Hey, everyone. Wanted to ask for help on what to do next. Here’s what I want to achieve:
I have 3 buttons and that each button once pressed should move on a specific position but instead of going to the next position, it would animate to the next position.
I added a Camera Rig Rail and attached a Camera Actor. I added a camera rig rail because I think it would be easy since I would only change the “Current Position on Rail” value via Blueprint Scripting.
It kinda works when I press the “Left button” because it would go to the position. What I am unsure on what to do next is how I am supposed to proceed to the next position.
Magic thing you should try first: camera arm component and turn on camera lag.
Now solution to your problem:
create 3 or more scene components inside player pawn bluepriints (same as camera is)
set up your components where you want those camera spots, together with rotation and location.
when you press one of buttons, enable camera lag (one that you use for transition), set camera position to one of those scene components, and let camera arm handle rest.
after camera is moved, turn camera arm lag back to some sane levels.
Because camera arm does not interpolate its length, you need to code it:
“desired_arm_length” is variable you set in keyboard events, then you read it in event tick, and interpolate arm length to its desired value.
PS.
If you want you can drop idea of using camera arm, and instead interpolate (just like arm length) transform of camera to move it and rotate. However you will need to add collision with walls checking it etc. So code whole camera behavior.
Oh i just read your whole post
Well maybe my arm solution has some use for you.
You probably need to reverse or reset animation while going from higher area to lower one.
Just put it on a sequence, these guys are all making it too complicated, with a sequence you can control the rotation and every aspect of the camera, on button clicked fire sequence.