2017-04-11 08:37:38 +00:00
|
|
|
#include <components/openmw-mp/NetworkMessages.hpp>
|
|
|
|
#include <components/openmw-mp/Log.hpp>
|
|
|
|
#include "PacketActorAttack.hpp"
|
|
|
|
|
|
|
|
using namespace mwmp;
|
|
|
|
|
|
|
|
PacketActorAttack::PacketActorAttack(RakNet::RakPeerInterface *peer) : ActorPacket(peer)
|
|
|
|
{
|
|
|
|
packetID = ID_ACTOR_ATTACK;
|
|
|
|
}
|
|
|
|
|
2017-06-02 19:42:10 +00:00
|
|
|
void PacketActorAttack::Actor(BaseActor &actor, bool send)
|
2017-04-11 08:37:38 +00:00
|
|
|
{
|
2017-06-02 19:42:10 +00:00
|
|
|
RW(actor.attack.target.refNumIndex, send);
|
|
|
|
RW(actor.attack.target.mpNum, send);
|
|
|
|
RW(actor.attack.target.guid, send);
|
|
|
|
|
|
|
|
RW(actor.attack.spellId, send);
|
|
|
|
RW(actor.attack.type, send);
|
|
|
|
RW(actor.attack.success, send);
|
|
|
|
RW(actor.attack.damage, send);
|
|
|
|
|
|
|
|
RW(actor.attack.pressed, send);
|
|
|
|
RW(actor.attack.knockdown, send);
|
|
|
|
RW(actor.attack.block, send);
|
2017-04-11 08:37:38 +00:00
|
|
|
}
|