Changeset View
Changeset View
Standalone View
Standalone View
ps/trunk/source/network/NetServer.h
Show First 20 Lines • Show All 141 Lines • ▼ Show 20 Lines | public: | ||||
void SetTurnLength(u32 msecs); | void SetTurnLength(u32 msecs); | ||||
bool UseLobbyAuth() const; | bool UseLobbyAuth() const; | ||||
void OnLobbyAuth(const CStr& name, const CStr& token); | void OnLobbyAuth(const CStr& name, const CStr& token); | ||||
void SendHolePunchingMessage(const CStr& ip, u16 port); | void SendHolePunchingMessage(const CStr& ip, u16 port); | ||||
void SetConnectionData(const CStr& ip, u16 port, bool useSTUN); | |||||
bool GetUseSTUN() const; | |||||
CStr GetPublicIp() const; | |||||
u16 GetPublicPort() const; | |||||
bool CheckPassword(const CStr& password) const; | |||||
void SetPassword(const CStr& password); | |||||
private: | private: | ||||
CNetServerWorker* m_Worker; | CNetServerWorker* m_Worker; | ||||
const bool m_LobbyAuth; | const bool m_LobbyAuth; | ||||
bool m_UseSTUN; | |||||
u16 m_PublicPort; | |||||
CStr m_PublicIp; | |||||
CStr m_Password; | |||||
}; | }; | ||||
/** | /** | ||||
* Network server worker thread. | * Network server worker thread. | ||||
* (This is run in a thread so that client/server communication is not delayed | * (This is run in a thread so that client/server communication is not delayed | ||||
* by the host player's framerate - the only delay should be the network latency.) | * by the host player's framerate - the only delay should be the network latency.) | ||||
* | * | ||||
* Thread-safety: | * Thread-safety: | ||||
▲ Show 20 Lines • Show All 228 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator