Component made with NewObject cannot be moved
I'm using NewObject to create object that rotate arount it's parent.
The trouble is that if object is created via attaching in editor, everything is fine. When i'm using NewObject, that thing doesn't move. UMySceneComponent derive from USceneComponent and moving in a tick function by just setting a local position. What's wrong?
Thats because you did not attach it to anything ;P or at least you left out the Code that would tell me otherwise.
answered Jul 23 '17 at 06:11 AM
Seems like I figured out what's wrong. Moved all the "ball creation" stuff into "BeginPlay" instead of constructor and now everything is fine. Seems like if my call stack doesn't belong anymore to "usual" constructor call stack, things can get messy. Lost few hours figuring out what's wrong, but thx for an idea.
answered Jul 23 '17 at 08:47 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here