File act.wizard.c

The do_set function


Included Files

  • #include "conf.h"
  • #include "sysdep.h"
  • #include <stdio.h>
  • #include <ctype.h>
  • #include <stdlib.h>
  • #include <string.h>
  • #include <sys/types.h>
  • #include <unistd.h>
  • #include <limits.h>
  • #include <sys/time.h>
  • #include <assert.h>
  • #include "structs.h"
  • #include "utils.h"
  • #include "comm.h"
  • #include "interpreter.h"
  • #include "handler.h"
  • #include "db.h"
  • #include "spells.h"
  • #include "house.h"
  • #include "screen.h"

  • Preprocessor definitions

    #define GOD_ROOMS_ZONE 2

    #define PC 1

    #define NPC 2

    #define BOTH 3

    #define MISC 0

    #define BINARY 1

    #define NUMBER 2

    #define SET_OR_REMOVE( flagset, flags )

    #define RANGE( low, high )


    Type struct show_struct

    struct show_struct
    {
    char* cmd
    char level
    }

    Type struct set_struct

    struct set_struct
    {
    char* cmd
    char level
    char pcnpc
    char type
    }

    Global Variable set_fields

    struct set_struct {char* cmd;char level;char pcnpc;char type;} set_fields[]
    Visible in:
  • act.wizard.c
  • Used in:
  • do_set() : act.wizard.c
  • perform_set() : act.wizard.c

  • External Variables

    player_fl
    extern FILE* player_fl
    Defined in:
  • db.c
  • world
    extern struct room_data* world

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

    Defined in:
  • db.c
  • object_list
    extern struct obj_data* object_list

    Defined in:
  • db.c
  • descriptor_list
    extern struct descriptor_data* descriptor_list

    Defined in:
  • comm.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
  • int_app
    extern struct int_app_type int_app[]

    Defined in:
  • constants.c
  • wis_app
    extern struct wis_app_type wis_app[]

    Defined in:
  • constants.c
  • zone_table
    extern struct zone_data* zone_table

    Defined in:
  • db.c
  • top_of_zone_table
    extern int top_of_zone_table

    Defined in:
  • db.c
  • restrict
    extern int restrict

    Defined in:
  • db.c
  • top_of_world
    extern int top_of_world

    Defined in:
  • db.c
  • top_of_mobt
    extern int top_of_mobt

    Defined in:
  • db.c
  • top_of_objt
    extern int top_of_objt

    Defined in:
  • db.c
  • top_of_p_table
    extern int top_of_p_table

    Defined in:
  • db.c
  • item_types
    extern char* item_types[]

    Defined in:
  • constants.c
  • wear_bits
    extern char* wear_bits[]

    Defined in:
  • constants.c
  • extra_bits
    extern char* extra_bits[]

    Defined in:
  • constants.c
  • container_bits
    extern char* container_bits[]

    Defined in:
  • constants.c
  • drinks
    extern char* drinks[]

    Defined in:
  • constants.c
  • dirs
    extern char* dirs[]

    Defined in:
  • constants.c
  • room_bits
    extern char* room_bits[]

    Defined in:
  • constants.c
  • exit_bits
    extern char* exit_bits[]

    Defined in:
  • constants.c
  • sector_types
    extern char* sector_types[]

    Defined in:
  • constants.c
  • spells
    extern char* spells[]

    Defined in:
  • spell_parser.c
  • equipment_types
    extern char* equipment_types[]

    Defined in:
  • constants.c
  • affected_bits
    extern char* affected_bits[]

    Defined in:
  • constants.c
  • apply_types
    extern char* apply_types[]

    Defined in:
  • constants.c
  • pc_class_types
    extern char* pc_class_types[]

    Defined in:
  • class.c
  • npc_class_types
    extern char* npc_class_types[]

    Defined in:
  • constants.c
  • action_bits
    extern char* action_bits[]

    Defined in:
  • constants.c
  • player_bits
    extern char* player_bits[]

    Defined in:
  • constants.c
  • preference_bits
    extern char* preference_bits[]

    Defined in:
  • constants.c
  • position_types
    extern char* position_types[]

    Defined in:
  • constants.c
  • connected_types
    extern char* connected_types[]

    Defined in:
  • constants.c
  • attack_hit_text
    extern struct attack_hit_type attack_hit_text[]

    Defined in:
  • fight.c
  • circle_shutdown
    extern int circle_shutdown

    Defined in:
  • comm.c
  • circle_reboot
    extern int circle_reboot

    Defined in:
  • comm.c
  • boot_time
    extern time_t boot_time

    Defined in:
  • db.c
  • class_abbrevs
    extern char* class_abbrevs[]

    Defined in:
  • class.c
  • genders
    extern char* genders[]

    Defined in:
  • constants.c
  • buf_switches
    extern int buf_switches

    Defined in:
  • comm.c
  • buf_largecount
    extern int buf_largecount

    Defined in:
  • comm.c
  • buf_overflows
    extern int buf_overflows

    Defined in:
  • comm.c

  • Local Variables

    logtypes
    static char* logtypes[]
    Used in:
  • do_syslog()

  • Global Function do_advance()

    void do_advance ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • basic_mud_log() : utils.c
  • gain_exp_regardless() : limits.c
  • get_char_vis() : handler.c
  • level_exp() : class.c
  • save_char() : db.c
  • send_to_char() : comm.c
  • two_arguments() : interpreter.c
  • atoi(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • arg, buf, buf

  • Global Function do_at()

    void do_at ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • char_from_room() : handler.c
  • char_to_room() : handler.c
  • command_interpreter() : interpreter.c
  • find_target_room() : act.wizard.c
  • half_chop() : interpreter.c
  • send_to_char() : comm.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • buf

  • Global Function do_date()

    void do_date ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • send_to_char() : comm.c
  • asctime(), localtime(), sprintf(), strlen(), time()
  • Used in:
  • : interpreter.c
  • References Variables:
  • boot_time : db.c
  • buf

  • Global Function do_dc()

    void do_dc ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • basic_mud_log() : utils.c
  • close_socket() : comm.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • atoi(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • descriptor_list : comm.c
  • arg, buf

  • Global Function do_echo()

    void do_echo ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • send_to_char() : comm.c
  • skip_spaces() : interpreter.c
  • sprintf(), strcpy()
  • Called by:
  • shopping_buy() : shop.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • buf

  • Global Function do_force()

    void do_force ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • MAX() : utils.c
  • act() : comm.c
  • command_interpreter() : interpreter.c
  • get_char_vis() : handler.c
  • half_chop() : interpreter.c
  • mudlog() : utils.c
  • send_to_char() : comm.c
  • str_cmp() : utils.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • NOPERSON : config.c
  • OK : config.c
  • descriptor_list : comm.c
  • world : db.c
  • arg, buf, buf

  • Global Function do_gecho()

    void do_gecho ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • delete_doubledollar() : interpreter.c
  • send_to_char() : comm.c
  • skip_spaces() : interpreter.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • descriptor_list : comm.c
  • buf

  • Global Function do_goto()

    void do_goto ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • char_from_room() : handler.c
  • char_to_room() : handler.c
  • find_target_room() : act.wizard.c
  • look_at_room() : act.informative.c
  • sprintf(), strcpy()
  • Used in:
  • : interpreter.c
  • References Variables:
  • buf

  • Global Function do_invis()

    void do_invis ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • one_argument() : interpreter.c
  • perform_immort_invis() : act.wizard.c
  • perform_immort_vis() : act.wizard.c
  • send_to_char() : comm.c
  • atoi()
  • Used in:
  • : interpreter.c
  • References Variables:
  • arg

  • Global Function do_last()

    void do_last ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • load_char() : db.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • ctime(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • class_abbrevs : class.c
  • arg, buf

  • Global Function do_load()

    void do_load ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • char_to_room() : handler.c
  • is_abbrev() : interpreter.c
  • obj_to_room() : handler.c
  • read_mobile() : db.c
  • read_object() : db.c
  • real_mobile() : db.c
  • real_object() : db.c
  • send_to_char() : comm.c
  • two_arguments() : interpreter.c
  • atoi()
  • Used in:
  • : interpreter.c
  • References Variables:
  • buf, buf

  • Global Function do_poofset()

    void do_poofset ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • send_to_char() : comm.c
  • skip_spaces() : interpreter.c
  • str_dup() : utils.c
  • free()
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c

  • Global Function do_purge()

    void do_purge ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • close_socket() : comm.c
  • extract_char() : handler.c
  • extract_obj() : handler.c
  • get_char_room_vis() : handler.c
  • get_obj_in_list_vis() : handler.c
  • mudlog() : utils.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • send_to_room() : comm.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • world : db.c
  • buf

  • Global Function do_restore()

    void do_restore ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • get_char_vis() : handler.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • update_pos() : fight.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • NOPERSON : config.c
  • OK : config.c
  • buf

  • Global Function do_return()

    void do_return ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • close_socket() : comm.c
  • send_to_char() : comm.c
  • Used in:
  • : interpreter.c

  • Global Function do_send()

    void do_send ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • get_char_vis() : handler.c
  • half_chop() : interpreter.c
  • send_to_char() : comm.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • NOPERSON : config.c
  • arg, buf, buf

  • Global Function do_set()

    void do_set ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • char_to_store() : db.c
  • clear_char() : db.c
  • free_char() : db.c
  • get_char_vis() : handler.c
  • get_player_vis() : handler.c
  • half_chop() : interpreter.c
  • load_char() : db.c
  • perform_set() : act.wizard.c
  • save_char() : db.c
  • send_to_char() : comm.c
  • store_to_char() : db.c
  • str_cmp() : utils.c
  • __gnu_calloc(), abort(), free(), fseek(), fwrite(), perror(), strcmp(), strcpy(), strlen(), strncmp()
  • Used in:
  • : interpreter.c
  • References Variables:
  • player_fl : db.c
  • set_fields : act.wizard.c
  • buf

  • Global Function do_show()

    void do_show ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • Crash_listrent() : objsave.c
  • is_number() : interpreter.c
  • load_char() : db.c
  • print_zone_to_buf() : act.wizard.c
  • send_to_char() : comm.c
  • skip_spaces() : interpreter.c
  • two_arguments() : interpreter.c
  • atoi(), ctime(), sprintf(), strcat(), strcmp(), strcpy(), strlen(), strncmp()
  • Used in:
  • : interpreter.c
  • References Variables:
  • character_list : db.c
  • class_abbrevs : class.c
  • genders : constants.c
  • object_list : db.c
  • top_of_mobt : db.c
  • top_of_objt : db.c
  • top_of_p_table : db.c
  • top_of_world : db.c
  • top_of_zone_table : db.c
  • weather_info : db.c
  • world : db.c
  • zone_table : db.c
  • arg, buf, buf, buf, buf

  • Global Function do_shutdown()

    void do_shutdown ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • basic_mud_log() : utils.c
  • one_argument() : interpreter.c
  • send_to_all() : comm.c
  • send_to_char() : comm.c
  • str_cmp() : utils.c
  • touch() : utils.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • circle_reboot : comm.c
  • circle_shutdown : comm.c
  • arg, buf

  • Global Function do_snoop()

    void do_snoop ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • get_char_vis() : handler.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • stop_snooping() : act.wizard.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • arg

  • Global Function do_stat()

    void do_stat ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • clear_char() : db.c
  • do_stat_character() : act.wizard.c
  • do_stat_object() : act.wizard.c
  • do_stat_room() : act.wizard.c
  • free_char() : db.c
  • get_char_room_vis() : handler.c
  • get_char_vis() : handler.c
  • get_obj_in_list_vis() : handler.c
  • get_obj_vis() : handler.c
  • get_object_in_equip_vis() : handler.c
  • get_player_vis() : handler.c
  • half_chop() : interpreter.c
  • is_abbrev() : interpreter.c
  • load_char() : db.c
  • send_to_char() : comm.c
  • store_to_char() : db.c
  • __gnu_calloc(), abort(), free(), perror()
  • Used in:
  • : interpreter.c
  • References Variables:
  • world : db.c
  • buf, buf

  • Global Function do_stat_character()

    void do_stat_character ( struct char_data* ch, struct char_data* k )
    Calls:
  • age() : utils.c
  • hit_gain() : limits.c
  • mana_gain() : limits.c
  • move_gain() : limits.c
  • send_to_char() : comm.c
  • sprintbit() : utils.c
  • sprinttype() : utils.c
  • asctime(), localtime(), sprintf(), strcat(), strcpy(), strlen()
  • Called by:
  • do_stat() : act.wizard.c
  • do_vstat() : act.wizard.c
  • References Variables:
  • action_bits : constants.c
  • affected_bits : constants.c
  • apply_types : constants.c
  • attack_hit_text : fight.c
  • connected_types : constants.c
  • int_app : constants.c
  • mob_index : db.c
  • npc_class_types : constants.c
  • pc_class_types : class.c
  • player_bits : constants.c
  • position_types : constants.c
  • preference_bits : constants.c
  • spells : spell_parser.c
  • weather_info : db.c
  • wis_app : constants.c
  • world : db.c
  • buf, buf, buf

  • Global Function do_stat_object()

    void do_stat_object ( struct char_data* ch, struct obj_data* j )
    Calls:
  • send_to_char() : comm.c
  • skill_name() : spell_parser.c
  • sprintbit() : utils.c
  • sprinttype() : utils.c
  • sprintf(), strcat(), strcpy(), strlen()
  • Called by:
  • do_stat() : act.wizard.c
  • do_vstat() : act.wizard.c
  • References Variables:
  • affected_bits : constants.c
  • apply_types : constants.c
  • container_bits : constants.c
  • drinks : constants.c
  • extra_bits : constants.c
  • item_types : constants.c
  • obj_index : db.c
  • wear_bits : constants.c
  • world : db.c
  • buf, buf, buf

  • Global Function do_stat_room()

    void do_stat_room ( struct char_data* ch )
    Calls:
  • send_to_char() : comm.c
  • sprintbit() : utils.c
  • sprinttype() : utils.c
  • sprintf(), strcat(), strcpy(), strlen()
  • Called by:
  • do_stat() : act.wizard.c
  • References Variables:
  • dirs : constants.c
  • exit_bits : constants.c
  • room_bits : constants.c
  • sector_types : constants.c
  • weather_info : db.c
  • world : db.c
  • buf, buf, buf

  • Global Function do_switch()

    void do_switch ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • get_char_vis() : handler.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • arg

  • Global Function do_syslog()

    void do_syslog ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • one_argument() : interpreter.c
  • search_block() : interpreter.c
  • send_to_char() : comm.c
  • sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • logtypes : act.wizard.c
  • arg, buf

  • Global Function do_teleport()

    void do_teleport ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • char_from_room() : handler.c
  • char_to_room() : handler.c
  • find_target_room() : act.wizard.c
  • get_char_vis() : handler.c
  • look_at_room() : act.informative.c
  • send_to_char() : comm.c
  • two_arguments() : interpreter.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • NOPERSON : config.c
  • OK : config.c
  • buf, buf

  • Global Function do_trans()

    void do_trans ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • act() : comm.c
  • char_from_room() : handler.c
  • char_to_room() : handler.c
  • get_char_vis() : handler.c
  • look_at_room() : act.informative.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • str_cmp() : utils.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • NOPERSON : config.c
  • OK : config.c
  • descriptor_list : comm.c
  • buf

  • Global Function do_vnum()

    void do_vnum ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • is_abbrev() : interpreter.c
  • send_to_char() : comm.c
  • two_arguments() : interpreter.c
  • vnum_mobile() : db.c
  • vnum_object() : db.c
  • Used in:
  • : interpreter.c
  • References Variables:
  • buf, buf

  • Global Function do_vstat()

    void do_vstat ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • char_to_room() : handler.c
  • do_stat_character() : act.wizard.c
  • do_stat_object() : act.wizard.c
  • extract_char() : handler.c
  • extract_obj() : handler.c
  • is_abbrev() : interpreter.c
  • read_mobile() : db.c
  • read_object() : db.c
  • real_mobile() : db.c
  • real_object() : db.c
  • send_to_char() : comm.c
  • two_arguments() : interpreter.c
  • atoi()
  • Used in:
  • : interpreter.c
  • References Variables:
  • buf, buf

  • Global Function do_wizlock()

    void do_wizlock ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • atoi(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • restrict : db.c
  • arg, buf

  • Global Function do_wiznet()

    void do_wiznet ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • MAX() : utils.c
  • delete_doubledollar() : interpreter.c
  • half_chop() : interpreter.c
  • is_number() : interpreter.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • skip_spaces() : interpreter.c
  • atoi(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • OK : config.c
  • descriptor_list : comm.c
  • weather_info : db.c
  • world : db.c
  • buf, buf

  • Global Function do_wizutil()

    void do_wizutil ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • MAX() : utils.c
  • act() : comm.c
  • affect_remove() : handler.c
  • basic_mud_log() : utils.c
  • get_char_vis() : handler.c
  • mudlog() : utils.c
  • one_argument() : interpreter.c
  • save_char() : db.c
  • send_to_char() : comm.c
  • sprintf(), strcat()
  • Used in:
  • : interpreter.c
  • References Variables:
  • arg, buf

  • Global Function do_zreset()

    void do_zreset ( struct char_data* ch, char* argument, int cmd, int subcmd )
    Calls:
  • MAX() : utils.c
  • mudlog() : utils.c
  • one_argument() : interpreter.c
  • send_to_char() : comm.c
  • atoi(), sprintf()
  • Used in:
  • : interpreter.c
  • References Variables:
  • top_of_zone_table : db.c
  • world : db.c
  • zone_table : db.c
  • arg, buf

  • Global Function find_target_room()

    sh_int find_target_room ( struct char_data* ch, char* rawroomstr )
    Calls:
  • House_can_enter() : house.c
  • get_char_vis() : handler.c
  • get_obj_vis() : handler.c
  • one_argument() : interpreter.c
  • real_room() : db.c
  • send_to_char() : comm.c
  • atoi(), strchr()
  • Called by:
  • do_at() : act.wizard.c
  • do_goto() : act.wizard.c
  • do_teleport() : act.wizard.c
  • References Variables:
  • world : db.c

  • Global Function perform_immort_invis()

    void perform_immort_invis ( struct char_data* ch, int level )
    Calls:
  • act() : comm.c
  • send_to_char() : comm.c
  • sprintf()
  • Called by:
  • do_invis() : act.wizard.c
  • References Variables:
  • world : db.c
  • buf

  • Global Function perform_immort_vis()

    void perform_immort_vis ( struct char_data* ch )
    Calls:
  • send_to_char() : comm.c
  • Called by:
  • do_invis() : act.wizard.c

  • Global Function perform_set()

    int perform_set ( struct char_data* ch, struct char_data* vict, int mode, char* val_arg )
    Calls:
  • MAX() : utils.c
  • MIN() : utils.c
  • affect_total() : handler.c
  • char_from_room() : handler.c
  • char_to_room() : handler.c
  • is_number() : interpreter.c
  • real_room() : db.c
  • send_to_char() : comm.c
  • set_title() : limits.c
  • str_cmp() : utils.c
  • atoi(), crypt(), sprintf(), strcat(), strcmp(), strcpy(), strncpy()
  • Called by:
  • do_set() : act.wizard.c
  • References Variables:
  • set_fields : act.wizard.c

  • Global Function print_zone_to_buf()

    void print_zone_to_buf ( char* bufptr, int zone )
    Calls:
  • sprintf()
  • Called by:
  • do_show() : act.wizard.c
  • References Variables:
  • zone_table : db.c

  • Global Function stop_snooping()

    void stop_snooping ( struct char_data* ch )
    Calls:
  • send_to_char() : comm.c
  • Called by:
  • do_snoop() : act.wizard.c