File src/region.c

References Functions: expire_gas_cloud()src/region.c
  inside_gas_cloud()src/region.c

Included Files


Preprocessor definitions

#define NO_CALLBACK 1

#define INSIDE_GAS_CLOUD 0

#define EXPIRE_GAS_CLOUD 1


Local Variables

regions
static NhRegion** regions
Used in: add_region()
  clear_regions()
  in_out_region()
  m_in_out_region()
  remove_region()
  rest_regions()
  run_regions()
  save_regions()
  update_monster_region()
  update_player_regions()
  visible_region_at()

n_regions
static int n_regions
Used in: add_region()
  clear_regions()
  in_out_region()
  m_in_out_region()
  remove_region()
  rest_regions()
  run_regions()
  save_regions()
  update_monster_region()
  update_player_regions()
  visible_region_at()

max_regions
static int max_regions
Used in: add_region()
  clear_regions()
  rest_regions()

callbacks
static callback_proc callbacks[]
Used in: in_out_region()
  m_in_out_region()
  run_regions()


Global Function add_mon_to_reg()

void add_mon_to_reg ( NhRegion* reg, struct monst* mon )
Prototyped in: src/region.c
Calls: alloc()src/alloc.c
  free()
Called by: add_region()src/region.c
  m_in_out_region()src/region.c
  update_monster_region()src/region.c

Global Function add_rect_to_reg()

void add_rect_to_reg ( NhRegion* reg, NhRect* rect )
Prototyped in: src/region.c
Calls: alloc()src/alloc.c
  free(), memcpy()
Called by: create_gas_cloud()src/region.c

Global Function add_region()

void add_region ( NhRegion* reg )
Prototyped in: src/region.c
Calls: add_mon_to_reg()src/region.c
  alloc()src/alloc.c
  inside_region()src/region.c
  isok()src/cmd.c
  newsym()src/display.c
  free(), memcpy()
Called by: create_gas_cloud()src/region.c
References Variables: levelsrc/decl.c
  max_regionssrc/region.c
  n_regionssrc/region.c
  regionssrc/region.c
  usrc/decl.c
  viz_arraysrc/decl.c

Global Function clear_regions()

void clear_regions ( void )
Prototyped in: include/extern.h
Calls: free_region()src/region.c
  free()
Called by: clear_level_structures()src/mklev.c
  rest_regions()src/region.c
References Variables: max_regionssrc/region.c
  n_regionssrc/region.c
  regionssrc/region.c

Global Function create_gas_cloud()

NhRegion* create_gas_cloud ( xchar x, xchar y, int radius, int damage )
Prototyped in: include/extern.h
Calls: add_rect_to_reg()src/region.c
  add_region()src/region.c
  create_region()src/region.c
  rn2()
Called by: seffects()src/read.c

Global Function create_region()

NhRegion* create_region ( NhRect* rects, int nrect )
Prototyped in: src/region.c
Calls: alloc()src/alloc.c
Called by: create_gas_cloud()src/region.c

Global Function expire_gas_cloud()

boolean expire_gas_cloud ( genericptr_t p1, genericptr_t p2 )
Prototyped in: src/region.c
Used in:  src/region.c

Global Function free_region()

void free_region ( NhRegion* reg )
Prototyped in: src/region.c
Calls: free()
Called by: clear_regions()src/region.c
  remove_region()src/region.c

Global Function in_out_region()

boolean in_out_region ( xchar x, xchar y )
Prototyped in: include/extern.h
Calls: inside_region()src/region.c
  pline()src/pline.c
Called by: domove()src/hack.c
References Variables: callbackssrc/region.c
  n_regionssrc/region.c
  regionssrc/region.c

Global Function inside_gas_cloud()

boolean inside_gas_cloud ( genericptr_t p1, genericptr_t p2 )
Prototyped in: src/region.c
Calls: Monnam()src/do_name.c
  You()src/pline.c
  body_part()src/polyself.c
  killed()src/mon.c
  losehp()src/hack.c
  make_blinded()src/potion.c
  makeplural()src/objnam.c
  pline()src/pline.c
  setmangry()src/mon.c
  rnd()
Used in:  src/region.c
References Variables: c_common_stringssrc/decl.c
  usrc/decl.c
  ublindfsrc/decl.c
  viz_arraysrc/decl.c
  youmonstsrc/decl.c

Global Function inside_rect()

boolean inside_rect ( NhRect* r, int x, int y )
Prototyped in: src/region.c
Called by: inside_region()src/region.c

Global Function inside_region()

boolean inside_region ( NhRegion* reg, int x, int y )
Prototyped in: src/region.c
Calls: inside_rect()src/region.c
Called by: add_region()src/region.c
  in_out_region()src/region.c
  m_in_out_region()src/region.c
  remove_region()src/region.c
  update_monster_region()src/region.c
  update_player_regions()src/region.c
  visible_region_at()src/region.c

Global Function m_in_out_region()

boolean m_in_out_region ( struct monst* mon, xchar x, xchar y )
Prototyped in: include/extern.h
Calls: add_mon_to_reg()src/region.c
  inside_region()src/region.c
  mon_in_region()src/region.c
  remove_mon_from_reg()src/region.c
Called by: dog_move()src/dogmove.c
  kickdmg()src/dokick.c
  m_move()src/monmove.c
References Variables: callbackssrc/region.c
  n_regionssrc/region.c
  regionssrc/region.c

Global Function mon_in_region()

boolean mon_in_region ( NhRegion* reg, struct monst* mon )
Prototyped in: src/region.c
Called by: m_in_out_region()src/region.c
  update_monster_region()src/region.c

Global Function remove_mon_from_reg()

void remove_mon_from_reg ( NhRegion* reg, struct monst* mon )
Prototyped in: src/region.c
Called by: m_in_out_region()src/region.c
  update_monster_region()src/region.c

Global Function remove_region()

void remove_region ( NhRegion* reg )
Prototyped in: src/region.c
Calls: free_region()src/region.c
  inside_region()src/region.c
  isok()src/cmd.c
  newsym()src/display.c
Called by: rest_regions()src/region.c
  run_regions()src/region.c
References Variables: n_regionssrc/region.c
  regionssrc/region.c
  viz_arraysrc/decl.c

Global Function rest_regions()

void rest_regions ( int fd )
Prototyped in: include/extern.h
Calls: alloc()src/alloc.c
  clear_regions()src/region.c
  remove_region()src/region.c
  mread()
References Variables: max_regionssrc/region.c
  movessrc/decl.c
  n_regionssrc/region.c
  regionssrc/region.c

Global Function run_regions()

void run_regions ( void )
Prototyped in: include/extern.h
Calls: find_mid()src/light.c
  remove_region()src/region.c
Called by: moveloop()src/allmain.c
References Variables: callbackssrc/region.c
  n_regionssrc/region.c
  regionssrc/region.c

Global Function save_regions()

* save_regions :

void save_regions ( int fd, int mode )
Prototyped in: include/extern.h
Calls: bwrite(), strlen()
References Variables: movessrc/decl.c
  n_regionssrc/region.c
  regionssrc/region.c


Global Function show_region()

void show_region ( NhRegion* reg, xchar x, xchar y )
Prototyped in: include/extern.h
Calls: show_glyph()src/display.c
Called by: newsym()src/display.c

Global Function update_monster_region()

void update_monster_region ( struct monst* mon )
Prototyped in: include/extern.h
Calls: add_mon_to_reg()src/region.c
  inside_region()src/region.c
  mon_in_region()src/region.c
  remove_mon_from_reg()src/region.c
Called by: do_entity()src/dbridge.c
References Variables: n_regionssrc/region.c
  regionssrc/region.c

Global Function update_player_regions()

void update_player_regions ( void )
Prototyped in: include/extern.h
Calls: inside_region()src/region.c
References Variables: n_regionssrc/region.c
  regionssrc/region.c
  usrc/decl.c

Global Function visible_region_at()

NhRegion* visible_region_at ( xchar x, xchar y )
Prototyped in: include/extern.h
Calls: inside_region()src/region.c
Called by: newsym()src/display.c
References Variables: n_regionssrc/region.c
  regionssrc/region.c