1 package network 2 3 type packettype_t uint8 4 // from d_clisrv.h 5 const ( 6 pt_nothing packettype_t = iota // To send a nop through the network. ^_~ 7 pt_servercfg // Server config used in start game 8 // (must stay 1 for backwards compatibility). 9 // This is a positive response to a CLIENTJOIN request. 10 pt_clientcmd // Ticcmd of the client. 11 pt_clientmis // Same as above with but saying resend from. 12 pt_client2cmd // 2 cmds in the packet for splitscreen. 13 pt_client2mis // Same as above with but saying resend from 14 pt_nodekeepalive // Same but without ticcmd and consistancy 15 pt_nodekeepalivemis 16 pt_servertics // All cmds for the tic. 17 pt_serverrefuse // Server refuses joiner (reason inside). 18 pt_servershutdown 19 pt_clientquit // Client closes the connection. 20 21 pt_askinfo // Anyone can ask info of the server. 22 pt_serverinfo // Send game & server info (gamespy). 23 pt_playerinfo // Send information for players in game (gamespy). 24 pt_requestfile // Client requests a file transfer 25 pt_askinfoviams // Packet from the MS requesting info be sent to new client. 26 // If this ID changes update masterserver definition. 27 pt_resynchend // Player is now resynched and is being requested to remake the gametic 28 pt_resynchget // Player got resynch packet 29 30 // Add non-PT_CANFAIL packet types here to avoid breaking MS compatibility. 31 32 // Kart-specific packets 33 pt_client3cmd // 3P 34 pt_client3mis 35 pt_client4cmd // 4P 36 pt_client4mis 37 pt_basickeepalive // Keep the network alive during wipes, as tics aren't advanced and NetUpdate isn't called 38 39 pt_canfail // This is kind of a priority. Anything bigger than CANFAIL 40 // allows HSendPacket(* true, *, *) to return false. 41 // In addition this packet can't occupy all the available slots. 42 43 44 pt_textcmd // Extra text commands from the client. 45 pt_textcmd2 // Splitscreen text commands. 46 pt_textcmd3 // 3P 47 pt_textcmd4 // 4P 48 pt_clientjoin // Client wants to join; used in start game. 49 pt_nodetimeout // Packet sent to self if the connection times out. 50 pt_resynching // Packet sent to resync players. 51 // Blocks game advance until synched. 52 53 pt_tellfilesneeded // Client, to server: "what other files do I need starting from this number?" 54 pt_morefilesneeded // Server, to client: "you need these (+ more on top of those)" 55 56 pt_ping // packet sent to tell clients the other client's latency to server. 57 numpackettype 58 ) 59 const pt_filefragment = pt_canfail // A part of a file. 60