I didn’t like it when it was added without a timeline, all at once, because it was too jittery movement. So I added a Timeline that gives rotation over 0,4 sec.
Now, as a newbie, I am wondering. Do I need to multiply the timeline output by Delta time?
Because it is different if I add some value over 0,4 sec … or If I add the value depending on how many frames the player is running the game, right? Like I run the game 65FPS and with that I am developing.
But the better machine that runs 120 FPS would have 2times bigger the rotation, right?
As a novice, I have a question now. Does the timeline time output need to be multiplied by Delta time?
Since things change if I add a value that is more than 0.4 seconds. or If I increase the value based on the number of frames the player is using to run the game, am I correct? Like I’m developing while running the game at 65 frames per second.
@ZkouskaMikrofonu You probably should not be using a timeline for this to start with. You have the Action Value pin on your input - it should be set to an axis and produce a float or a swizzled vector, or even a world-transformed ready-to-go vector (check input modifiers). And then be multiplied by frame delta.
I am making game, where AD gives a rotation to a motorbike.
If you use a TL here, you tap a key once then wait, let’s say 5s, during which the bike turns automatically without further input - is that what you want? Or is this real-time? The longer we hold key, the more we lean & bank?
Timelines work with time - you play it and it runs for x seconds. It is frame-rate independent but you can make it frame-rate dependent by plugging something into the Update that does not belong there (or you’re making something funky). The TL’s Update fires every frame - the more frames, the more updates. The real question is what are you doing with the data during the update.
Timelines work best with Lerps by producing Alpha which is then sampled during the Update, the more frames, the more steps, but the same end result.
this will run pretty much the same at 10 and 100 fps:
The game runs on physics. Move-forward is made by physics constrain on a wheel and setting the rotation and strength of the Physic Constrain… setting physics materials… friction, gravity…
So to add “world/relative rotation” all the time is math beyond my skill. I am for example scared that adding world/relative rotation would not react with angular damping…
Or I think I would have to create a function with a big math in it…
If I add torque force with a button press, math is taken care of by the engine
So when I decide how to rotate, I do not want to put direct value into world rotation, but I prefer to affect the physics.
Anyway, I will read a few more times what you wrote to get it and then I think I will try to playtest the Lerp option by adding torque force to the rotation vector.
Rotation was just an example, if you want physics, use torque. A timeline serves a different purpose, though. It simply makes little sense apllied like that.