How is the shooting and hitting managed in common shooter online multiplayer games? [closed]

I will address your question in the realm of Counter Strike since it is the game out of those you listed that I am most familiar with. Take it with a grain of salt since not all FPS games are the same.

  1. If as you stated in the question you are moving and shooting, in CS it is quite possible that you would miss a target, even at close range, due to moving inaccuracy. Many games have moving inaccuracy especially those that claim to be more realistic but others that you have not listed like CoD, Battlefield, Overwatch, etc have negligible to no moving inaccuracy and reward players for moving quickly. In the scenario you listed, it is normal for a player with their crosshair directly on another player to miss a shot if they are moving (I'd actually be quite mad if I did get killed like that). Even if you are standing still, IF you and the other player are far enough away, that you would miss even if your crosshair was right on their head due to range inaccuracy of most guns outside of snipers (at least in CSGO).

  2. Same as above. I'm not sure how the vectors for bullets are calculated in CS but I assume they have a 3 dimensional plane with a variable area depending on what your character is doing (moving, crouching, standing still, jiggle peaking, etc). The coordinates of the final resting place of the bullet would be calculated and a vector would be drawn from the gun to the point and if it intercepts a character it will do damage based on the guns damage, where it hit on the character model, and if it passed through any penetrable surfaces.

  3. This one is not too absurd and it happens in games of all types. All games have different bullet travel times so it is quite easy for you to have a firefight with another person where both of you would have bullets in the air traveling towards the other at the same time. Unless the bullets are meant to despawn after you die, it is reasonable for you and another player to kill each other. It is even easier for this to happen if explosives are involved since they usually travel slow or have delayed explosions.

  4. This is, as Unionhawk said, more of a server thing. In CS, there are multiple kinds of servers that you may play on with something called a tick rate. The higher the tick rate, the more often the location of you and your enemies is updated. With low tick rates, although it is frustrating, it is normal for a shot to get fired where you were and still register as a hit. Since your character model is still registered as being there and bullets have a certain velocity, when the server does update, it would calculate you as still being there even if you were around the corner.

Hopefully this is helpful for you and please let me know if there is anything else you would like me to clarify.