Skip to content

Build a star topology game protocol

Sheeo edited this page Oct 6, 2014 · 1 revision

build a star topology game protocol.

purpose

  • reduce reliance on existing faf proxy
  • this stands to eliminate certain forms of desync
  • reduce server bandwidth.
  • possible reconnect/resume support after tcp disconnect?

components

  1. a localhost proxy that simulates the framing data of /n/ other players over udp to localhost. demuxes tcp streams into udp data recieved from 2 below from server into the engine's udp recieve port
  2. should remove it's own inbound commands, or verify the ones sent are the ones received.
  3. on the server side, a zero-copy muxer that receives tcp streams without udp framing data normally sent over udp, but everything else that matters. unclear how similar this is to replay data.
  4. sends the entire tick over tcp to the player's localhost proxy above, including the player's own commands. if all players receive the same stream (unclear if this is exactly what a replay looks like at this time...) the transmission of one outbound network buffer to n sockets is pretty cheap and scalable.
  5. optional deflate on stream
  6. should be single-process, single thread C or java select IO handling numerous concurrent matches and handling the replay-server role of FAF defined elsewhere
  7. FAF client support
  8. toggle use in FAF
  9. define or register server mux before launch and include in lobby pre-game meta
  10. encapsulate lobby protocol also? adding and removing players before match?
Clone this wiki locally