My Project
 
Loading...
Searching...
No Matches
Shopkeeper Class Reference

#include <mob.h>

Inheritance diagram for Shopkeeper:
Collaboration diagram for Shopkeeper:

Public Member Functions

 Shopkeeper ()
 
 CLASSNAME (Shopkeeper)
 
virtual CharSpriteSprite ()
 
virtual void damage (int dmg, const std::string &src)
 
virtual void add (Buff *buff)
 
virtual boolean reset ()
 
virtual String description ()
 
virtual void interact ()
 
- Public Member Functions inherited from NPC
 NPC ()
 
virtual void beckon (int cell)
 
- Public Member Functions inherited from Mob
 Mob ()
 
virtual void storeInBundle (Bundle *bundle)
 
virtual void restoreFromBundle (Bundle *bundle)
 
virtual void remove (Buff *buff)
 
virtual void move (int step)
 
virtual void onAttackComplete ()
 
virtual int defenseSkill (Char *enemy)
 
virtual int defenseProc (Char *enemy, int damage)
 
void aggro (Char *ch)
 
virtual void notice ()
 
void yell (const std::string &str)
 
virtual void destroy ()
 
int exp ()
 
virtual void die (const std::string &str)
 
- Public Member Functions inherited from Char
 Char ()
 
 CLASSOBJECT (Char)
 
HashSet< std::string > & resistances ()
 
HashSet< std::string > & immunities ()
 
bool immunitiesContain (const std::string &cls)
 
void add (Buff *buff)
 
void remove (Buff *buff)
 
void remove (const std::string &buffClass)
 
bool attack (Char *enemy)
 
virtual int attackSkill (Char *target)
 
virtual std::string defenseVerb ()
 
virtual int dr ()
 
virtual int damageRoll ()
 
virtual int attackProc (Char *enemy, int damage)
 
float speed ()
 
void destroy ()
 
bool isAlive ()
 
void Buffs (const std::string &c, std::set< Buff * > &re)
 
Buffbuff (const std::string &c)
 
std::set< Buff * > buffSet (const std::string &c)
 
bool isCharmedBy (Char *ch)
 
void updateSpriteState ()
 
virtual int stealth ()
 
int distance (Char *other)
 
void onMotionComplete ()
 
void onAttackComplete ()
 
void onOperateComplete ()
 
- Public Member Functions inherited from Actor
 Actor ()
 
int Id ()
 
void next ()
 
- Public Member Functions inherited from Object
virtual std::string getObject ()=0
 

Static Public Member Functions

static WndBagsell ()
 
- Static Public Member Functions inherited from Char
static bool hit (Char *attacker, Char *defender, bool magic)
 
- Static Public Member Functions inherited from Actor
static void fixTime ()
 
static void clear ()
 
static CharfindChar (int pos)
 
static ActorfindById (int id)
 
static void init ()
 
static void addDelayed (Actor *actor, float delay)
 
static void remove (Actor *actor)
 
static void add (Actor *actor)
 
static void occupyCell (Char *ch)
 
static void freeCell (int pos)
 
static void process ()
 

Protected Member Functions

virtual boolean act ()
 
void flee ()
 
- Protected Member Functions inherited from NPC
void throwItem ()
 
- Protected Member Functions inherited from Mob
CharchooseEnemy ()
 
bool moveSprite (int from, int to)
 
virtual bool canAttack (Char *enemy)
 
virtual bool getCloser (int target)
 
virtual bool getFurther (int target)
 
virtual float attackDelay ()
 
virtual bool doAttack (Char *enemy)
 
- Protected Member Functions inherited from Char
virtual void spend (float time)
 
virtual void onRemove ()
 
- Protected Member Functions inherited from Actor
void postpone (float time)
 
float cooldown ()
 
void diactivate ()
 
virtual void onAdd ()
 

Additional Inherited Members

- Public Attributes inherited from Mob
bool hostile
 
AiStateSLEEPEING
 
AiStateHUNTING
 
AiStateWANDERING
 
AiStateFLEEING
 
AiStatePASSIVE
 
AiStatestate
 
- Public Attributes inherited from Char
int pos
 
std::string name
 
int HT
 
int HP
 
CharSpritesprite
 
bool paralysed
 
bool rooted
 
bool flying
 
int invisible
 
int viewDistance
 
std::set< Buff * > buffs
 
- Static Public Attributes inherited from Actor
static const int TICK = 1
 
static HashSet< Actor * > all
 
- Protected Attributes inherited from Mob
int target
 
int _defenseSkill
 
int EXP
 
int maxLvl
 
Charenemy
 
bool enemySeen
 
bool alerted
 
float lootChance
 
- Protected Attributes inherited from Char
float baseSpeed
 
- Static Protected Attributes inherited from Mob
static const String TXT_ECHO = "echo of "
 
static const String TXT_NOTICE1 = "?!"
 
static const String TXT_RAGE = "#$%^"
 
static const String TXT_EXP = "%+dEXP"
 
static const float TIME_TO_WAKE_UP = 1.0f
 
- Static Protected Attributes inherited from Char
static const std::string TXT_HIT = BPT::getText("lang.s_hit_s")
 
static const std::string TXT_KILL = BPT::getText("lang.killed_you")
 
static const std::string TXT_DEFEAT = BPT::getText("lang.s_defeated_s")
 

Constructor & Destructor Documentation

◆ Shopkeeper()

Shopkeeper::Shopkeeper ( )
Here is the caller graph for this function:

Member Function Documentation

◆ act()

boolean Shopkeeper::act ( )
protectedvirtual

Reimplemented from Mob.

Here is the call graph for this function:

◆ add()

virtual void Shopkeeper::add ( Buff * buff)
inlinevirtual

Reimplemented from Mob.

Here is the call graph for this function:

◆ CLASSNAME()

Shopkeeper::CLASSNAME ( Shopkeeper )
Here is the call graph for this function:

◆ damage()

virtual void Shopkeeper::damage ( int dmg,
const std::string & src )
inlinevirtual

Reimplemented from Mob.

Here is the call graph for this function:

◆ description()

virtual String Shopkeeper::description ( )
inlinevirtual

Reimplemented from Mob.

Here is the call graph for this function:

◆ flee()

void Shopkeeper::flee ( )
protected
Here is the call graph for this function:
Here is the caller graph for this function:

◆ interact()

virtual void Shopkeeper::interact ( )
inlinevirtual

Implements NPC.

Here is the call graph for this function:

◆ reset()

virtual boolean Shopkeeper::reset ( )
inlinevirtual

◆ sell()

WndBag * Shopkeeper::sell ( )
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ Sprite()

CharSprite * Shopkeeper::Sprite ( )
virtual

Implements Mob.


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