Every frame a unit needs to acquire the TimeDelta to figure out how much time has passed to act upon their current velocity.
The timer is wrapped in a class. GetTimeDelta() func.
So I can either pass the TimeDelta to each unit that needs it each frame.
Or
I can create a static pointer in the unit class to the timer class TimeDelta and derefernce it each time it is needed.
Well, I know dereferencing is laggy, and it could be done as of now at most twice per unit per frame. Usually just to apply to the velocity once.
Which is the fastest method????




Reply With Quote