forked from jewalky/srvmgr
-
Notifications
You must be signed in to change notification settings - Fork 5
/
protolayer_hat.h
45 lines (38 loc) · 1.01 KB
/
protolayer_hat.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#ifndef PROTOLAYER_HAT_HPP_INCLUDED
#define PROTOLAYER_HAT_HPP_INCLUDED
bool Net_HatInit();
bool Net_HatProcess();
void Net_HatShutdown();
#include "lib\socket.hpp"
#include "lib\utils.hpp"
#include "lib\packet.hpp"
namespace NetHat
{
extern std::string HatAddr;
extern uint16_t HatPort;
extern std::string ControlAddr;
extern uint16_t ControlPort;
extern SOCKET Socket;
extern bool Connected;
extern uint32_t LastReconnect;
extern PacketReceiver Receiver;
extern uint32_t ServerCaps;
extern bool HaveInfo;
struct ServerInfo
{
unsigned long PlayerCount;
unsigned long MapLevel;
std::string MapName;
unsigned long GameMode;
unsigned long MapSize;
};
extern ServerInfo Info;
extern bool ShuttingDown;
extern uint32_t LastUpdate;
}
bool NetCmd_UpdateInfo();
bool NetCmd_Broadcast(std::string what);
bool NetCmd_Shutdown();
bool NetCmd_UnlockLogin(std::string login);
void Net_RegularProc();
#endif // PROTOLAYER_HAT_HPP_INCLUDED