This is probably very simple question but I can’t find anything related except C++ examples.
So here is the use case. I created Actor blueprint. Put into it TextRender Actor and exposed a public variable called “text string” so that I can drop this actor into the level, type a string into “text string” field and see the updated text on that actor. The problem is - I can’t find how to listen to editor fields change in BP. There is a ton of C++ examples, but I don’t want to jump into code for something simple like this. I found that each time I change a prop in details panel, the related actor’s construction script is being called, but then the text property of the TextRenderComponent is being set again from its own “text” property. So what I need is to set that property based on the “text string” field change AFTER the construction script has been called. Is it only possible via C++ only?
I have my reasons to wrap text render component into custom actor. Also,the “text” property of the comp is not exposed in details panel when it is part of the BP actor.
Hello! But Text Render Component has its own Text field, that is working fine…
Unfortunately I don’t think it’s directly possible without C++
There is no blueprint event or overrideable function that is equivalent to PostEditChangeProperty…
But all you need is something to run after the Text Component sets its own text, right?
The only thing I can think of is this (its kinda dumb):
- Create a new Custom Event in the Event Graph. (by right-clicking and selecting “Add Custom Event”)
- Add onto the Custom Event’s exec pin a Delay node with a delay of 0.1 seconds
- Set the Text Component’s text after the Delay node
- Call the Custom Event in the Construction Strip
Hope this helps.
Do you add component in C++ at runtime? For other add methods (C++ Constructor && Blueprint Editor) component’s “text” property is accessible through details panel.