What is the best way to achieve a typewriter text effect.(where text types out one character at a time) I’ve implemented this feature in blueprints using Strings and repeatedly setting the display text to substrings of increasing length of the source String over time. Is there a way to accomplish this with Text variables?
Is it possible to and if so what is the best way to create a list of buttons that can fire generic events/actions/functions?
What I would like to be able to do is to have a menu with various options that can fire functions in another class or classes.
Thus far I’ve followed this tutorial by Rama:
However his example requires the function of each button to be the same, and to be contained in the button itself.
What I’ve figured out so far: I set the button function up to fire an Event Dispatcher that my PlayerController class (where the menu is created) can listen to with a unique ID passed to the Dispatcher for each button. The issue is that the buttons are created using the Create Button function, and I obviously can’t put an event in that function and there’s no way for me to pass one in or out. I’m currently storing a reference to each of the buttons in an array when they’re created and binding the events in the Event Graph, which works but that seems a little messy. Is there a better way to do this that you’d recommend or does that sound right?
I have a question related to this as well – how can you store Button references in variables? I’ve been unable to create a button variable. It would be amazing to have a button array as well, but it doesn’t seem possible with BPs.
Can UMG widgets be used out in the world(not directly attached to the player viewscreen), and if so can you show a quick easy example? This would be things like a floating health bar on a unit/enemy, icons that float near specific points or objects, etc.
This would obviously be immensely useful for VR, too. I know that there was a post previously that the Unreal Engine team was working on getting this to work, but some general roadmap timeline might be nice!
As per the tutorial from Rama that I linked each Button is its own Widget and so in that case you can just reference each “Button” by the Widget Class (in that cast ListItem). That’s how I’m storing the Button references.
If you don’t have an entire Widget per Button like that you can store references to the actual Button type using a UObject.