File interpreter.c

* Routines to handle aliasing *

References Functions: do_action()act.social.c
  do_advance()act.wizard.c
  do_alias()interpreter.c
  do_assist()act.offensive.c
  do_at()act.wizard.c
  do_backstab()act.offensive.c
  do_ban()ban.c
  do_bash()act.offensive.c
  do_cast()spell_parser.c
  do_color()act.informative.c
  do_commands()act.informative.c
  do_consider()act.informative.c
  do_date()act.wizard.c
  do_dc()act.wizard.c
  do_diagnose()act.informative.c
  do_display()act.other.c
  do_drink()act.item.c
  do_drop()act.item.c
  do_eat()act.item.c
  do_echo()act.wizard.c
  do_enter()act.movement.c
  do_equipment()act.informative.c
  do_examine()act.informative.c
  do_exits()act.informative.c
  do_flee()act.offensive.c
  do_follow()act.movement.c
  do_force()act.wizard.c
  do_gecho()act.wizard.c
  do_gen_comm()act.comm.c
  do_gen_door()act.movement.c
  do_gen_ps()act.informative.c
  do_gen_tog()act.other.c
  do_gen_write()act.other.c
  do_get()act.item.c
  do_give()act.item.c
  do_gold()act.informative.c
  do_goto()act.wizard.c
  do_grab()act.item.c
  do_group()act.other.c
  do_gsay()act.comm.c
  do_hcontrol()house.c
  do_help()act.informative.c
  do_hide()act.other.c
  do_hit()act.offensive.c
  do_house()house.c
  do_insult()act.social.c
  do_inventory()act.informative.c
  do_invis()act.wizard.c
  do_kick()act.offensive.c
  do_kill()act.offensive.c
  do_last()act.wizard.c
  do_leave()act.movement.c
  do_levels()act.informative.c
  do_load()act.wizard.c
  do_look()act.informative.c
  do_move()act.movement.c
  do_not_here()act.other.c
  do_olc()olc.c
  do_order()act.offensive.c
  do_page()act.comm.c
  do_poofset()act.wizard.c
  do_pour()act.item.c
  do_practice()act.other.c
  do_purge()act.wizard.c
  do_put()act.item.c
  do_qcomm()act.comm.c
  do_quit()act.other.c
  do_reboot()db.c
  do_remove()act.item.c
  do_reply()act.comm.c
  do_report()act.other.c
  do_rescue()act.offensive.c
  do_rest()act.movement.c
  do_restore()act.wizard.c
  do_return()act.wizard.c
  do_save()act.other.c
  do_say()act.comm.c
  do_score()act.informative.c
  do_send()act.wizard.c
  do_set()act.wizard.c
  do_show()act.wizard.c
  do_shutdown()act.wizard.c
  do_sit()act.movement.c
  do_skillset()modify.c
  do_sleep()act.movement.c
  do_sneak()act.other.c
  do_snoop()act.wizard.c
  do_spec_comm()act.comm.c
  do_split()act.other.c
  do_stand()act.movement.c
  do_stat()act.wizard.c
  do_steal()act.other.c
  do_switch()act.wizard.c
  do_syslog()act.wizard.c
  do_teleport()act.wizard.c
  do_tell()act.comm.c
  do_time()act.informative.c
  do_title()act.other.c
  do_toggle()act.informative.c
  do_track()graph.c
  do_trans()act.wizard.c
  do_unban()ban.c
  do_ungroup()act.other.c
  do_use()act.other.c
  do_users()act.informative.c
  do_visible()act.other.c
  do_vnum()act.wizard.c
  do_vstat()act.wizard.c
  do_wake()act.movement.c
  do_wear()act.item.c
  do_weather()act.informative.c
  do_where()act.informative.c
  do_who()act.informative.c
  do_wield()act.item.c
  do_wimpy()act.other.c
  do_wizlock()act.wizard.c
  do_wiznet()act.wizard.c
  do_wizutil()act.wizard.c
  do_write()act.comm.c
  do_zreset()act.wizard.c


Included Files


Preprocessor definitions

#define __INTERPRETER_C__

#define NUM_TOKENS 9

#define RECON 1

#define USURP 2

#define UNSWITCH 3


Global Variable cmd_info

const struct command_info cmd_info[]
Visible in:  act.comm.c
   act.informative.c
   act.item.c
   act.movement.c
   act.offensive.c
   act.other.c
   act.social.c
   act.wizard.c
   alias.c
   ban.c
   boards.c
   castle.c
   class.c
   comm.c
   config.c
   constants.c
   db.c
   fight.c
   graph.c
   handler.c
   house.c
   interpreter.c
   limits.c
   magic.c
   mail.c
   mobact.c
   modify.c
   objsave.c
   olc.c
   shop.c
   spec_assign.c
   spec_procs.c
   spell_parser.c
   spells.c
   utils.c
   weather.c
Used in: bank()spec_procs.c
  boot_social_messages()act.social.c
  command_interpreter()interpreter.c
  do_commands()act.informative.c
  do_gen_write()act.other.c
  do_qcomm()act.comm.c
  do_use()act.other.c
  dump()spec_procs.c
  find_command()interpreter.c
  gen_receptionist()objsave.c
  guild()spec_procs.c
  guild_guard()spec_procs.c
  pet_shops()spec_procs.c
  postmaster()mail.c
  shop_keeper()shop.c
  sort_commands()act.informative.c

Global Variable fill

const char* fill[]
Visible in:  interpreter.c
Used in: fill_word()interpreter.c

Global Variable reserved

const char* reserved[]
Visible in:  interpreter.c
Used in: reserved_word()interpreter.c

External Variables

r_mortal_start_room
extern room_rnum r_mortal_start_room
Defined in: db.c

r_immort_start_room
extern room_rnum r_immort_start_room
Defined in: db.c

r_frozen_start_room
extern room_rnum r_frozen_start_room
Defined in: db.c

class_menu
extern const char* class_menu
Defined in: class.c

motd
extern char* motd
Defined in: db.c

imotd
extern char* imotd
Defined in: db.c

background
extern char* background
Defined in: db.c

MENU
extern char* MENU
Defined in: config.c

WELC_MESSG
extern char* WELC_MESSG
Defined in: config.c

START_MESSG
extern char* START_MESSG
Defined in: config.c

character_list
extern struct char_data* character_list
Defined in: db.c

descriptor_list
extern struct descriptor_data* descriptor_list
Defined in: comm.c

player_table
extern struct player_index_element* player_table
Defined in: db.c

top_of_p_table
extern int top_of_p_table
Defined in: db.c

circle_restrict
extern int circle_restrict
Defined in: db.c

no_specials
extern int no_specials
Defined in: comm.c

max_bad_pws
extern int max_bad_pws
Defined in: config.c

mob_index
extern struct index_data* mob_index
Defined in: db.c

obj_index
extern struct index_data* obj_index
Defined in: db.c

world
extern struct room_data* world
Defined in: db.c


Global Function _parse_name()

int _parse_name ( char* arg, char* name )
Prototyped in: interpreter.c
Called by: nanny()interpreter.c

Global Function any_one_arg()

char* any_one_arg ( char* argument, char* first_arg )
Prototyped in: interpreter.h
Calls: skip_spaces()interpreter.c
Called by: command_interpreter()interpreter.c
  do_alias()interpreter.c
  find_skill_num()spell_parser.c
  half_chop()interpreter.c
  perform_alias()interpreter.c
  show_string()modify.c

Global Function command_interpreter()

void command_interpreter ( struct char_data* ch, char* argument )
Prototyped in: interpreter.h
Calls: any_one_arg()interpreter.c
  send_to_char()comm.c
  skip_spaces()interpreter.c
  special()interpreter.c
  strlen(), strncmp()
Called by: do_at()act.wizard.c
  do_force()act.wizard.c
  do_order()act.offensive.c
  game_loop()comm.c
References Variables: argdb.c
  cmd_infointerpreter.c
  no_specialscomm.c

Global Function delete_doubledollar()

char* delete_doubledollar ( char* string )
Prototyped in: interpreter.h
Calls: strchr()
Called by: Board_write_message()boards.c
  do_alias()interpreter.c
  do_gecho()act.wizard.c
  do_gen_write()act.other.c
  do_say()act.comm.c
  do_title()act.other.c
  do_wiznet()act.wizard.c
  string_add()modify.c

Global Function do_alias()

void do_alias ( struct char_data* ch, char* argument, int cmd, int subcmd )
Prototyped in: interpreter.c
Calls: any_one_arg()interpreter.c
  basic_mud_log()utils.c
  delete_doubledollar()interpreter.c
  find_alias()interpreter.c
  free_alias()interpreter.c
  send_to_char()comm.c
  str_cmp()utils.c
  str_dup()utils.c
  abort(), calloc(), perror(), sprintf(), strchr()
Used in:  interpreter.c
References Variables: argdb.c
  bufdb.c
  dummy_mobdb.c

Global Function fill_word()

int fill_word ( char* argument )
Prototyped in: interpreter.h
Calls: search_block()interpreter.c
Called by: nanny()interpreter.c
  one_argument()interpreter.c
  one_word()interpreter.c
References Variables: fillinterpreter.c

Global Function find_alias()

struct alias_data* find_alias ( struct alias_data* alias_list, char* str )
Prototyped in: interpreter.c
Calls: strcmp()
Called by: do_alias()interpreter.c
  perform_alias()interpreter.c

Global Function find_command()

int find_command ( const char* command )
Prototyped in: interpreter.h
Calls: strcmp()
Called by: assign_the_shopkeepers()shop.c
  boot_social_messages()act.social.c
  gen_receptionist()objsave.c
  init_boards()boards.c
  sort_commands()act.informative.c
References Variables: cmd_infointerpreter.c

Global Function find_name()

int find_name ( char* name )
Prototyped in: interpreter.c
Calls: str_cmp()utils.c
Called by: load_char()db.c
References Variables: player_tabledb.c
  top_of_p_tabledb.c

Global Function free_alias()

void free_alias ( struct alias_data* a )
Prototyped in: interpreter.c
Calls: free()
Called by: do_alias()interpreter.c
  free_char()db.c

Global Function half_chop()

void half_chop ( char* string, char* arg1, char* arg2 )
Prototyped in: interpreter.h
Calls: any_one_arg()interpreter.c
  skip_spaces()interpreter.c
  strcpy()
Called by: do_at()act.wizard.c
  do_force()act.wizard.c
  do_hcontrol()house.c
  do_look()act.informative.c
  do_olc()olc.c
  do_order()act.offensive.c
  do_page()act.comm.c
  do_send()act.wizard.c
  do_set()act.wizard.c
  do_spec_comm()act.comm.c
  do_stat()act.wizard.c
  do_tell()act.comm.c
  do_use()act.other.c
  do_users()act.informative.c
  do_vnum()act.wizard.c
  do_who()act.informative.c
  do_wiznet()act.wizard.c
  olc_interpreter()olc.c

Global Function is_abbrev()

int is_abbrev ( const char* arg1, const char* arg2 )
Prototyped in: interpreter.h
Called by: do_hcontrol()house.c
  do_load()act.wizard.c
  do_look()act.informative.c
  do_order()act.offensive.c
  do_stat()act.wizard.c
  do_vnum()act.wizard.c
  do_vstat()act.wizard.c
  find_skill_num()spell_parser.c
  process_input()comm.c

Global Function is_number()

int is_number ( const char* str )
Prototyped in: interpreter.h
Called by: do_drop()act.item.c
  do_get()act.item.c
  do_give()act.item.c
  do_put()act.item.c
  do_show()act.wizard.c
  do_split()act.other.c
  do_wiznet()act.wizard.c
  get_hash_obj_vis()shop.c
  get_purchase_obj()shop.c
  perform_set()act.wizard.c
  show_shops()shop.c
  transaction_amt()shop.c

Global Function nanny()

void nanny ( struct descriptor_data* d, char* arg )
Prototyped in: interpreter.h
Calls: CAP()utils.c
  Crash_delete_file()objsave.c
  Crash_load()objsave.c
  MAX()utils.c
  Valid_Name()ban.c
  _parse_name()interpreter.c
  act()comm.c
  basic_mud_log()utils.c
  char_to_room()handler.c
  clear_char()db.c
  create_entry()db.c
  do_start()class.c
  echo_off()comm.c
  echo_on()comm.c
  fill_word()interpreter.c
  free_char()db.c
  has_mail()mail.c
  init_char()db.c
  isbanned()ban.c
  load_char()db.c
  look_at_room()act.informative.c
  mudlog()utils.c
  page_string()modify.c
  parse_class()class.c
  perform_dupe_check()interpreter.c
  read_aliases()alias.c
  real_room()db.c
  reserved_word()interpreter.c
  reset_char()db.c
  save_char()db.c
  send_to_char()comm.c
  skip_spaces()interpreter.c
  store_to_char()db.c
  str_cmp()utils.c
  write_to_output()comm.c
  abort(), calloc(), crypt(), free(), perror(), sprintf(), strcmp(), strcpy(), strlen(), strncmp(), strncpy()
Called by: game_loop()comm.c
References Variables: MENUconfig.c
  START_MESSGconfig.c
  WELC_MESSGconfig.c
  backgrounddb.c
  character_listdb.c
  circle_restrictdb.c
  class_menuclass.c
  dummy_mobdb.c
  imotddb.c
  max_bad_pwsconfig.c
  motddb.c
  r_frozen_start_roomdb.c
  r_immort_start_roomdb.c
  r_mortal_start_roomdb.c

Global Function one_argument()

char* one_argument ( char* argument, char* first_arg )
Prototyped in: interpreter.h
Calls: basic_mud_log()utils.c
  fill_word()interpreter.c
  skip_spaces()interpreter.c
Called by: Board_display_msg()boards.c
  Board_remove_msg()boards.c
  Board_show_board()boards.c
  do_action()act.social.c
  do_assist()act.offensive.c
  do_backstab()act.offensive.c
  do_bash()act.offensive.c
  do_cast()spell_parser.c
  do_color()act.informative.c
  do_commands()act.informative.c
  do_consider()act.informative.c
  do_dc()act.wizard.c
  do_diagnose()act.informative.c
  do_drink()act.item.c
  do_drop()act.item.c
  do_eat()act.item.c
  do_enter()act.movement.c
  do_examine()act.informative.c
  do_follow()act.movement.c
  do_get()act.item.c
  do_give()act.item.c
  do_grab()act.item.c
  do_group()act.other.c
  do_hit()act.offensive.c
  do_house()house.c
  do_insult()act.social.c
  do_invis()act.wizard.c
  do_kick()act.offensive.c
  do_kill()act.offensive.c
  do_last()act.wizard.c
  do_olc()olc.c
  do_practice()act.other.c
  do_purge()act.wizard.c
  do_put()act.item.c
  do_reboot()db.c
  do_remove()act.item.c
  do_rescue()act.offensive.c
  do_restore()act.wizard.c
  do_shutdown()act.wizard.c
  do_skillset()modify.c
  do_snoop()act.wizard.c
  do_split()act.other.c
  do_switch()act.wizard.c
  do_syslog()act.wizard.c
  do_track()graph.c
  do_trans()act.wizard.c
  do_unban()ban.c
  do_ungroup()act.other.c
  do_users()act.informative.c
  do_wake()act.movement.c
  do_where()act.informative.c
  do_wield()act.item.c
  do_wimpy()act.other.c
  do_wizlock()act.wizard.c
  do_wiznet()act.wizard.c
  do_wizutil()act.wizard.c
  do_zreset()act.wizard.c
  find_target_room()act.wizard.c
  generic_find()handler.c
  get_id_by_name()db.c
  get_ptable_by_name()db.c
  get_purchase_obj()shop.c
  hcontrol_build_house()house.c
  mag_objectmagic()spell_parser.c
  olc_bitvector()olc.c
  postmaster_send_mail()mail.c
  shopping_list()shop.c
  shopping_sell()shop.c
  shopping_value()shop.c
  transaction_amt()shop.c
  two_arguments()interpreter.c

Global Function one_word()

char* one_word ( char* argument, char* first_arg )
Prototyped in: interpreter.h
Calls: fill_word()interpreter.c
  skip_spaces()interpreter.c
Called by: count_alias_records()db.c
  load_help()db.c

Global Function perform_alias()

int perform_alias ( struct descriptor_data* d, char* orig )
Prototyped in: interpreter.c
Calls: any_one_arg()interpreter.c
  basic_mud_log()utils.c
  find_alias()interpreter.c
  perform_complex_alias()interpreter.c
  strcpy()
Called by: game_loop()comm.c
References Variables: dummy_mobdb.c

Global Function perform_complex_alias()

void perform_complex_alias ( struct txt_q* input_q, char* orig, struct alias_data* a )
Prototyped in: interpreter.c
Calls: write_to_q()comm.c
  strcpy(), strlen(), strtok()
Called by: perform_alias()interpreter.c
References Variables: bufdb.c
  buf2db.c

Global Function perform_dupe_check()

int perform_dupe_check ( struct descriptor_data* d )
Prototyped in: interpreter.c
Calls: MAX()utils.c
  act()comm.c
  basic_mud_log()utils.c
  char_from_room()handler.c
  char_to_room()handler.c
  extract_char()handler.c
  free_char()db.c
  mudlog()utils.c
  write_to_output()comm.c
  sprintf()
Called by: nanny()interpreter.c
References Variables: bufdb.c
  character_listdb.c
  descriptor_listcomm.c
  dummy_mobdb.c

Global Function reserved_word()

int reserved_word ( char* argument )
Prototyped in: interpreter.c
Calls: search_block()interpreter.c
Called by: nanny()interpreter.c
References Variables: reservedinterpreter.c

Global Function search_block()

int search_block ( char* arg, const char** list, int exact )
Prototyped in: interpreter.h
Calls: strcmp(), strncmp()
Called by: check_object()db.c
  do_color()act.informative.c
  do_look()act.informative.c
  do_olc()olc.c
  do_syslog()act.wizard.c
  fill_word()interpreter.c
  find_door()act.movement.c
  find_eq_pos()act.item.c
  hcontrol_build_house()house.c
  olc_bitvector()olc.c
  olc_interpreter()olc.c
  perform_set()act.wizard.c
  reserved_word()interpreter.c

Global Function skip_spaces()

void skip_spaces ( char** string )
Prototyped in: interpreter.h
Called by: Board_write_message()boards.c
  any_one_arg()interpreter.c
  command_interpreter()interpreter.c
  do_cast()spell_parser.c
  do_display()act.other.c
  do_echo()act.wizard.c
  do_gecho()act.wizard.c
  do_gen_comm()act.comm.c
  do_gen_door()act.movement.c
  do_gen_write()act.other.c
  do_gsay()act.comm.c
  do_help()act.informative.c
  do_poofset()act.wizard.c
  do_qcomm()act.comm.c
  do_reply()act.comm.c
  do_say()act.comm.c
  do_show()act.wizard.c
  do_skillset()modify.c
  do_title()act.other.c
  do_who()act.informative.c
  do_wiznet()act.wizard.c
  guild()spec_procs.c
  half_chop()interpreter.c
  load_zones()db.c
  nanny()interpreter.c
  olc_bitvector()olc.c
  olc_string()olc.c
  one_argument()interpreter.c
  one_word()interpreter.c
  process_input()comm.c

Global Function special()

int special ( struct char_data* ch, int cmd, char* arg )
Prototyped in: interpreter.c
Called by: command_interpreter()interpreter.c
  do_simple_move()act.movement.c
References Variables: mob_indexdb.c
  obj_indexdb.c
  top_of_worlddb.c
  worlddb.c

Global Function two_arguments()

char* two_arguments ( char* argument, char* first_arg, char* second_arg )
Prototyped in: interpreter.h
Calls: one_argument()interpreter.c
Called by: do_advance()act.wizard.c
  do_ban()ban.c
  do_gen_door()act.movement.c
  do_get()act.item.c
  do_load()act.wizard.c
  do_pour()act.item.c
  do_put()act.item.c
  do_show()act.wizard.c
  do_steal()act.other.c
  do_teleport()act.wizard.c
  do_vstat()act.wizard.c
  do_wear()act.item.c
  do_write()act.comm.c
  pet_shops()spec_procs.c