What is the proper procedure with editing a Struct?
It seems like half the time I edit a Struct after I've already implemented it within my BP that something goes wonky. One example that just happened, I went to edit a Struct with 2 elements. The editor crashed. I boot back up and a different Struct with 10 elements (in the same BP) had 5 separate instances of being disconnected. I reconnected all nodes. Ran my project, had issues and then closed the editor. Reopened and the same nodes were all disconnected again. (I've had disconnecting nodes upon launching my project before, so this is not the first time.)
After all that I right clicked and hit 'Refresh Nodes' on all the ones with issues and they no longer broke upon opening the editor.
So the real question is: What procedures should I follow when editing a Struct? Should I even edit them once implemented? Is this behavior unintentional or is some kind of bug within the editor?
Thanks for any feedback and answers.
asked Feb 12 '17 at 12:21 AM in Using UE4
Ive had issues with structs in BP so I try to keep them as flat and simple as possible compared to how I used to work in UScript. Ive found having structs nested in other structs can be fragile as theres no way to set the correct compile order if the editor gets it wrong. Atleast in my experience with BP that seems to be one of the causes of alot of issues is that its trying to compile things out of order which causes it to crash.
Its difficult to know without seeing exactly what it is youre doing, 10 elements could mean anything which leaves alot of room to not be able to reproduce it.
The ideal situation is that you dont edit structs too much once they are created and you start using them, there are instances where editing a variable type once its being used extensively causes a similar type of crash.
If you do need more stability of editing structs you can use C++ but it requires you to restart the editor alot, I do recommend working on paper and really nailing down your data structures as much as you can first and if you need updates create a new data structure to replace the old one entirely. It does create abit of rework but it seems to be far more stable to do it that way then trying to modify types which touch alot of functionality.
answered Feb 12 '17 at 07:34 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here