I’m working on the LAN network ability right now which involves multi threading i’ll try and at least get the server part done tonight and ill share all the classes so far in this folder
Server Setup:
ClientThread setup:
Client setup:
Listen from Server Thread setup:
Server Setup:
- Setup server socket
- Waits for clients to connect
- accepts client connection
- makes thread for client
- adds thread to arraylist
- broadcast location of all servers players
- remove method to remove disconnected clients
ClientThread setup:
- Create output and input streams
- send coordinates to all clients
Client setup:
- setup client socket
- setup data streams
- create thread to listen from the server
- send this users coordinates
- disconnect method
Listen from Server Thread setup:
- constantly runs and tries to get input from server