37:083e493fa1fd | 38:80b26bc9707a |
---|---|
35 | 35 |
36 // ------------------------------------------------------------------------------------------------- | 36 // ------------------------------------------------------------------------------------------------- |
37 // | 37 // |
38 enum | 38 enum |
39 { | 39 { |
40 RCON_PROTOCOL_VERSION = 3 | 40 RCON_PROTOCOL_VERSION = 4 |
41 }; | 41 }; |
42 | 42 |
43 // ------------------------------------------------------------------------------------------------- | 43 // ------------------------------------------------------------------------------------------------- |
44 // | 44 // |
45 enum ServerResponse | 45 enum ServerResponse |
49 SVRC_SALT, | 49 SVRC_SALT, |
50 SVRC_LOGGEDIN, | 50 SVRC_LOGGEDIN, |
51 SVRC_INVALIDPASSWORD, | 51 SVRC_INVALIDPASSWORD, |
52 SVRC_MESSAGE, | 52 SVRC_MESSAGE, |
53 SVRC_UPDATE, | 53 SVRC_UPDATE, |
54 SVRC_TABCOMPLETE, | |
54 }; | 55 }; |
55 | 56 |
56 // ------------------------------------------------------------------------------------------------- | 57 // ------------------------------------------------------------------------------------------------- |
57 // | 58 // |
58 enum ClientRequest | 59 enum ClientRequest |
60 CLRC_BEGINCONNECTION = 52, | 61 CLRC_BEGINCONNECTION = 52, |
61 CLRC_PASSWORD, | 62 CLRC_PASSWORD, |
62 CLRC_COMMAND, | 63 CLRC_COMMAND, |
63 CLRC_PONG, | 64 CLRC_PONG, |
64 CLRC_DISCONNECT, | 65 CLRC_DISCONNECT, |
66 CLRC_TABCOMPLETE, | |
65 }; | 67 }; |
66 | 68 |
67 // ------------------------------------------------------------------------------------------------- | 69 // ------------------------------------------------------------------------------------------------- |
68 // | 70 // |
69 enum RCONUpdateType | 71 enum RCONUpdateType |
105 METHOD bump_last_ping() -> void; | 107 METHOD bump_last_ping() -> void; |
106 METHOD send_command (const String& message) -> bool; | 108 METHOD send_command (const String& message) -> bool; |
107 METHOD state() const -> RCONSessionState; | 109 METHOD state() const -> RCONSessionState; |
108 METHOD level() const -> const String&; | 110 METHOD level() const -> const String&; |
109 METHOD is_active() const -> bool; | 111 METHOD is_active() const -> bool; |
112 METHOD request_tab_complete (const String& part) -> void; | |
110 | 113 |
111 static METHOD new_session() -> RCONSession*; | 114 static METHOD new_session() -> RCONSession*; |
112 static METHOD get_session() -> RCONSession*; | 115 static METHOD get_session() -> RCONSession*; |
113 | 116 |
114 private: | 117 private: |
122 String m_salt; | 125 String m_salt; |
123 int m_serverProtocol; | 126 int m_serverProtocol; |
124 String m_hostname; | 127 String m_hostname; |
125 int m_numAdmins; | 128 int m_numAdmins; |
126 String m_level; | 129 String m_level; |
130 String m_lastTabComplete; | |
127 }; | 131 }; |