1 use crate::server::coretypes::{GameCfg, HedgehogInfo, ServerVar, TeamInfo, VoteType}; |
1 use crate::server::coretypes::{GameCfg, HedgehogInfo, ServerVar, TeamInfo, VoteType}; |
2 use std::{convert::From, iter::once, ops}; |
2 use std::{convert::From, iter::once, ops}; |
3 |
3 |
4 #[derive(PartialEq, Eq, Clone, Debug)] |
4 #[derive(PartialEq, Eq, Clone, Debug)] |
5 pub enum HWProtocolMessage { |
5 pub enum HWProtocolMessage { |
6 // core |
6 // common messages |
7 Ping, |
7 Ping, |
8 Pong, |
8 Pong, |
9 Quit(Option<String>), |
9 Quit(Option<String>), |
10 //Cmd(String, Vec<String>), |
|
11 Global(String), |
10 Global(String), |
12 Watch(String), |
11 Watch(String), |
13 ToggleServerRegisteredOnly, |
12 ToggleServerRegisteredOnly, |
14 SuperPower, |
13 SuperPower, |
15 Info(String), |
14 Info(String), |
16 // not entered state |
15 // anteroom messages |
17 Nick(String), |
16 Nick(String), |
18 Proto(u16), |
17 Proto(u16), |
19 Password(String, String), |
18 Password(String, String), |
20 Checker(u16, String, String), |
19 Checker(u16, String, String), |
21 // lobby |
20 // lobby messages |
22 List, |
21 List, |
23 Chat(String), |
22 Chat(String), |
24 CreateRoom(String, Option<String>), |
23 CreateRoom(String, Option<String>), |
25 JoinRoom(String, Option<String>), |
24 JoinRoom(String, Option<String>), |
26 Follow(String), |
25 Follow(String), |