I know how building a solo game works, with models and interactions coded, but how are games made so that those interactions happen on many players screens with just tens of milliseconds of difference. Is it code or is it putting your game files (models + code + whatever else I am missing) on a server that can be accesed by peoples devices?
In: Technology
Generally the game client and assets are on your computer, and you are sending/receiving packets of data to a server, which handles getting them to the other players, that describe your actions.
For instance, if you turn your character to face north, it isn’t sending the whole model, it just sends some data that describes you/your state. IE. for some top down game like the original Zelda
{
player: “Charming_Possesion6”
, location_x: some number to show where you are left/right
, location_y: some number to show where you are up/down
, rotation: Up
, current_health: 10
, max_health: 10
, player_model: whatever avatar you choose
, etc..
}
and the game client on your computers knows how to take that sort of data and render each other player it has data for.
Latest Answers