Hello, I’m new to UE, and using BP graphs. I started making my game without accounting for delta time. Since I became aware of the issue now I have to go back and fix things.
I know the basic premise of delta time and how to implement it, using multiplication to make value changes “over time” instead of “per tick.” But I’m not sure if I know everywhere I need to use this. It’s critical to get this right.
How can you know what things need delta time? I can understand gradual changes over time should use it. I also have read that Add Force accounts for delta time automagically, whereas calling Add Impulse every tick apparently does not. But what about Add Torque? Or how about timelines, do they account for delta time? What about, well, who knows what else? I’m still learning so I’m not aware of all the things.
Also, I’m trying to internalize the thought process necessary for this. I think it’s correct to say that every exec node being continuously ticked on that isn’t meant to be an instantaneous effect would need delta time. Then I just need to look backwards at all the data nodes connected to it and determine which values there need to be multiplied. However, let me share with you an example:
Say I wanted to use Set Physics Linear Velocity (ignoring for now that I could use Add Force etc. instead). here this code takes a fractional amount of the actor forward vector and a fractional amount of the current velocity vector and mixes them together to create a new velocity vector. The value connected to the lerp alpha is a constant. I believe the correct way to implement delta time into this would be to multiply in by that value connected to the lerp alpha. However, it wasn’t easy for me to figure this out. What kind of thought process should I use to make sense of these things?
I would appreciate any advice to be more confident in this!