Ok not even saying the idea of a shooter gets used,
to fix it couldn't the server tell the client they where shot at x,y the client then checks to see what tile they are on if they arn't on that x,y then the bullet doesn't hit them?
This way it is 100% accurate to the point of impact at least.
Thats a start, but a bullet starts to move before it is created. Take this example:
- Player A left-clicks, their gun is shot
- The packet is sent to the server, where the server has to take the position of the user, the time it took for the packet to reach the server, and predict where the bullet is
- The server sends the bullet's location and velocity to every client in range
- Every client then takes that position and calculates based off of the recent average ping and velocity of the bullet the location it should be, and increases the bullet's velocity until it is caught up to the point where it should be, then velocity returns to normal
You also have to take into consideration that a fast bullet can travel more than one tile at a time, so you have to calculate collision based on every tile the bullet has passed through since the last check, not the tile the bullet is on.
And that is just the basics. :X
How is the ranged weapons working in vbgore, lol it's all there now that I think about it.. Ninja stars
A shooter where the only time you aim is to auto-target someone? Ick.