-
Notifications
You must be signed in to change notification settings - Fork 37
Kryonet & Networking
This library wraps Kryo functionality and basically allow us to use it in both sides (client and server) so we can send Java Objects. Read more about Kryonet
If we understand how ECS works, we can say that the Server will have the real World and clients will see a portion of that same World. The reason is simple: to make it more efficient
A client will be interested on things that it should know, for example, if a user is in map 1, same user doesn't care what's happening in other maps and even what happens on other far away parts of the map.
The solution is to keep relations between near entities, let say what entities are around X tiles (X = 30 TBD).
With EntityUpdate and RemoveEntity classes, we can do all what we want and is very intuitive. Client will be in charge of send user input (Requests), so Server can process that input and notify corresponding near users with (EntityUpdate, RemoveEntity and Responses).
- IntelliJ
- Windows JDK
- Linux JDK
- Run client and server localhost
- Host a public server
- Import project to IntelliJ