1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-24 20:23:51 +00:00
openmw-tes3mp/apps/openmw/mwmp/processors/player/ProcessorPlayerAttack.hpp

28 lines
673 B
C++
Raw Normal View History

2017-04-16 07:00:25 +00:00
#ifndef OPENMW_PROCESSORPLAYERATTACK_HPP
#define OPENMW_PROCESSORPLAYERATTACK_HPP
2017-04-18 04:17:58 +00:00
#include "apps/openmw/mwmp/Main.hpp"
2017-06-06 16:06:10 +00:00
#include "../PlayerProcessor.hpp"
2017-04-18 04:17:58 +00:00
#include "apps/openmw/mwmp/MechanicsHelper.hpp"
2017-04-16 07:00:25 +00:00
namespace mwmp
{
class ProcessorPlayerAttack final: public PlayerProcessor
2017-04-16 07:00:25 +00:00
{
public:
ProcessorPlayerAttack()
{
BPP_INIT(ID_PLAYER_ATTACK)
}
virtual void Do(PlayerPacket &packet, BasePlayer *player)
{
if (player != 0)
MechanicsHelper::processAttack(player->attack, static_cast<DedicatedPlayer*>(player)->getPtr());
2017-04-16 07:00:25 +00:00
}
};
}
#endif //OPENMW_PROCESSORPLAYERATTACK_HPP