Skip to content

Instantly share code, notes, and snippets.

@TrueBrain
Last active Aug 10, 2021
Embed
What would you like to do?
Network TODO list

GC = Game Coordinator

Cleanup

  • ✓ Server name not empty (or default to "playername's server"?)

Client Info

  • 9114 Add GAME_INFO to TCP and use it for lobby
  • 9469 Sync NetworkGameInfo from server with all clients, so clients locally know the server they are on (and sync servername changes when they happen); possibly only sync information client doesn't already know via a Command packet.
  • 9469 Show server name in GUI

Connect

  • 9112 Change Connect() to always be non-blocking and with a low (configurable) timeout
  • 9127 Allow Connect() to bind locally

NetworkGame* Refactor

  • Refactor NetworkGameList to use C++ linked-list (and don't call an entry on a list List)
  • 9114 Refactor NetworkGameInfo to have all functions in the same place (like SendGRFIdentifier etc)
  • 9114 Add new NetworkGameInfo version to work better with GC (optional NewGRF, remove of unused fields, invite-code)

STUN

  • 9017 Add ability for Connect() to do either a direct-connect or connect via GC
  • 9017 Add STUN capability
  • 9017 Show GC invite code in GUI

Game Coordinator

  • 9017 Add announcing via GC and update GC with latest info every 30 seconds (but only do NewGRF blob once)
  • 9017 Add retrieving server-list via GC
  • ✓ Add ability to GC to scan a new server what type of connection he has (direct, STUN, TURN, ..)
  • 9017 On client-join-request, figure out best way to connect client and server
  • ✓ Allow for "sticky" invite-codes

Visibility

  • 9017 Add "visibility" setting "friends-only", which does connect to GC but doesn't make the server public

NewGRFs

  • On join, ask user to download missing NewGRFs and automate this otherwise
  • 9114 Extend the NewGRF blob in server info with the name of the GRF, so we can do away with the complex code to get the name if we don't know the NewGRF

UDP

  • 9017 Remove UDP protocol from OpenTTD (only keep the UDP broadcast for local LAN network game discovery)

UI flow

  • If a server has a password, ask that before showing company info (or as alternative:)
  • 9467 Remove lobby window on join, but join the game as spectator and show Network GUI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment