Change to time dependant instead of frame dependant

Hello,

Last couple of days i have been rebuilding an old project of mine, in general just optimizing it and trying out new techniques to store and handle data.

One of the other things im trying to change is migrating it from being a frame dependant game to being time dependant.
Player movement etc is no problem but i just cant wrap my head around when i wanna move a object from point a to point b.

Since it updated before at a set 60fps i could always assume that it would reach the target position in 15 frames(See picture for reference)

How can something like this be solved with a time dependant solution instead of frames?
I’m not asking for a complete solution, just a push in the right direction.

Thanks in advance!

The GameTime variable given in Game.Update gives you a form of real-life time to use in your engine. GameTime.TotalGameTime tells you how much time has passed since the game was started, while GameTIme.ElapsedGameTime tells you how much time has passed since the previous update.

So, to ensure that your previously 60fps-dependent entity moves at roughly the same speed at a variable framerate, you can multiply the speed by something like (float)(DeltaTime.ElapsedGameTime.TotalSeconds * 60f).

Thank you, that makes sense when i think about it.
Started implementing it and starting to look like it used to with some minor changes to the conditions.