Collab View Template Input Change

Hello there! I am a newbie to unreal engine and its interfaces and I was trying to use the collab view template in the architecture section I want to know “Where is the code by which the widget was showing on the screen” as I press SpceBAr because I want to change it from spacebar to simple always showing widget icon but I am unable t find it but there are lots of blueprints and logics
And Actually in the unreal doc, it says that it is handled by the interaction menu but I m not able to find it also…

So can you help me to find that Where IS the code/logic by which the widget was showing on the screen???

o/
I’ll give you general hints on how to debug any widget from any project !

You can easily ‘get to’ any project widget at runtime (while playing), or engine widget (editor UI widgets directly in editor) with Widget Reflector
just press: Ctrl Shift W (in UE5)


or from top menu: Tools → Debug → Widget Reflector The new window will appear with handy way to inspect any widget which is currently visible on screen.

Then, for interactive widgets click: Pick Hit-Testable Widgets
and click on widget You want to inspect. Hierarchy with highlighted widget being one You’ve clicked will appear. From there You can navigate to source of widget by clicking on it Source column, or check where it lies in hierarchy to further inspect where it could be coming from.
You can also view widget details, to see them show:
Window → Details

For non interactive widgets click three dots menu and choose:
image
then repeat what I said.

Also usually Widgets are drawn in common places like (for BP projects):

  • HUD actor. Check Your WorldSettings. (Window → World Settings).
    image
    If custom class was specified for HUD in game mode inspect it. Good chance it might be initialised there.
  • If no custom HUD class is visible or widget not there, check GameMode itself, PlayerController etc.
  • Lastly check Level Blueprint
    image

Good chance widgets might be in one of these places :slight_smile:

Thanks a lot that helps me very much and I found it out in my Bp_playercontroller mode thnx again for help

but now that i have found out that I’m having an issue in adding another widget in its interaction menu as I wanna change my wall material and want that option to be shown in that interaction menu
ANY HELP???

plz describe what you want to achieve in more details :slight_smile:

Actually I want to add more options in the interaction menu of the collab viewed template


right now it shows its own menu option in that but now I wanna add my choice option and remove some like scale but I don’t how ?? cause it is way more complicated for me
So do you know how to?

Where did You get CollabView project from ?

There is a Contextual_Widget widget blueprint containing Activate VB WrapBox widget. It’s children (buttons) get dynamically added at runtime by running Add Child to Wrap Box method on it.
This is done in BP_BaseCommandComponent so each component inheriting from it adds it’s own button widget to it.

Now to delete some buttons you can modify those child components not to add buttons.
To add new custom button you can make your own component and specify a button widget to add, or (if it doesn’t have to be dynamic) just directly add button to WrapBox in Contextual_Widget wrapbox named Activate VB

Then do with that button whatever you want :slight_smile:

2 Likes

thank you so much @UnrealVerseGuru for your reply but can you be more specific as I added my button in it and add some blueprints but it doesn’t show on a contextual menu in the viewport

I have selected from architecture section templates

Make sure those buttons you add are not cleared out
they are in BP_BasePawn


so if you add your buttons dynamically - make sure it happens after the clear, re-add them after the clear or remove clearing all together for this particular button you add :slight_smile:

If you do not need to have them exactly in Activate_VB WrapBox you might want to add the button to the VerticalBox it resides in (red arrow)
image
This way you won’t have to modify the script dealing with clearing that happens

ok thank you, it is very helpful

Thanks, this is really helpful info.

How would you go about creating a new, dynamically created button (the same as the others). Or even remove existing ones from the context menu? I can see they get compiled into an array of object references but can’t find how to edit that, or where to look. Sorry - UI newbie.

Cheers

Hi @GreeyaJini,

did you find a way to add a button ‘dynamically’?
trying to do the same but with no results :frowning:

this is what i did:

Hey just saw that and had the same problem. Noticed that you have to add the component to the base pawn and or VR Pawn depending on where you want the button to be otherwise it wont be found by the get component by class node and therefor not added.