Spielerando

Bullets fired by players with a slow connection start far behind the gun

When the host creates a shot only after your fire message has crossed the network, it starts late and trails behind where it should be. Starting it a little further along fixes the look, but too much of that lets shots appear through walls. Here is the right amount and what to do at obstacles.

Why this works

The shooter pressed fire in the past, so a bullet that appears later is simply behind where it belongs. Starting it partway along makes up the lost time, while the cap and the wall check stop the catch-up from becoming a way to cheat.

When not to use it

Avoid it for slow, visible projectiles such as lobbed bombs or magic bolts, where a late start is natural and dodging is the point. Let them start at the gun and take their full flight.

In the full entry

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

Say this to your AI

Use the Spielerando entry "Bullets fired by players with a slow connection start far behind the gun" (read_entry online-fire-a-bullet-already-on-its-way) 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