C++ Code Doesn't Update Unless Instance gets replaced
So I was following this tutorial; https://docs.unrealengine.com/latest/INT/Programming/Tutorials/PlayerInput/index.html
and I just finished it up, but I wanted to change the camera rotation,So I went into the code and changed it and compiled on UE4.
But i noticed the camera rotation stayed the same and so I deleted the instance on the level and re-placed it in the level and now it was changed.
Is it how its supposed to happen? or Am I missing something?
asked Jul 11 '17 at 11:11 PM in C++ Programming
My guess is that the .umap file stores the Transform information of your camera component, so even the default value had changed it was override by the value from the map.
Two possible fix:
Easy way (Not recommended): Set the camera rotation in BeginPlay().
Ideal way: Expose the camera component to Blueprint. Create a BP version of your pawn, and use the BP version in the map.
This way you can edit camera transform in the blueprint editor so it's less hard-coded and compiling BP is much faster.
Follow this question
Once you sign in you will be able to subscribe for any updates here