playMaker

Author Topic: How do I zoom the camera fov smoothly?  (Read 1587 times)

kevkev

  • Playmaker Newbie
  • *
  • Posts: 3
How do I zoom the camera fov smoothly?
« on: December 15, 2019, 02:46:30 PM »
I tried to do it with float variables but it doesnt work. The FSM (shown in the image) shows no errors and does everything right but it just doesnt change the fov.
I also tried "Ease float" and " along with float lerp and "float interpolate" but none work. What am I doing wrong?

Note that i CANT do it with camera moving from one empty to another, because it just glitches the camera through walls which i obviously dont want. Im just trying to change the fov smoothly
« Last Edit: December 15, 2019, 04:11:37 PM by kevkev »

Wrensey

  • Playmaker Newbie
  • *
  • Posts: 23
Re: How do I zoom the camera fov smoothly?
« Reply #1 on: December 15, 2019, 05:00:00 PM »
Make sure you are setting the property of the camera fov to the float variable you are animating in the same state you are animating the variable in

So your "camera Fov" variable should be getting set to the camera every frame in States 2 and 3
Follow me on twitter!

kevkev

  • Playmaker Newbie
  • *
  • Posts: 3
Re: How do I zoom the camera fov smoothly?
« Reply #2 on: December 15, 2019, 08:25:46 PM »
thank you i tried but its still not working. it now changes the fov instead of doing nothing, but it still doesnt lerp, it just changes it instantly from 70 to 40.
and the 3rd state doesnt finish now? it just stops there and i have no idea how to make it go back to state 1.

Wrensey

  • Playmaker Newbie
  • *
  • Posts: 23
Re: How do I zoom the camera fov smoothly?
« Reply #3 on: December 15, 2019, 11:17:01 PM »
Try using the Ease Float action again instead of the lerp, much easier to work with imo. Set the finished event to FINISHED or whatever custom event you need. I attached screenshots of an example of how it works recreating what you're trying to do

The attached example worked for smoothly changing the camera fov when I tried it
« Last Edit: December 15, 2019, 11:38:09 PM by Wrensey »
Follow me on twitter!

kevkev

  • Playmaker Newbie
  • *
  • Posts: 3
Re: How do I zoom the camera fov smoothly?
« Reply #4 on: December 16, 2019, 06:50:08 PM »
thank you sooo much man, this helped it finally works now. so im guessing float interpolate doesnt have much of a use in most cases?

Wrensey

  • Playmaker Newbie
  • *
  • Posts: 23
Re: How do I zoom the camera fov smoothly?
« Reply #5 on: December 16, 2019, 09:59:16 PM »
No problem! I never use it, pretty much exclusively use "Ease" actions whenever I need to animate a variable.

Tip: The "Ease Type" option within the action is a really useful and fun thing to play around with if you haven't already. Lets you easily do smooth ease in/out or other cool effects
Follow me on twitter!