You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
openmw-tes3coop/components/openmw-mp/Packets/Worldstate/WorldstatePacket.cpp

32 lines
649 B
C++

#include <components/openmw-mp/NetworkMessages.hpp>
#include <PacketPriority.h>
#include <RakPeer.h>
#include "WorldstatePacket.hpp"
using namespace mwmp;
WorldstatePacket::WorldstatePacket(RakNet::RakPeerInterface *peer) : BasePacket(peer)
{
packetID = 0;
priority = HIGH_PRIORITY;
reliability = RELIABLE_ORDERED;
orderChannel = CHANNEL_WORLDSTATE;
this->peer = peer;
}
WorldstatePacket::~WorldstatePacket()
{
}
void WorldstatePacket::setWorldstate(BaseWorldstate *worldstate)
{
this->worldstate = worldstate;
guid = worldstate->guid;
}
BaseWorldstate *WorldstatePacket::getWorldstate()
{
return worldstate;
}