1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-15 23:49:55 +00:00
openmw-tes3mp/components/openmw-mp/Packets/Worldstate/PacketWorldTime.cpp

24 lines
583 B
C++
Raw Normal View History

2016-08-30 05:24:31 +00:00
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketWorldTime.hpp"
2016-08-30 05:24:31 +00:00
using namespace mwmp;
PacketWorldTime::PacketWorldTime(RakNet::RakPeerInterface *peer) : WorldstatePacket(peer)
2016-08-30 05:24:31 +00:00
{
packetID = ID_WORLD_TIME;
orderChannel = CHANNEL_WORLDSTATE;
2016-08-30 05:24:31 +00:00
}
void PacketWorldTime::Packet(RakNet::BitStream *bs, bool send)
2016-08-30 05:24:31 +00:00
{
WorldstatePacket::Packet(bs, send);
2016-08-30 05:24:31 +00:00
RW(worldstate->hour, send);
RW(worldstate->day, send);
RW(worldstate->month, send);
RW(worldstate->year, send);
RW(worldstate->daysPassed, send);
RW(worldstate->timeScale, send);
}