Spielerando

A dash or lunge ends in a different place on slow and fast computers

If the movement of an attack comes from the animation, then each computer adds up its own little steps and the sum comes out a bit different on every machine. After a few lunges, two screens disagree about where the fighters stand. Here is how to make every machine land on the same spot.

Why this works

Position that depends on how many pictures a machine draws will differ between machines. If the distance is read from a fixed curve at fixed steps, each step's share is a difference of exact values, so the shares add up to the full distance, whatever the display does.

When not to use it

Skip it when the movement must react to the world during the move, such as a lunge that steers toward a moving target or slides along walls; plain steering from the player's input fits better. It is also not needed in a game with only one machine.

In the full entry

  • What to build, step by step
  • Starting values and the reason for each
  • 3 common mistakes and the fix
  • 18 lines of example code with 3 checks that pass
  • How your AI shows you that it works

Say this to your AI

Use the Spielerando entry "A dash or lunge ends in a different place on slow and fast computers" (read_entry lunge-lands-in-the-same-spot-at-every-frame-rate) in my game. Build it step by step, and show me how you checked that it works.

Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP