My Project
 
Loading...
Searching...
No Matches
KindOfWeapon Class Referenceabstract

#include <kindofweapon.h>

Inheritance diagram for KindOfWeapon:
Collaboration diagram for KindOfWeapon:

Public Member Functions

virtual void actions (Hero *hero, std::vector< std::string > &actions)
 
virtual bool isEquipped (Hero *hero)
 
virtual bool doEquip (Hero *hero)
 
virtual bool doUnequip (Hero *hero, bool collect, bool single)
 
virtual void activate (Hero *hero)
 
virtual int min ()=0
 
virtual int max ()=0
 
virtual int damageRoll (Hero *owner)
 
virtual float acuracyFactor (Hero *hero)
 
virtual float speedFactor (Hero *hero)
 
virtual void proc (Char *attacker, Char *defender, int damage)
 
- Public Member Functions inherited from EquipableItem
virtual void execute (Hero *hero, std::string action)
 
virtual void doDrop (Hero *hero)
 
virtual void cast (Hero *user, int dst)
 
virtual bool doUnequip (Hero *hero, bool collect)
 
- Public Member Functions inherited from Item
 CLASSNAME (Item)
 
 CLASSOBJECT (Item)
 
 Item ()
 
virtual bool doPickUp (Hero *hero)
 
virtual void doThrow (Hero *hero)
 
virtual std::string toString ()
 
virtual std::string Name ()
 
std::string trueName ()
 
int Image ()
 
Itemdetach (Bag *container)
 
ItemdetachAll (Bag *container)
 
virtual ItemSprite::Glowingglowing ()
 
virtual void storeInBundle (Bundle *bundle)
 
virtual void restoreFromBundle (Bundle *bundle)
 
virtual bool isUpgradable ()
 
virtual bool isIdentified ()
 
virtual int effectiveLevel ()
 
virtual std::string info ()
 
virtual std::string desc ()
 
virtual int price ()
 
int Quantity ()
 
void Quantity (int value)
 
virtual void getBroken ()
 
bool isBroken ()
 
virtual void fix ()
 
virtual int maxDurability (int lvl)
 
int maxDurability ()
 
int visiblyUpgraded ()
 
virtual Itemidentify ()
 
virtual Itemrandom ()
 
virtual void Level (int value)
 
int Level ()
 
virtual boolean collect (Bag *container)
 
void use ()
 
void updateQuickslot ()
 
virtual Itemupgrade ()
 
virtual Itemdegrade ()
 
Itemdegrade (int n)
 
int considerState (int price)
 
void polish ()
 
std::string status ()
 
- Public Member Functions inherited from Object
virtual std::string getObject ()=0
 

Static Protected Attributes

static const float TIME_TO_EQUIP = 1.0f
 
- Static Protected Attributes inherited from Item
static const float TIME_TO_THROW = 1.0f
 
static const float TIME_TO_PICK_UP = 1.0f
 
static const float TIME_TO_DROP = 0.5f
 
static const std::string AC_DROP = "lang.item_drop"
 
static const std::string AC_THROW = "lang.item_throw"
 
static CellSelector::Listenerthrower = new CellSelectorListenerNew()
 

Additional Inherited Members

- Static Public Member Functions inherited from Item
static void evoke (Hero *hero)
 
static ItemVirtual (const std::string &cl)
 
- Public Attributes inherited from Item
std::string defaultAction
 
std::string name = "smth"
 
int image = 0
 
bool stackable = false
 
bool levelKnown = false
 
bool cursed
 
bool cursedKnown
 
bool unique = false
 
int quantity
 
- Static Public Attributes inherited from EquipableItem
static const std::string AC_EQUIP = "EQUIP"
 
static const std::string AC_UNEQUIP = "UNEQUIP"
 
- Static Public Attributes inherited from Item
static HerocurUser
 
static ItemcurItem
 
- Protected Member Functions inherited from EquipableItem
virtual float time2equip (Hero *hero)
 
- Protected Member Functions inherited from Item
virtual void onThrow (int cell)
 
virtual void onDetach ()
 
- Static Protected Member Functions inherited from EquipableItem
static void equipCursed (Hero *hero)
 

Member Function Documentation

◆ actions()

void KindOfWeapon::actions ( Hero * hero,
std::vector< std::string > & actions )
virtual

Reimplemented from Item.

Reimplemented in MissileWeapon, ShortSword, Wand, and WandOfMagicMissile.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ activate()

virtual void KindOfWeapon::activate ( Hero * hero)
inlinevirtual

Reimplemented in Wand.

◆ acuracyFactor()

virtual float KindOfWeapon::acuracyFactor ( Hero * hero)
inlinevirtual

Reimplemented in Weapon.

Here is the caller graph for this function:

◆ damageRoll()

int KindOfWeapon::damageRoll ( Hero * owner)
virtual

Reimplemented in Weapon.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ doEquip()

bool KindOfWeapon::doEquip ( Hero * hero)
virtual

Implements EquipableItem.

Reimplemented in MissileWeapon.

◆ doUnequip()

bool KindOfWeapon::doUnequip ( Hero * hero,
bool collect,
bool single )
virtual

Reimplemented from EquipableItem.

Reimplemented in Wand.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isEquipped()

bool KindOfWeapon::isEquipped ( Hero * hero)
virtual

Reimplemented from Item.

Here is the caller graph for this function:

◆ max()

virtual int KindOfWeapon::max ( )
pure virtual

Implemented in Boomerang, CurareDart, Dart, IncendiaryDart, Javelin, MeleeWeapon, Shuriken, Tamahawk, and Wand.

Here is the caller graph for this function:

◆ min()

virtual int KindOfWeapon::min ( )
pure virtual

Implemented in Boomerang, CurareDart, Dart, IncendiaryDart, Javelin, MeleeWeapon, Shuriken, Tamahawk, and Wand.

Here is the caller graph for this function:

◆ proc()

virtual void KindOfWeapon::proc ( Char * attacker,
Char * defender,
int damage )
inlinevirtual

◆ speedFactor()

virtual float KindOfWeapon::speedFactor ( Hero * hero)
inlinevirtual

Reimplemented in Weapon.

Here is the caller graph for this function:

Member Data Documentation

◆ TIME_TO_EQUIP

const float KindOfWeapon::TIME_TO_EQUIP = 1.0f
staticprotected

The documentation for this class was generated from the following files: