Patrick Square
Explore posts from servers❔ Creating a multiplayer Snake game WPF, Blazor, SignalR
Server: This is where your snake array actually lives. All actual game mechanics should be calculated here. In my opinion, the server should not know the client exists.
Client: This is where your players play the game. All the client does is sends data to the server and receives data from the server. In my opinion, the client should not know that the server exists.
API: This is the layer that connects the server and the client and is generally an abstraction over your server's chosen connectivity choice, whether it be a web API or real-time framework like GRPC. This is how you will ensure the client and the server don't exactly know about each other, but can be trusted to communicate in a standard way.
You do not need to think about an exact schematic for every specific function of how this will work just yet. I strongly recommend you have these three concepts in mind and just start programming!
80 replies