#ifndef _L2EX_ #define _L2EX_ #ifndef _GLOBAL_ #include "Global.h" #endif #ifndef _CCREATURE_ #include "CCreature.h" #endif #ifndef _CSOCKET_ #include "CSocket.h" #endif #ifndef _L2SERVER_ #include "L2Server.h" #endif #ifndef _USERCONTAINER_ #include "UserContainer.h" #endif #ifndef _CPLEDGE_ #include "CPledge.h" #endif extern "C" { void CharSelectInfoFix(BYTE *pSocket, const char *szFormat, BYTE bOpCode, DWORD dwCharNum, DWORD dwPacketSize, DWORD *pOldPacket); void UserInfoFix(BYTE *pSocket, const char *szFormat, ...); void CharInfoFix(BYTE *pSocket, BYTE *pUser, const char *szFormat, ...); void EWHandler(CCreature *pUser); void NewAve(); } class L2Ex { public: L2Ex(); static L2Ex *Instance(); void WriteServerMemory(DWORD *pAddress, LPCVOID pData, SIZE_T nSize); void WriteServerHook(BYTE *pAddress, DWORD *pFunction, BYTE bNops); void SetProtocolRevision(const char *szRevision); void IncreaseMaxNpcId(); void IncreaseMaxItemId(); void FixVersionPacket(); void FixCharSelectInfo(); void FixUserInfo(); void FixCharInfo(); void FixAve(); void HookEnterWorld(); ~L2Ex(); private: HANDLE L2Server; DWORD dwProcessID; }; #endif