Functions | Variables

mondata.c File Reference

#include "hack.h"
#include "eshk.h"
#include "epri.h"
Include dependency graph for mondata.c:

Functions

void set_mon_data (struct monst *mon, struct permonst *ptr, int flag)
struct attackattacktype_fordmg (struct permonst *ptr, int atyp, int dtyp)
boolean attacktype (struct permonst *ptr, int atyp)
boolean poly_when_stoned (struct permonst *ptr)
boolean resists_drli (struct monst *mon)
boolean resists_magm (struct monst *mon)
boolean resists_blnd (struct monst *mon)
boolean can_blnd (struct monst *magr, struct monst *mdef, uchar aatyp, struct obj *obj)
boolean ranged_attk (struct permonst *ptr)
boolean hates_silver (struct permonst *ptr)
boolean passes_bars (struct permonst *mptr)
boolean can_track (struct permonst *ptr)
boolean sliparm (struct permonst *ptr)
boolean breakarm (struct permonst *ptr)
boolean sticks (struct permonst *ptr)
int num_horns (struct permonst *ptr)
struct attackdmgtype_fromattack (struct permonst *ptr, int dtyp, int atyp)
boolean dmgtype (struct permonst *ptr, int dtyp)
int max_passive_dmg (struct monst *mdef, struct monst *magr)
int monsndx (struct permonst *ptr)
int name_to_mon (char *in_str) const
int gender (struct monst *mtmp)
int pronoun_gender (struct monst *mtmp)
boolean levl_follower (struct monst *mtmp)
int little_to_big (int montype)
int big_to_little (int montype)
struct permonstraceptr (struct monst *mtmp)
const char * locomotion (struct permonst *ptr, const char *def) const
const char * stagger (struct permonst *ptr, const char *def) const
const char * on_fire (struct permonst *mptr, struct attack *mattk)

Variables

static const short grownups [][2]
static const char * levitate [4] = { "float", "Float", "wobble", "Wobble" }
static const char * flys [4] = { "fly", "Fly", "flutter", "Flutter" }
static const char * flyl [4] = { "fly", "Fly", "stagger", "Stagger" }
static const char * slither [4] = { "slither", "Slither", "falter", "Falter" }
static const char * ooze [4] = { "ooze", "Ooze", "tremble", "Tremble" }
static const char * immobile [4] = { "wiggle", "Wiggle", "pulsate", "Pulsate" }
static const char * crawl [4] = { "crawl", "Crawl", "falter", "Falter" }

Function Documentation

boolean attacktype ( struct permonst ptr,
int  atyp 
)
struct attack* attacktype_fordmg ( struct permonst ptr,
int  atyp,
int  dtyp 
) [read]

References attack::aatyp, AD_ANY, attack::adtyp, and NATTK.

Referenced by attacktype(), and dobreathe().

Here is the caller graph for this function:

int big_to_little ( int  montype )

References grownups, and LOW_PM.

Referenced by dead_species(), and hatch_egg().

Here is the caller graph for this function:

boolean breakarm ( struct permonst ptr )

References bigmonst, humanoid, mons, MZ_SMALL, PM_MARILITH, PM_WINGED_GARGOYLE, and sliparm().

Referenced by break_armor(), and mon_break_armor().

Here is the call graph for this function:

Here is the caller graph for this function:

boolean can_blnd ( struct monst magr,
struct monst mdef,
uchar  aatyp,
struct obj obj 
)
boolean can_track ( struct permonst ptr )

References ART_EXCALIBUR, haseyes, obj::oartifact, TRUE, and uwep.

Referenced by m_move().

Here is the caller graph for this function:

boolean dmgtype ( struct permonst ptr,
int  dtyp 
)

References AT_ANY, dmgtype_fromattack(), FALSE, and TRUE.

Referenced by attack_checks(), cpostfx(), explmu(), find_offensive(), gulpmu(), hitmu(), montraits(), mrustm(), potionhit(), resists_magm(), stealarm(), sticks(), stumble_onto_mimic(), and urustm().

Here is the call graph for this function:

Here is the caller graph for this function:

struct attack* dmgtype_fromattack ( struct permonst ptr,
int  dtyp,
int  atyp 
) [read]

References attack::aatyp, attack::adtyp, AT_ANY, and NATTK.

Referenced by dmgtype(), and resists_blnd().

Here is the caller graph for this function:

int gender ( struct monst mtmp )

References is_neuter.

Referenced by could_seduce(), and steal_it().

Here is the caller graph for this function:

boolean hates_silver ( struct permonst ptr )

References is_demon, is_vampire, is_were, mons, PM_SHADE, PM_TENGU, and S_IMP.

Referenced by can_carry(), dmgval(), dogfood(), hmon_hitmon(), ohitmon(), select_hwep(), select_rwep(), thitu(), and use_misc().

Here is the caller graph for this function:

boolean levl_follower ( struct monst mtmp )

References FALSE, is_fshk(), M2_STALK, mon_has_amulet(), TRUE, u, and you::uhave.

Referenced by keepdogs().

Here is the call graph for this function:

Here is the caller graph for this function:

int little_to_big ( int  montype )

References grownups, and LOW_PM.

Referenced by can_be_hatched(), grow_up(), and learn_egg_type().

Here is the caller graph for this function:

const char* locomotion ( struct permonst ptr,
const char *  def 
) const

References amorphous, crawl, flyl, flys, highc(), immobile, is_floater, is_flyer, levitate, MZ_SMALL, nolimbs, ooze, slither, and slithy.

Referenced by check_special_room(), dodown(), domove(), dotele(), dotrap(), fig_transform(), hatch_egg(), hitmu(), level_tele_trap(), m_move(), monstone(), revive_corpse(), shopdig(), use_defensive(), and use_misc().

Here is the call graph for this function:

Here is the caller graph for this function:

int max_passive_dmg ( struct monst mdef,
struct monst magr 
)

References AD_ACID, AD_COLD, AD_ELEC, AD_FIRE, AD_PHYS, attack::adtyp, AT_BOOM, AT_NONE, NATTK, resists_acid, resists_cold, resists_elec, and resists_fire.

Referenced by dog_move().

Here is the caller graph for this function:

int monsndx ( struct permonst ptr )
int name_to_mon ( char *  in_str ) const
int num_horns ( struct permonst ptr )

References monsndx(), PM_ASMODEUS, PM_BALROG, PM_BLACK_UNICORN, PM_GRAY_UNICORN, PM_HORNED_DEVIL, PM_KI_RIN, PM_MINOTAUR, and PM_WHITE_UNICORN.

Referenced by break_armor(), and canwearobj().

Here is the call graph for this function:

Here is the caller graph for this function:

const char* on_fire ( struct permonst mptr,
struct attack mattk 
)
boolean passes_bars ( struct permonst mptr )

References amorphous, bigmonst, is_whirly, passes_walls, slithy, and verysmall.

Referenced by dog_move(), m_move(), and test_move().

Here is the caller graph for this function:

boolean poly_when_stoned ( struct permonst ptr )
int pronoun_gender ( struct monst mtmp )

References canspotmon, G_UNIQ, humanoid, is_neuter, and type_is_pname.

Referenced by mon_nam_too().

Here is the caller graph for this function:

struct permonst* raceptr ( struct monst mtmp ) [read]

References Race::malenum, mons, Upolyd, urace, and youmonst.

Referenced by racial_exception().

Here is the caller graph for this function:

boolean ranged_attk ( struct permonst ptr )
boolean resists_blnd ( struct monst mon )
boolean resists_drli ( struct monst mon )

References AD_DRLI, defends(), is_demon, is_undead, is_were, MON_WEP, mons, obj::oartifact, PM_DEATH, uwep, and youmonst.

Referenced by bhitm(), damageum(), losexp(), mdamagem(), and spec_applies().

Here is the call graph for this function:

Here is the caller graph for this function:

boolean resists_magm ( struct monst mon )

References AD_MAGM, AD_RBRE, ANTIMAGIC, defends(), dmgtype(), FALSE, invent, MON_WEP, mons, obj::nobj, obj::oartifact, objects, objclass::oc_oprop, obj::otyp, obj::owornmask, PM_BABY_GRAY_DRAGON, protects(), TRUE, uwep, and youmonst.

Referenced by bhitm(), explode(), mbhitm(), mintrap(), and zhitm().

Here is the call graph for this function:

Here is the caller graph for this function:

void set_mon_data ( struct monst mon,
struct permonst ptr,
int  flag 
)

References permonst::mresists.

Referenced by grow_up(), makemon(), new_were(), newcham(), and set_uasmon().

Here is the caller graph for this function:

boolean sliparm ( struct permonst ptr )

References is_whirly, MZ_SMALL, and noncorporeal.

Referenced by break_armor(), breakarm(), and mon_break_armor().

Here is the caller graph for this function:

const char* stagger ( struct permonst ptr,
const char *  def 
) const

References amorphous, crawl, flyl, flys, highc(), immobile, is_floater, is_flyer, levitate, MZ_SMALL, nolimbs, ooze, slither, and slithy.

Referenced by chest_trap(), damageum(), encumber_msg(), hmon_hitmon(), make_stunned(), mdamagem(), passivemm(), and passiveum().

Here is the call graph for this function:

Here is the caller graph for this function:

boolean sticks ( struct permonst ptr )

References AD_STCK, AD_WRAP, AT_HUGS, attacktype(), and dmgtype().

Referenced by damageum(), dog_move(), domove(), dountrap(), enlightenment(), float_down(), hitmu(), hmonas(), itsstuck(), known_hitum(), lookat(), Mb_hit(), monflee(), mstatusline(), newcham(), polyman(), polymon(), slept_monst(), tamedog(), and ustatusline().

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

const char* crawl[4] = { "crawl", "Crawl", "falter", "Falter" } [static]

Referenced by drown(), locomotion(), and stagger().

const char* flyl[4] = { "fly", "Fly", "stagger", "Stagger" } [static]

Referenced by locomotion(), and stagger().

const char* flys[4] = { "fly", "Fly", "flutter", "Flutter" } [static]

Referenced by locomotion(), and stagger().

const short grownups[][2] [static]

Referenced by big_to_little(), and little_to_big().

const char* immobile[4] = { "wiggle", "Wiggle", "pulsate", "Pulsate" } [static]
const char* levitate[4] = { "float", "Float", "wobble", "Wobble" } [static]

Referenced by locomotion(), and stagger().

const char* ooze[4] = { "ooze", "Ooze", "tremble", "Tremble" } [static]

Referenced by locomotion(), and stagger().

const char* slither[4] = { "slither", "Slither", "falter", "Falter" } [static]

Referenced by locomotion(), and stagger().