1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-15 22:19:54 +00:00
openmw-tes3mp/apps/openmw/mwmp/LocalActor.hpp

62 lines
1.7 KiB
C++
Raw Normal View History

#ifndef OPENMW_LOCALACTOR_HPP
#define OPENMW_LOCALACTOR_HPP
#include <components/openmw-mp/Base/BaseActor.hpp>
#include "../mwmechanics/creaturestats.hpp"
2017-04-06 01:00:50 +00:00
#include "../mwworld/manualref.hpp"
#include "../mwworld/timestamp.hpp"
namespace mwmp
{
class LocalActor : public BaseActor
{
public:
LocalActor();
virtual ~LocalActor();
void update(bool forceUpdate);
2017-04-06 01:00:50 +00:00
void updateCell();
void updatePosition(bool forceUpdate);
void updateAnimFlags(bool forceUpdate);
void updateAnimPlay();
void updateSpeech();
void updateStatsDynamic(bool forceUpdate);
void updateEquipment(bool forceUpdate, bool sendImmediately = false);
void updateAttackOrCast();
void sendEquipment();
void sendSpellsActiveAddition(const std::string id, bool isStackingSpell, ESM::ActiveSpells::ActiveSpellParams params, MWWorld::TimeStamp timestamp);
void sendSpellsActiveRemoval(const std::string id, bool isStackingSpell, MWWorld::TimeStamp timestamp);
void sendDeath(char newDeathState);
2017-04-06 01:00:50 +00:00
MWWorld::Ptr getPtr();
void setPtr(const MWWorld::Ptr& newPtr);
bool hasSentData;
2017-04-06 01:00:50 +00:00
private:
MWWorld::Ptr ptr;
bool posWasChanged;
bool equipmentChanged;
bool wasRunning;
bool wasSneaking;
bool wasForceJumping;
bool wasForceMoveJumping;
bool wasJumping;
bool wasFlying;
MWMechanics::DrawState_ lastDrawState;
MWMechanics::DynamicStat<float> oldHealth;
MWMechanics::DynamicStat<float> oldMagicka;
MWMechanics::DynamicStat<float> oldFatigue;
};
}
#endif //OPENMW_LOCALACTOR_HPP