1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 01:49:54 +00:00
openmw-tes3mp/apps/openmw/mwmp/processors/BaseClientPacketProcessor.hpp

40 lines
822 B
C++
Raw Normal View History

2017-04-18 07:05:32 +00:00
#ifndef OPENMW_BASECLIENTPACKETPROCESSOR_HPP
#define OPENMW_BASECLIENTPACKETPROCESSOR_HPP
#include <components/openmw-mp/Base/BasePacketProcessor.hpp>
2017-06-06 16:06:10 +00:00
#include "../LocalPlayer.hpp"
#include "../DedicatedPlayer.hpp"
2017-04-18 07:05:32 +00:00
namespace mwmp
{
class BaseClientPacketProcessor
2017-04-18 07:05:32 +00:00
{
public:
static void SetServerAddr(RakNet::SystemAddress addr)
{
serverAddr = addr;
}
protected:
inline bool isRequest()
{
return request;
}
inline bool isLocal()
{
return guid == myGuid;
}
LocalPlayer *getLocalPlayer();
protected:
static RakNet::RakNetGUID guid, myGuid;
static RakNet::SystemAddress serverAddr;
static bool request;
};
}
#endif //OPENMW_BASECLIENTPACKETPROCESSOR_HPP