2017-05-16 16:25:31 +00:00
|
|
|
#include <components/openmw-mp/NetworkMessages.hpp>
|
2019-08-19 18:39:33 +00:00
|
|
|
#include <components/openmw-mp/TimedLog.hpp>
|
2017-05-16 16:25:31 +00:00
|
|
|
#include "PacketActorEquipment.hpp"
|
|
|
|
|
|
|
|
using namespace mwmp;
|
|
|
|
|
|
|
|
PacketActorEquipment::PacketActorEquipment(RakNet::RakPeerInterface *peer) : ActorPacket(peer)
|
|
|
|
{
|
|
|
|
packetID = ID_ACTOR_EQUIPMENT;
|
|
|
|
}
|
|
|
|
|
2017-06-02 19:42:10 +00:00
|
|
|
void PacketActorEquipment::Actor(BaseActor &actor, bool send)
|
2017-05-16 16:25:31 +00:00
|
|
|
{
|
2018-04-20 19:46:16 +00:00
|
|
|
for (auto &&equipmentItem : actor.equipmentItems)
|
2017-05-16 16:25:31 +00:00
|
|
|
{
|
2018-04-20 19:46:16 +00:00
|
|
|
RW(equipmentItem.refId, send);
|
|
|
|
RW(equipmentItem.count, send);
|
|
|
|
RW(equipmentItem.charge, send);
|
|
|
|
RW(equipmentItem.enchantmentCharge, send);
|
2017-05-16 16:25:31 +00:00
|
|
|
}
|
|
|
|
}
|