Restructure repository to include all source folders
Move git root from Client/ to src/ to track all source code: - Client: Game client source (moved to Client/Client/) - Server: Game server source - GameTools: Development tools - CryptoSource: Encryption utilities - database: Database scripts - Script: Game scripts - rylCoder_16.02.2008_src: Legacy coder tools - GMFont, Game: Additional resources 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,78 @@
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// UDPList
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
#ifndef _GAMA_CLIENT_UDP_ADDRESS_LIST_H_
|
||||
#define _GAMA_CLIENT_UDP_ADDRESS_LIST_H_
|
||||
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <winsock2.h>
|
||||
#include <winsock.h>
|
||||
#include <list>
|
||||
|
||||
enum PEERTYPE
|
||||
{
|
||||
Not_Defined = 0, // <20><><EFBFBD><EFBFBD> <20>ȵ<EFBFBD>
|
||||
REAL_IP, // <20><><EFBFBD><EFBFBD> IP
|
||||
NAT_Friendly, // <20><><EFBFBD><EFBFBD> IP (<28><><EFBFBD><EFBFBD> NAT)
|
||||
NAT_Different // <20><><EFBFBD><EFBFBD> IP (<28>ٸ<EFBFBD> NAT)
|
||||
};
|
||||
|
||||
typedef struct UDP_LIST* LPUDP_LIST;
|
||||
struct UDP_LIST
|
||||
{
|
||||
DWORD CharID; // ij<><C4B3><EFBFBD><EFBFBD> <20><><EFBFBD>̵<EFBFBD>
|
||||
|
||||
PEERTYPE PeerType; // <20><><EFBFBD><EFBFBD> Ÿ<><C5B8>
|
||||
SOCKADDR_IN PublicAddress; // <20>ּ<EFBFBD> Public
|
||||
SOCKADDR_IN PrivateAddress; // <20>ּ<EFBFBD> Private
|
||||
|
||||
DWORD MoveTick; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ð<EFBFBD>
|
||||
};
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Ŭ<><C5AC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
class UDPList
|
||||
{
|
||||
public:
|
||||
|
||||
typedef std::list<UDP_LIST*> STDLIST;
|
||||
|
||||
UDPList();
|
||||
~UDPList();
|
||||
|
||||
DWORD InsertIntoAddressList(DWORD CharID_In, const SOCKADDR_IN& PubAddress_In,
|
||||
const SOCKADDR_IN& PriAddress_In, PEERTYPE PeerType_In);
|
||||
|
||||
DWORD InsertIntoAddressList(UDP_LIST* lpUDP_List);
|
||||
|
||||
bool DeleteFromAddressList(DWORD CharID_In);
|
||||
bool DeleteFromAddressList(const SOCKADDR_IN& Address_In);
|
||||
void DeleteAllFromList();
|
||||
|
||||
bool IsListEmpty() { return m_UDP_List.empty(); }
|
||||
size_t GetListCount() { return m_UDP_List.size(); }
|
||||
|
||||
LPUDP_LIST SearchFromAddressList(DWORD CharID_In);
|
||||
LPUDP_LIST SearchFromAddressList(const SOCKADDR_IN& Address_In);
|
||||
|
||||
void SetGarbageStackLength(size_t StackLength_In);
|
||||
void ClearGarbageStack(void);
|
||||
|
||||
STDLIST::iterator begin() { return m_UDP_List.begin(); }
|
||||
STDLIST::iterator end() { return m_UDP_List.end(); }
|
||||
|
||||
protected:
|
||||
|
||||
STDLIST m_UDP_List;
|
||||
STDLIST m_GarbageList;
|
||||
|
||||
size_t m_nMaxGarbageStackLength;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user