2016-01-12 03:41:44 +00:00
|
|
|
//
|
2016-09-28 12:20:23 +00:00
|
|
|
// Created by koncord on 13.01.16.
|
2016-01-12 03:41:44 +00:00
|
|
|
//
|
|
|
|
|
2017-04-16 06:00:18 +00:00
|
|
|
#include "PacketPlayerStatsDynamic.hpp"
|
2016-01-12 03:41:44 +00:00
|
|
|
#include <components/openmw-mp/NetworkMessages.hpp>
|
|
|
|
|
|
|
|
using namespace mwmp;
|
|
|
|
|
2017-04-16 06:00:18 +00:00
|
|
|
PacketPlayerStatsDynamic::PacketPlayerStatsDynamic(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
|
2016-01-12 03:41:44 +00:00
|
|
|
{
|
2017-04-16 06:00:18 +00:00
|
|
|
packetID = ID_PLAYER_STATS_DYNAMIC;
|
2016-01-12 03:41:44 +00:00
|
|
|
}
|
|
|
|
|
2017-04-16 06:00:18 +00:00
|
|
|
void PacketPlayerStatsDynamic::Packet(RakNet::BitStream *bs, bool send)
|
2016-01-12 03:41:44 +00:00
|
|
|
{
|
2017-03-06 09:44:08 +00:00
|
|
|
PlayerPacket::Packet(bs, send);
|
2017-01-25 15:06:15 +00:00
|
|
|
RW(player->creatureStats.mDynamic[0], send); // health
|
|
|
|
RW(player->creatureStats.mDynamic[1], send); // magic
|
|
|
|
RW(player->creatureStats.mDynamic[2], send); // fatigue
|
2017-01-26 04:17:29 +00:00
|
|
|
}
|