1 #ifndef OPENMW_AICOMBAT_ACTION_H
2 #define OPENMW_AICOMBAT_ACTION_H
4 #include <boost/shared_ptr.hpp>
8 #include "../mwworld/ptr.hpp"
9 #include "../mwworld/containerstore.hpp"
96 int type=-1,
float arrowRating=0.f,
float boltRating=0.f);
virtual float getCombatRange(bool &isRanged) const =0
Iteration over a subset of objects in a ContainerStore.
Definition: containerstore.hpp:196
virtual const ESM::Weapon * getWeapon() const
Definition: aicombataction.cpp:511
virtual float getCombatRange(bool &isRanged) const
Definition: aicombataction.cpp:454
virtual float getActionCooldown()
Since this action has no animation, apply a small cool down for using it.
Definition: aicombataction.hpp:72
Definition: aicombataction.hpp:14
ActionFlee()
Definition: aicombataction.hpp:29
Definition: aicombataction.hpp:37
ActionEnchantedItem(const MWWorld::ContainerStoreIterator &item)
Definition: aicombataction.hpp:51
virtual float getActionCooldown()
Definition: aicombataction.hpp:32
virtual float getCombatRange(bool &isRanged) const
Definition: aicombataction.cpp:487
Definition: loadspel.hpp:14
virtual float getActionCooldown()
Definition: aicombataction.hpp:20
virtual float getActionCooldown()
Since this action has no animation, apply a small cool down for using it.
Definition: aicombataction.hpp:58
virtual void prepare(const MWWorld::Ptr &actor)
Equips the given weapon.
Definition: aicombataction.cpp:466
virtual bool isAttackingOrSpell() const
Definition: aicombataction.hpp:22
float rateSpell(const ESM::Spell *spell, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:171
ActionWeapon(const MWWorld::Ptr &weapon, const MWWorld::Ptr &ammo=MWWorld::Ptr())
weapon may be empty for hand-to-hand combat
Definition: aicombataction.hpp:83
virtual ~Action()
Definition: aicombataction.hpp:17
float vanillaRateFlee(const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:874
Definition: aicombataction.hpp:75
virtual bool isFleeing() const
Definition: aicombataction.hpp:23
MWWorld::Ptr mPotion
Definition: aicombataction.hpp:65
Definition: effectlist.hpp:17
std::string mSpellId
Definition: aicombataction.hpp:41
virtual const ESM::Weapon * getWeapon() const
Definition: aicombataction.hpp:21
virtual void prepare(const MWWorld::Ptr &actor)
Sets the given item as selected enchanted item in the actor's InventoryStore.
Definition: aicombataction.cpp:440
MWWorld::ContainerStoreIterator mItem
Definition: aicombataction.hpp:52
virtual void prepare(const MWWorld::Ptr &actor)=0
ActionSpell(const std::string &spellId)
Definition: aicombataction.hpp:40
virtual float getCombatRange(bool &isRanged) const
Definition: aicombataction.cpp:431
float getDistanceMinusHalfExtents(const MWWorld::Ptr &actor1, const MWWorld::Ptr &actor2, bool minusZDist)
Definition: aicombataction.cpp:630
Definition: aicombataction.hpp:26
virtual bool isFleeing() const
Definition: aicombataction.hpp:34
float vanillaRateWeaponAndAmmo(const MWWorld::Ptr &weapon, const MWWorld::Ptr &ammo, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:838
virtual void prepare(const MWWorld::Ptr &actor)
Definition: aicombataction.hpp:30
float vanillaRateSpell(const ESM::Spell *spell, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:813
MWWorld::Ptr mAmmunition
Definition: aicombataction.hpp:78
virtual void prepare(const MWWorld::Ptr &actor)
Drinks the given potion.
Definition: aicombataction.cpp:460
float getMaxAttackDistance(const MWWorld::Ptr &actor)
Definition: aicombataction.cpp:645
float ratePotion(const MWWorld::Ptr &item, const MWWorld::Ptr &actor)
Definition: aicombataction.cpp:92
virtual float getCombatRange(bool &isRanged) const
Definition: aicombataction.hpp:31
boost::shared_ptr< Action > prepareNextAction(const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:518
virtual bool isAttackingOrSpell() const
Definition: aicombataction.hpp:69
Definition: aicombataction.hpp:48
float rateMagicItem(const MWWorld::Ptr &ptr, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:204
Pointer to a LiveCellRef.
Definition: ptr.hpp:19
virtual void prepare(const MWWorld::Ptr &actor)
Sets the given spell as selected on the actor's spell list.
Definition: aicombataction.cpp:420
virtual bool isAttackingOrSpell() const
Definition: aicombataction.hpp:33
Definition: aicombataction.hpp:61
float rateEffects(const ESM::EffectList &list, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:409
EffectList, ENAM subrecord.
Definition: effectlist.hpp:33
virtual float getCombatRange(bool &isRanged) const
Definition: aicombataction.cpp:447
bool canFight(const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:749
bool makeFleeDecision(const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy, float antiFleeRating)
Definition: aicombataction.cpp:904
float rateEffect(const ESM::ENAMstruct &effect, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy)
Definition: aicombataction.cpp:222
ActionPotion(const MWWorld::Ptr &potion)
Definition: aicombataction.hpp:64
MWWorld::Ptr mWeapon
Definition: aicombataction.hpp:79
Definition: loadweap.hpp:16
float rateWeapon(const MWWorld::Ptr &item, const MWWorld::Ptr &actor, const MWWorld::Ptr &enemy, int type, float arrowRating, float boltRating)
Definition: aicombataction.cpp:101