![]() |
Crossfire Server, Trunk
1.75.0
|
Go to the source code of this file.
Functions | |
| int | account_change_password (const char *account_name, const char *current_password, const char *new_password) |
| Change an account password. More... | |
| void | account_char_add (Account_Chars *chars, player *pl) |
| This adds a player to the list of accounts. More... | |
| void | account_char_free (Account_Chars *chars) |
| This frees all data associated with the character information. More... | |
| Account_Chars * | account_char_load (const char *account_name) |
| For a given account name, load the character information and return it. More... | |
| void | account_char_remove (Account_Chars *chars, const char *pl_name) |
| This removes a character on this account. More... | |
| void | account_char_save (Account_Chars *chars) |
| Saves the character information for the given account. More... | |
| int | account_check_string (const char *str) |
| Checks a string to make sure it does not have any invalid characters. More... | |
| const char * | account_exists (const char *account_name) |
| Checks the existing accounts, and see if this account exists. More... | |
| const char * | account_get_account_for_char (const char *charname) |
| This looks at all the accounts and sees if charname is associated with any of them. More... | |
| linked_char * | account_get_additional_chars (const char *account_name, const Account_Chars *chars, int *count) |
| Get a list of character names linked to the specified account which are not listed in chars. More... | |
| char ** | account_get_players_for_account (const char *account_name) |
| Returns an array of strings for the characters on this account - the array is null terminated. More... | |
| int | account_is_logged_in (const char *name) |
| This checkes if an account is logged in. More... | |
| int | account_link (const char *account_name, const char *player_name) |
| Adds a player name to an account. More... | |
| int | account_login (const char *account_name, const char *account_password) |
| Check if the given account exists, and whether the password is correct. More... | |
| void | account_logout (const char *account_name) |
| Remove 'account_name' from the list of logged in accounts. More... | |
| int | account_new (const char *account_name, const char *account_password) |
| Adds an account. More... | |
| int | account_remove_player (const char *account_name, const char *player_name) |
| Removes a player name from an account. More... | |
| void | accounts_clear (void) |
| This is used purely by the test harness - by clearing the accounts, it can then verify that the data is added is loaded back into memory properly. More... | |
| void | accounts_load (void) |
| This loads all the account entries into memory. More... | |
| void | accounts_save (void) |
| Save all the account information. More... | |
| player * | add_player (socket_struct *ns, int flags) |
| Tries to add player on the connection passwd in ns. More... | |
| void | add_server_collect_hooks () |
| int | alchemy (object *op, object *caster, object *spell_ob) |
| Change items to gold nuggets. More... | |
| int | animate_weapon (object *op, object *caster, object *spell, int dir) |
| Generalization of staff_to_snake(). More... | |
| int | apply_auto (object *op) |
| Map was just loaded, handle op's initialization. More... | |
| void | apply_auto_fix (mapstruct *m) |
| Go through the entire map (only the first time when an original map is loaded) and performs special actions for certain objects (most initialization of chests and creation of treasures and stuff). More... | |
| void | apply_builder_remove (object *pl, int dir) |
| Item remover. More... | |
| int | apply_by_living (object *pl, object *op, int aflag, int quiet) |
| Living thing is applying an object. More... | |
| void | apply_by_living_below (object *pl) |
| Attempt to apply the object 'below' the player. More... | |
| int | apply_can_apply_object (const object *who, const object *op) |
| Checks to see if 'who' can apply object 'op'. More... | |
| void | apply_changes_to_player (object *pl, object *change, int limit_stats) |
| Applies (race) changes to a player. More... | |
| int | apply_check_weapon_power (const object *who, int improves) |
| This checks to see of the player (who) is sufficient level to use a weapon with improves improvements (typically last_eat). More... | |
| void | apply_handle_yield (object *tmp) |
| This checks whether the object has a "on_use_yield" field, and if so generated and drops matching item. More... | |
| int | apply_manual (object *op, object *tmp, int aflag) |
| Main apply handler. More... | |
| void | apply_map_builder (object *pl, int dir) |
| Global building function. More... | |
| int | apply_race_and_class (object *op, archetype *race, archetype *opclass, living *stats) |
| This is somewhat like key_change_class() above, except we know the race to change to, but we still basically need to do the same work (apply bonuses, update archetype, etc.) More... | |
| int | apply_special (object *who, object *op, int aflags) |
| Apply an object. More... | |
| int | attack_ob (object *op, object *hitter) |
| Simple wrapper for attack_ob_simple(), will use hitter's values. More... | |
| int | become_follower (object *op, const object *new_god) |
| This function is called whenever a player has switched to a new god. More... | |
| void | blind_living (object *op, object *hitter, int dam) |
| Blind a living thing. More... | |
| int64_t | calc_skill_exp (const object *who, const object *op, const object *skill) |
| Calculates amount of experience can be gained for successful use of a skill. More... | |
| bool | can_follow (object *op, player *other) |
| int | cast_bless (object *op, object *caster, object *spell_ob, int dir) |
| Improve statistics of some living object. More... | |
| int | cast_cause_disease (object *op, object *caster, object *spell, int dir) |
| Let's try to infect something. More... | |
| int | cast_change_ability (object *op, object *caster, object *spell_ob, int dir, int silent) |
| Cast some stat-improving spell. More... | |
| int | cast_change_map_lightlevel (object *op, object *spell) |
| This changes the light level for the entire map. More... | |
| int | cast_cone (object *op, object *caster, int dir, object *spell) |
| Casts a cone spell. More... | |
| int | cast_consecrate (object *op, object *caster, object *spell) |
| A spell to make an altar your god's. More... | |
| int | cast_create_food (object *op, object *caster, object *spell_ob, int dir, const char *stringarg) |
| Create food. More... | |
| int | cast_create_missile (object *op, object *caster, object *spell, int dir, const char *stringarg) |
| Create a missile (nonmagic - magic +4). More... | |
| int | cast_create_obj (object *op, object *new_op, int dir) |
| Creates object new_op in direction dir or if that is blocked, beneath the player (op). More... | |
| int | cast_create_town_portal (object *op, object *caster, object *spell) |
| This function cast the spell of town portal for op. More... | |
| int | cast_curse (object *op, object *caster, object *spell_ob, int dir) |
| Curse an object, reducing its statistics. More... | |
| int | cast_destruction (object *op, object *caster, object *spell_ob) |
| Hit all monsters around the caster. More... | |
| int | cast_detection (object *op, object *caster, object *spell) |
| Detect magic or invisible items. More... | |
| void | cast_dust (object *op, object *throw_ob, int dir) |
| Handles op throwing objects of type 'DUST'. More... | |
| int | cast_earth_to_dust (object *op, object *caster, object *spell_ob) |
| Basically destroys earthwalls in the area. More... | |
| int | cast_heal (object *op, object *caster, object *spell, int dir) |
| Heals something. More... | |
| int | cast_identify (object *op, object *caster, object *spell) |
| Identifies objects in the players inventory/on the ground. More... | |
| int | cast_invisible (object *op, object *caster, object *spell_ob) |
| Makes the player or character invisible. More... | |
| int | cast_item_curse_or_bless (object *op, object *spell_ob) |
| This alters player's marked item's cursed or blessed status, based on the spell_ob's fields. More... | |
| int | cast_light (object *op, object *caster, object *spell, int dir) |
| Illuminates something on a map, or try to blind a living thing. More... | |
| void | cast_magic_storm (object *op, object *tmp, int lvl) |
| This is really used mostly for spell fumbles and the like. More... | |
| int | cast_polymorph (object *op, object *caster, object *spell_ob, int dir) |
| Polymorph spell casting. More... | |
| int | cast_raise_dead_spell (object *op, object *caster, object *spell, int dir, const char *arg) |
| This handles the raise dead / resurrection spells. More... | |
| int | cast_smite_spell (object *op, object *caster, int dir, object *spell) |
| The priest points to a creature and causes a 'godly curse' to descend. More... | |
| int | cast_spell (object *op, object *caster, int dir, object *spell_ob, char *stringarg) |
| Main dispatch when someone casts a spell. More... | |
| int | cast_transfer (object *op, object *caster, object *spell, int dir) |
| This spell transfers sp from the player to another person. More... | |
| int | cast_wonder (object *op, object *caster, int dir, object *spell_ob) |
| wonder is really just a spell that will likely cast another spell. More... | |
| int | cast_word_of_recall (object *op, object *caster, object *spell_ob) |
| Word of recall causes the player to return 'home'. More... | |
| int | caster_level (const object *caster, const object *spell) |
| This function returns the effective level the spell is being cast at. More... | |
| int | cftimer_create (int id, long delay, object *ob, int mode) |
| Creates a new timer. More... | |
| int | cftimer_destroy (int id) |
| Destroys an existing timer. More... | |
| int | cftimer_find_free_id (void) |
| Finds a free ID for a new timer. More... | |
| void | cftimer_init (void) |
| Initialize timers. More... | |
| void | cftimer_process_timers (void) |
| Processes all timers. More... | |
| void | change_object (object *op) |
| Replaces op with its other_arch if it has reached its end of life. More... | |
| int | change_skill (object *who, object *new_skill, int flag) |
| This changes the object's skill to new_skill. More... | |
| void | check_active_maps (void) |
| Finds maps in memory to swap. More... | |
| void | check_bullet (object *op) |
| Checks to see what op should do, given the space it is on (eg, explode, damage player, etc). More... | |
| void | check_login (object *op, const char *password) |
| Actually login a player, load from disk and such. More... | |
| int | check_name (player *me, const char *name) |
| Ensure player's name is valid. More... | |
| bool | check_password (const char *typed, const char *crypted) |
| Hash a password and compare it to the stored version. More... | |
| void | check_physically_infect (object *victim, object *hitter) |
| Possibly infect due to direct physical contact i.e., AT_PHYSICAL. More... | |
| int | check_pick (object *op) |
| Sees if there is stuff to be picked up/picks up stuff, for players only. More... | |
| int | check_race_and_class (living *stats, archetype *race, archetype *opclass) |
| This checks to see if the race and class are legal. More... | |
| void | check_spell_expiry (object *spell) |
| Checks if player should be warned of soon expiring spell. More... | |
| object * | check_spell_known (object *op, const char *name) |
| Checks to see if player knows the spell. More... | |
| int | checkbanned (const char *login, const char *host) |
| Check if a player and/or host is banned. More... | |
| void | clean_tmp_files (void) |
| Save unique maps and clean up temporary map files unless recycling temporary maps. More... | |
| void | cleanup (void) |
| Clean up everything and exit. More... | |
| void | cleanupPlugins (void) |
| Call the crossfire_plugin::closefunc on the various plugins, used at server shutdown. More... | |
| void | clear_skill (object *who) |
| This function just clears the chosen_skill and range_skill values in the player. More... | |
| void | close_modules () |
| Clean up all modules which are not disabled. More... | |
| void | command_abil (object *op, const char *params) |
| Changes an object's statistics. More... | |
| void | command_accountpasswd (object *op, const char *params) |
| void | command_accuse (object *op, const char *params) |
| 'accuse' command. More... | |
| void | command_addexp (object *op, const char *params) |
| This adds exp to a player. More... | |
| void | command_afk (object *op, const char *params) |
| Toggles the afk status of a player. More... | |
| void | command_apply (object *op, const char *params) |
| 'apply' command. More... | |
| void | command_applymode (object *op, const char *params) |
| Players wants to change the apply mode, ie how to handle applying an item when no body slot available. More... | |
| void | command_archs (object *op, const char *params) |
| void | command_arrest (object *op, const char *params) |
| Wizard jails player. More... | |
| void | command_banish (object *op, const char *params) |
| Add player's IP to ban_file and kick them off the server. More... | |
| void | command_beg (object *op, const char *params) |
| 'beg' command. More... | |
| void | command_bleed (object *op, const char *params) |
| 'bleed' command. More... | |
| void | command_blush (object *op, const char *params) |
| 'blush' command. More... | |
| void | command_body (object *op, const char *params) |
| This command dumps the body information for object *op. More... | |
| void | command_bounce (object *op, const char *params) |
| 'bounce' command. More... | |
| void | command_bow (object *op, const char *params) |
| 'bow' command. More... | |
| void | command_bowmode (object *op, const char *params) |
| Player wants to change the bowmode, how arrows are fired. More... | |
| void | command_brace (object *op, const char *params) |
| Player toggles her braced status. More... | |
| void | command_burp (object *op, const char *params) |
| 'burp' command. More... | |
| void | command_cackle (object *op, const char *params) |
| 'cackle' command. More... | |
| void | command_cast (object *op, const char *params) |
| 'cast' command, prepares a spell for laster casting. More... | |
| void | command_cast_spell (object *op, const char *params, int cast_now) |
| Sets up to cast a spell. More... | |
| void | command_chat (object *op, const char *params) |
| 'chat' command. More... | |
| void | command_chuckle (object *op, const char *params) |
| 'chuckle' command. More... | |
| void | command_clap (object *op, const char *params) |
| 'clap' command. More... | |
| void | command_cointoss (object *op, const char *params) |
| 'cointoss' command. More... | |
| void | command_cough (object *op, const char *params) |
| 'cough' command. More... | |
| void | command_create (object *op, const char *params) |
| Wizard wants to create an object. More... | |
| void | command_cringe (object *op, const char *params) |
| 'cringe' command. More... | |
| void | command_cry (object *op, const char *params) |
| 'cry' command. More... | |
| void | command_dance (object *op, const char *params) |
| 'dance' command. More... | |
| void | command_debug (object *op, const char *params) |
| Player wants to see/change the debug level. More... | |
| void | command_delete (object *op, const char *params) |
| Player wants to totally delete her character. More... | |
| void | command_diff (object *op, const char *params) |
| Get a diff of specified items. More... | |
| void | command_disarm (object *op, const char *params) |
| 'disarm' command. More... | |
| void | command_dm (object *op, const char *params) |
| Actual command to perhaps become dm. More... | |
| void | command_dmhide (object *op, const char *params) |
| A players wants to become DM and hide. More... | |
| void | command_dmtell (object *op, const char *params) |
| Private communication, by a DM (can't be ignored by player). More... | |
| void | command_drop (object *op, const char *params) |
| 'drop' command. More... | |
| void | command_dropall (object *op, const char *params) |
| Command to drop all items that have not been locked. More... | |
| void | command_dump (object *op, const char *params) |
| Dumps the difference between an object and its archetype. More... | |
| void | command_dumpabove (object *op, const char *params) |
| Player wants to dump object above her. More... | |
| void | command_dumpallarchetypes (object *op, const char *params) |
| Various archetypes-related statistics. More... | |
| void | command_dumpallmaps (object *op, const char *params) |
| Various map-related statistics. More... | |
| void | command_dumpallobjects (object *op, const char *params) |
| Various object-related statistics. More... | |
| void | command_dumpbelow (object *op, const char *params) |
| Player wants to dump object below her. More... | |
| void | command_dumpfriendlyobjects (object *op, const char *params) |
| Various friendly object-related statistics. More... | |
| void | command_dumpmap (object *op, const char *params) |
| Various map-related statistics. More... | |
| void | command_east (object *op, const char *params) |
| 'east' command. More... | |
| void | command_empty (object *op, const char *params) |
| 'empty' command. More... | |
| void | command_examine (object *op, const char *params) |
| 'examine' command. More... | |
| void | command_execute (object *pl, char *command) |
| Handle a player-issued command. More... | |
| void | command_face (object *op, const char *params) |
| Player wants to face a given direction. More... | |
| void | command_fire (object *op, const char *params) |
| Player wants to start firing. More... | |
| void | command_fire_stop (object *op, const char *params) |
| Player wants to stop firing. More... | |
| void | command_fix_me (object *op, const char *params) |
| Wrapper to fix a player. More... | |
| void | command_flip (object *op, const char *params) |
| 'flip' command. More... | |
| void | command_follow (object *op, const char *params) |
| Follow a player, or stop following a player. More... | |
| void | command_forget_spell (object *op, const char *params) |
| Command for players to forget a spell. More... | |
| void | command_free (object *op, const char *params) |
| Totally free an object. More... | |
| void | command_freeze (object *op, const char *params) |
| Freezes a player for a specified tick count, 100 by default. More... | |
| void | command_frown (object *op, const char *params) |
| 'frown' command. More... | |
| void | command_gasp (object *op, const char *params) |
| 'gasp' command. More... | |
| void | command_giggle (object *op, const char *params) |
| 'giggle' command. More... | |
| void | command_glare (object *op, const char *params) |
| 'glare' command. More... | |
| void | command_goto (object *op, const char *params) |
| Wizard teleports to a map. More... | |
| void | command_grin (object *op, const char *params) |
| 'grin' command. More... | |
| void | command_groan (object *op, const char *params) |
| 'groan' command. More... | |
| void | command_growl (object *op, const char *params) |
| 'growl' command. More... | |
| void | command_gsay (object *op, const char *params) |
| 'gsay' command, talks to party. More... | |
| void | command_help (object *op, const char *params) |
| Player is asking for some help. More... | |
| void | command_hiccup (object *op, const char *params) |
| 'hiccup' command. More... | |
| void | command_hide (object *op, const char *params) |
| Wizard 'hide' command. More... | |
| void | command_hiscore (object *op, const char *params) |
| Player is asking for the hiscore. More... | |
| void | command_hug (object *op, const char *params) |
| 'hug' command. More... | |
| void | command_insert_into (object *op, const char *params) |
| Puts an object into another. More... | |
| void | command_inventory (object *op, const char *params) |
| Shows the inventory or some item. More... | |
| void | command_invisible (object *op, const char *params) |
| Wizard wants to become invisible. More... | |
| void | command_invoke (object *op, const char *params) |
| 'invoke' command, fires a spell immediately. More... | |
| void | command_kick (object *op, const char *params) |
| Kicks a player from the server. More... | |
| void | command_kill_pets (object *op, const char *params) |
| Player wants to get rid of pets. More... | |
| void | command_kiss (object *op, const char *params) |
| 'kiss' command. More... | |
| void | command_knowledge (object *pl, const char *params) |
| Handle the 'knowledge' for a player. More... | |
| void | command_language (object *op, const char *params) |
| This is the 'language' command. More... | |
| void | command_laugh (object *op, const char *params) |
| 'laugh' command. More... | |
| void | command_learn_special_prayer (object *op, const char *params) |
| Wizard wants to learn a god-given spell. More... | |
| void | command_learn_spell (object *op, const char *params) |
| Wizard wants to learn a regular spell. More... | |
| void | command_lick (object *op, const char *params) |
| 'lick' command. More... | |
| void | command_list (object *pl, bool is_dm) |
| Display the list of commands to a player. More... | |
| void | command_listen (object *op, const char *params) |
| Change the player's listen level. More... | |
| void | command_listplugins (object *op, const char *params) |
| Lists all plugins currently loaded with their IDs and full names. More... | |
| void | command_loadplugin (object *op, const char *params) |
| Loads the given plugin. More... | |
| void | command_loadtest (object *op, const char *params) |
| This command will stress server. More... | |
| void | command_lock_item (object *op, const char *params) |
| Alternate way to lock/unlock items (command line). More... | |
| void | command_malloc (object *op, const char *params) |
| Display memory information. More... | |
| void | command_mapinfo (object *op, const char *params) |
| 'mapinfo' command. More... | |
| void | command_maps (object *op, const char *params) |
| 'maps' command. More... | |
| void | command_mark (object *op, const char *params) |
| 'mark' command, to mark an item for some effects (enchant armor, ...). More... | |
| void | command_me (object *op, const char *params) |
| 'me' command. More... | |
| void | command_mon_aggr (object *op, const char *params) |
| When DM is possessing a monster, flip aggression on and off, to allow better motion. More... | |
| void | command_motd (object *op, const char *params) |
| Display the message of the day. More... | |
| void | command_news (object *op, const char *params) |
| Display the server news. More... | |
| void | command_nod (object *op, const char *params) |
| 'nod' command. More... | |
| void | command_north (object *op, const char *params) |
| 'north' command. More... | |
| void | command_northeast (object *op, const char *params) |
| 'northeast' command. More... | |
| void | command_northwest (object *op, const char *params) |
| 'northwest' command. More... | |
| void | command_nowiz (object *op, const char *params) |
| Steps down from wizard mode. More... | |
| void | command_orcknuckle (object *op, const char *params) |
| Plays the "orcknucke" game. More... | |
| void | command_overlay_reset (object *op, const char *params) |
| Removes the overlay for op's current map. More... | |
| void | command_overlay_save (object *op, const char *params) |
| Saves the op's map as an overlay - objects are persisted. More... | |
| void | command_party (object *op, const char *params) |
| 'party' command, subdivided in different sub commands. More... | |
| void | command_party_rejoin (object *op, const char *params) |
| Handles the 'party_rejoin' command. More... | |
| void | command_passwd (object *pl, const char *params) |
| Player is asking to change password. More... | |
| void | command_patch (object *op, const char *params) |
| Wizard wants to altar an object. More... | |
| void | command_peaceful (object *op, const char *params) |
| Player toggles her peaceful status. More... | |
| void | command_petmode (object *op, const char *params) |
| Player wants to change how her pets behave. More... | |
| void | command_pickup (object *op, const char *params) |
| 'pickup' command. More... | |
| void | command_players (object *op, const char *params) |
| Display all known players. More... | |
| void | command_poke (object *op, const char *params) |
| 'poke' command. More... | |
| void | command_possess (object *op, const char *params) |
| DM can possess a monster. More... | |
| void | command_pout (object *op, const char *params) |
| 'pout' command. More... | |
| void | command_printlos (object *op, const char *params) |
| Various LOS-related statistics. More... | |
| void | command_puke (object *op, const char *params) |
| 'puke' command. More... | |
| void | command_purge_quest (object *op, const char *param) |
| void | command_purge_quest_definitions (object *op, const char *param) |
| void | command_quest (object *op, const char *params) |
| Command handler for 'quest'. More... | |
| void | command_quit (object *op, const char *params) |
| Tell players to use the 'delete' command. More... | |
| void | command_recollect (object *op, const char *params) |
| command_registration | command_register (const char *name, uint8_t type, command_function func, float time) |
| Register a player-issued command. More... | |
| command_registration | command_register_extra (const char *name, const char *extra, uint8_t type, command_function_extra func, float time) |
| Register a player-issued command with an extra parameter. More... | |
| void | command_remove (object *op, const char *params) |
| Remove an object from its position. More... | |
| void | command_rename_item (object *op, const char *params) |
| Changing the custom name of an item. More... | |
| void | command_reply (object *op, const char *params) |
| Reply to last person who told you something [mids 01/14/2002]. More... | |
| void | command_reset (object *op, const char *params) |
| Resets a map. More... | |
| void | command_resistances (object *op, const char *params) |
| Players wants to know her resistances. More... | |
| void | command_rotateshoottype (object *op, const char *params) |
| 'rotateshoottype' command, switch range attack. More... | |
| void | command_rskill (object *pl, const char *params) |
| 'ready_skill' command. More... | |
| void | command_rules (object *op, const char *params) |
| Display the server rules. More... | |
| void | command_run (object *op, const char *params) |
| Player wants to start running. More... | |
| void | command_run_stop (object *op, const char *params) |
| Player wants to stop running. More... | |
| void | command_save (object *op, const char *params) |
| Player wants to get saved. More... | |
| void | command_say (object *op, const char *params) |
| 'say' command. More... | |
| void | command_scream (object *op, const char *params) |
| 'scream' command. More... | |
| void | command_search (object *op, const char *params) |
| 'search' command. More... | |
| void | command_search_items (object *op, const char *params) |
| 'search-items' command. More... | |
| void | command_setgod (object *op, const char *params) |
| Sets the god for some objects. More... | |
| void | command_settings (object *op, const char *ignored) |
| Wizard wants to know some server settings, so display. More... | |
| void | command_shake (object *op, const char *params) |
| 'shake' command. More... | |
| void | command_shiver (object *op, const char *params) |
| 'shiver' command. More... | |
| void | command_shoottype (object *op, const char *params) |
| 'shoottype' command, set range attack. More... | |
| void | command_shout (object *op, const char *params) |
| 'shout' command. More... | |
| void | command_showpets (object *op, const char *params) |
| Players wants to know her pets. More... | |
| void | command_shrug (object *op, const char *params) |
| 'shrug' command. More... | |
| void | command_shutdown (object *op, const char *params) |
| Totally shutdowns the server. More... | |
| void | command_sigh (object *op, const char *params) |
| 'sigh' command. More... | |
| void | command_skills (object *op, const char *params) |
| Player is asking for her skills. More... | |
| void | command_slap (object *op, const char *params) |
| 'slap' command. More... | |
| void | command_smile (object *op, const char *params) |
| 'smile' command. More... | |
| void | command_smirk (object *op, const char *params) |
| 'smirk' command. More... | |
| void | command_snap (object *op, const char *params) |
| 'snap' command. More... | |
| void | command_sneeze (object *op, const char *params) |
| 'sneeze' command. More... | |
| void | command_snicker (object *op, const char *params) |
| 'snicker' command. More... | |
| void | command_sniff (object *op, const char *params) |
| 'sniff' command. More... | |
| void | command_snore (object *op, const char *params) |
| 'snore' command. More... | |
| void | command_sound (object *op, const char *params) |
| Player wants to change sound status. More... | |
| void | command_south (object *op, const char *params) |
| 'south' command. More... | |
| void | command_southeast (object *op, const char *params) |
| 'southeast' command. More... | |
| void | command_southwest (object *op, const char *params) |
| 'southwest' command. More... | |
| void | command_speed (object *op, const char *params) |
| Changes the server speed. More... | |
| void | command_spit (object *op, const char *params) |
| 'spit' command. More... | |
| void | command_ssdumptable (object *op, const char *params) |
| Various string-related statistics. More... | |
| void | command_stack_clear (object *op, const char *params) |
| Empty DM item stack. More... | |
| void | command_stack_list (object *op, const char *params) |
| Displays stack contents. More... | |
| void | command_stack_pop (object *op, const char *params) |
| Pop the stack top. More... | |
| void | command_stack_push (object *op, const char *params) |
| Push specified item on stack. More... | |
| void | command_statistics (object *pl, const char *params) |
| Prints out some useful information for the character. More... | |
| void | command_stats (object *op, const char *params) |
| Displays the statistics of a player. More... | |
| void | command_stay (object *op, const char *params) |
| 'stay' command. More... | |
| void | command_strings (object *op, const char *params) |
| Various string-related statistics. More... | |
| void | command_strut (object *op, const char *params) |
| 'strut' command. More... | |
| void | command_style_map_info (object *op, const char *params) |
| Displays information about styles loaded for random maps. More... | |
| void | command_sulk (object *op, const char *params) |
| 'sulk' command. More... | |
| void | command_summon (object *op, const char *params) |
| Summons player near DM. More... | |
| void | command_swap (object *op, const char *params) |
| Mark a map as ready for swapping. More... | |
| void | command_take (object *op, const char *params) |
| This takes (picks up) an item. More... | |
| void | command_teleport (object *op, const char *params) |
| Teleport next to target player. More... | |
| void | command_tell (object *op, const char *params) |
| Private communication. More... | |
| void | command_thank (object *op, const char *params) |
| 'thank' command. More... | |
| void | command_think (object *op, const char *params) |
| 'think' command. More... | |
| void | command_throw (object *op, const char *params) |
| 'throw' command. More... | |
| void | command_time (object *op, const char *params) |
| Players asks for the time. More... | |
| void | command_title (object *op, const char *params) |
| Player wishes to change her title. More... | |
| void | command_toggle_shout (object *op, const char *params) |
| A simple toggle for the no_shout field. More... | |
| void | command_twiddle (object *op, const char *params) |
| 'twiddle' command. More... | |
| void | command_unarmed_skill (object *op, const char *params) |
| Player wants to change prefered unarmed skill. More... | |
| void | command_unloadplugin (object *op, const char *params) |
| Unloads the given plugin. More... | |
| void | command_unregister (command_registration command) |
| Unregister a previously registered command. More... | |
| void | command_use (object *op, const char *params) |
| Try to use an item on another. More... | |
| void | command_usekeys (object *op, const char *params) |
| Player wants to change how keys are used. More... | |
| void | command_uskill (object *pl, const char *params) |
| 'use_skill' command. More... | |
| void | command_version (object *op, const char *params) |
| Server version. More... | |
| void | command_wave (object *op, const char *params) |
| 'wave' command. More... | |
| void | command_west (object *op, const char *params) |
| 'west' command. More... | |
| void | command_whereabouts (object *op, const char *params) |
| 'whereabouts' command. More... | |
| void | command_whereami (object *op, const char *params) |
| 'whereami' command. More... | |
| void | command_whistle (object *op, const char *params) |
| 'whistle' command. More... | |
| void | command_who (object *op, const char *params) |
| 'who' command. More... | |
| void | command_wimpy (object *op, const char *params) |
| Player wants to change how soon she'll flee. More... | |
| void | command_wink (object *op, const char *params) |
| 'wink' command. More... | |
| void | command_wizcast (object *op, const char *params) |
| Wizard toggling "cast everywhere" ability. More... | |
| void | command_wizpass (object *op, const char *params) |
| Wizard toggling wall-crossing. More... | |
| void | command_yawn (object *op, const char *params) |
| 'yawn' command. More... | |
| void | commands_clear () |
| Clear all registered commands. More... | |
| void | commands_init (void) |
| Init standard commands. More... | |
| void | compute_sky (void) |
| Let the madness, begin. More... | |
| void | cone_drop (object *op) |
| Drops an object based on what is in the cone's "other_arch". More... | |
| void | confirm_password (object *op) |
| Ask the player to confirm her password during creation. More... | |
| void | confuse_living (object *op, object *hitter, int dam) |
| Confuse a living thing. More... | |
| void | counterspell (object *op, int dir) |
| Nullifies spell effects. More... | |
| int | create_aura (object *op, object *caster, object *spell) |
| Create an aura spell object and put it in the player's inventory. More... | |
| int | create_bomb (object *op, object *caster, int dir, object *spell) |
| Create a bomb. More... | |
| bool | csv_contains (std::string list, std::string item, std::string delim=",") |
| Split list by comma, then see if item matches anything in the list. More... | |
| int | cure_disease (object *sufferer, object *caster, sstring skill) |
| Do the cure disease stuff, from the spell "cure disease". More... | |
| void | dead_player (object *op) |
| Kill a player on a permanent death server with resurrection. More... | |
| void | delete_character (const char *name) |
| Totally deletes a character. More... | |
| void | destroy_object (object *op) |
| Recursively object_free_drop_inventory() op and its inventory. More... | |
| int | detect_curse_on_item (object *pl, object *tmp, object *skill) |
| Runs a 'detect curse' check on a given item. More... | |
| int | detect_magic_on_item (object *pl, object *tmp, object *skill) |
| Runs a 'detect magic' check on a given item. More... | |
| const char * | determine_god (object *op) |
| Determines if op worships a god. More... | |
| archetype * | determine_holy_arch (const object *god, const char *type) |
| Determines the archetype for holy servant and god avatar. More... | |
| int | dimension_door (object *op, object *caster, object *spob, int dir) |
| Teleport through some doors and space. More... | |
| int | dispel_rune (object *op, object *skill, int dir) |
| Someone is trying to disarm a rune. More... | |
| void | display_motd (const object *op) |
| Sends the message of the day to the player. More... | |
| void | do_dump (object *who, object *what) |
| void | do_forget_spell (object *op, const char *spell) |
| Erases spell from player's inventory. More... | |
| void | do_goto (object *op, const char *name, int x, int y) |
| void | do_harvest (object *pl, int dir, object *skill) |
| Player is trying to harvest something. More... | |
| void | do_hidden_move (object *op) |
| For hidden creatures - a chance of becoming 'unhidden' every time they move - as we subtract off 'invisibility' AND, for players, if they move into a ridiculously unhideable spot (surrounded by clear terrain in broad daylight). More... | |
| void | do_learn_spell (object *op, object *spell, int special_prayer) |
| Actually makes op learn spell. More... | |
| int | do_skill (object *op, object *part, object *skill, int dir, const char *string) |
| Main skills use function-similar in scope to cast_spell(). More... | |
| void | do_some_living (object *op) |
| Regenerate hp/sp/gr, decreases food. More... | |
| void | dragon_ability_gain (object *who, int atnr, int level) |
| When a dragon-player gains a new stage of evolution, he gets some treasure. More... | |
| void | drain_rod_charge (object *rod) |
| Drain charges from a rod. More... | |
| void | drain_wand_charge (object *wand) |
| Drains a charge from a wand. More... | |
| void | drop (object *op, object *tmp) |
| Drop an item, either on the floor or in a container. More... | |
| object * | drop_object (object *op, object *tmp, uint32_t nrof) |
| Try to drop an object on the floor. More... | |
| void | dump_quests (void) |
| Dump all of the quests, then calls exit() - useful in terms of debugging to make sure that quests are set up and recognised correctly. More... | |
| void | dump_races (void) |
| Dumps all race information to stderr. More... | |
| void | dump_spells (void) |
| Dumps all the spells - now also dumps skill associated with the spell. More... | |
| void | emergency_save (int flag) |
| Save all players. More... | |
| void | enter_exit (object *op, object *exit_ob) |
| Tries to move 'op' to exit_ob. More... | |
| void | enter_player_maplevel (object *op) |
| Move a player to its stored map level. More... | |
| void | enter_player_savebed (object *op) |
| This is a basic little function to put the player back to his savebed. More... | |
| void | examine (object *op, object *tmp) |
| Player examines some object. More... | |
| void | examine_monster (object *op, object *tmp, int level) |
| Player examine a monster. More... | |
| void | explode_bullet (object *op) |
| Causes an object to explode, eg, a firebullet, poison cloud ball, etc. More... | |
| int | face_player (object *op, int dir) |
| Face player in the given direction. More... | |
| object * | find_applied_skill_by_name (const object *op, const char *name) |
| Find a skill by name using the last_skill_ob list. More... | |
| object * | find_key (object *pl, object *container, object *door) |
| We try to find a key for the door as passed. More... | |
| object * | find_marked_object (object *op) |
| Return the object the player has marked with the 'mark' command below. More... | |
| player * | find_player (const char *plname) |
| Find a player by her full name. More... | |
| player * | find_player_options (const char *plname, int options, const mapstruct *map) |
| Find a player. More... | |
| player * | find_player_partial_name (const char *plname) |
| Find a player by a partial name. More... | |
| player * | find_player_socket (const socket_struct *ns) |
| Return a player for a socket structure. More... | |
| object * | find_random_spell_in_ob (object *ob, const char *skill) |
| This returns a random spell from 'ob'. More... | |
| object * | find_skill_by_name (object *who, const char *name) |
| This returns the skill pointer of the given name (the one that accumulates exp, has the level, etc). More... | |
| object * | find_skill_by_number (object *who, int skillno) |
| This returns the first skill pointer of the given subtype (the one that accumulates exp, has the level, etc). More... | |
| object * | find_target_for_friendly_spell (object *op, int dir) |
| This function is commonly used to find a friendly target for spells such as heal or protection or armour. More... | |
| int | find_traps (object *pl, object *skill) |
| Checks for traps on the spaces around the player or in certain objects. More... | |
| void | finish_races () |
| void | fire (object *op, int dir) |
| Received a fire command for the player - go and do it. More... | |
| int | fire_arch_from_position (object *op, object *caster, int16_t x, int16_t y, int dir, object *spell) |
| Fires an archetype. More... | |
| int | fire_bolt (object *op, object *caster, int dir, object *spob) |
| Cast a bolt-like spell. More... | |
| int | fire_bow (object *op, object *arrow, int dir, int wc_mod, int16_t sx, int16_t sy) |
| Creature (monster or player) fires a bow. More... | |
| int | fire_swarm (object *op, object *caster, object *spell, int dir) |
| The following routine creates a swarm of objects. More... | |
| void | fix_luck (void) |
| Fixes luck of players, slowly move it towards 0. More... | |
| object * | fix_stopped_arrow (object *op) |
| An ARROW stops moving. More... | |
| void | fix_stopped_item (object *op, mapstruct *map, object *originator) |
| Put stopped item where stop_item() had found it. More... | |
| void | fix_weight (void) |
| Check recursively the weight of all players, and fix what needs to be fixed. More... | |
| void | flush_old_maps (void) |
| Reset maps that need to, remove their swap file. More... | |
| int | forbid_play (void) |
| Checks if server should be started. More... | |
| void | free_knowledge (void) |
| Free all knowledge data. More... | |
| int | free_no_drop (object *op) |
| Check whether the given object is FLAG_NO_DROP. More... | |
| void | free_quest (void) |
| Free all quest status structures. More... | |
| void | free_quest_definitions (void) |
| void | free_races (void) |
| Frees all race-related information. More... | |
| void | free_server (void) |
| Frees all memory allocated around here: More... | |
| int | friendly_fire (object *op, object *hitter) |
| Find out if this is friendly fire (PVP and attacker is peaceful) or not. More... | |
| void | get_attack_message_for_attack_type (int dam, uint8_t atm_type, const char *victim_name, char *buf1, char *buf2) |
| Get the attack message for a damage and a type. More... | |
| void | get_name (object *op) |
| Waiting for the player's name. More... | |
| object * | get_nearest_criminal (object *mon) |
| object * | get_nearest_player (object *mon) |
| Finds the nearest visible player or player-friendly for some object. More... | |
| int | get_party_password (object *op, partylist *party) |
| Ask the player for the password of the party she wants to join. More... | |
| void | get_password (object *op) |
| Waiting for the player's password. More... | |
| player * | get_player (player *p) |
| Create a player's object, initialize a player's structure. More... | |
| const char * | get_reply_text_own (reply_type rt) |
| Return the verb for the player's dialog type. More... | |
| int | get_world_darkness (void) |
| Get the darkness of the world map at this point. More... | |
| void | give_initial_items (object *pl, treasurelist *items) |
| Gives a new player her initial items. More... | |
| int | handle_newcs_player (object *op) |
| Handles commands the player can send us, and various checks on invisibility, golem and such. More... | |
| int | hide (object *op, object *skill) |
| Main hide handling. More... | |
| int | hideability (object *ob) |
| Look at the surrounding terrain to determine the hideability of this object. More... | |
| void | hiscore_check (object *op, int quiet) |
| Checks if player should enter the hiscore, and if so writes her into the list. More... | |
| void | hiscore_display (object *op, int max, const char *match) |
| Displays the high score file. More... | |
| void | hiscore_init (void) |
| Initializes the module. More... | |
| int | hit_map (object *op, int dir, uint32_t type, int full_hit) |
| Attack a spot on the map. More... | |
| int | hit_player (object *op, int dam, object *hitter, uint32_t type, int full_hit) |
| Object is attacked by something. More... | |
| object * | hit_with_arrow (object *op, object *victim) |
| hit_with_arrow() disassembles the missile, attacks the victim and reassembles the missile. More... | |
| int | identify_object_with_skill (object *tmp, object *pl, object *skill, int print_on_success) |
| Helper function for do_skill_ident, so that we can loop over inventory AND objects on the ground conveniently. More... | |
| int | infect_object (object *victim, object *disease, int force) |
| Try to infect something with a disease. More... | |
| void | init (int argc, char **argv) |
| This is the main server initialization function. More... | |
| void | init_ob_methods (void) |
| Initializes the ob_method system. More... | |
| void | init_signals () |
| Setup our signal handlers. More... | |
| void | init_skills (void) |
| This just sets up the skill_names table above. More... | |
| void | initPlugins (void) |
| Plugins initialization. More... | |
| void | inventory (object *op, object *inv) |
| Prints object's inventory. More... | |
| int | is_true_undead (object *op) |
| Is the object a true undead? More... | |
| int | jump (object *pl, int dir, object *skill) |
| Jump skill handling. More... | |
| void | key_change_class (object *op, char key) |
| This function takes the key that is passed, and does the appropriate action with it (change race, or other things). More... | |
| void | key_confirm_quit (object *op, char key) |
| We receive the reply to the 'quit confirmation' message. More... | |
| void | key_roll_stat (object *op, char key) |
| Player is currently swapping stats. More... | |
| void | kill_player (object *op, const object *killer) |
| Handle a player's death. More... | |
| void | knowledge_add_probe_monster (object *op, object *mon) |
| Display monster details, then add to a player's knowledge if not already. More... | |
| void | knowledge_first_player_save (player *pl) |
| Ensure the knowledge state is correctly saved for the player. More... | |
| void | knowledge_give (player *pl, const char *marker, const object *book) |
| Give a knowledge item from its code. More... | |
| void | knowledge_item_can_be_used_alchemy (object *op, const object *item) |
| Displays known alchemy recipes an item can be used in. More... | |
| int | knowledge_player_knows (const player *pl, const char *knowledge) |
| Determines whether a player knows a specific knowledge or not. More... | |
| void | knowledge_process_incremental (void) |
| Incrementally send knowledge information to players, and remove information for players who left. More... | |
| void | knowledge_read (player *pl, object *book) |
| Player is reading a book, give knowledge if needed, warn player, and such. More... | |
| void | knowledge_send_info (socket_struct *ns) |
| Send the reply_info for 'knowledge_info'. More... | |
| void | knowledge_send_known (player *pl) |
| Send initial known knowledge to player, if requested. More... | |
| int | learn_skill (object *pl, object *scroll) |
| Player is trying to learn a skill. More... | |
| void | leave (player *pl, int draw_exit) |
| Player logs out, or was disconnected. More... | |
| void | legacy_animate_trigger (object *op) |
| void | legacy_move_hole (object *op) |
| void | legacy_remove_force (object *op) |
| int | legal_range (object *op, int r) |
| Check for the validity of a player range. More... | |
| void | list_players (object *op, region *reg, partylist *party) |
| Displays the players in a region or party. More... | |
| void | load_races (BufferReader *reader, const char *filename) |
| Reads the races file in the lib/ directory, then overwrites old 'race' entries. More... | |
| object * | lookup_spell_by_name (object *op, const char *spname) |
| Look at object 'op' and see if they know the spell spname. More... | |
| int | magic_wall (object *op, object *caster, int dir, object *spell_ob) |
| This creates magic walls. More... | |
| void | make_visible (object *op) |
| Makes an object visible again. More... | |
| int | makes_invisible_to (object *pl, object *mon) |
| This checks to see if 'pl' is invisible to 'mon'. More... | |
| bool | map_can_reset (const mapstruct *map, long current_time) |
| Returns whether a map can be reset, including all other maps in the same reset group. More... | |
| void | meditate (object *pl, object *skill) |
| Meditation skill handling. More... | |
| int | min_casting_level (const object *caster, const object *spell) |
| This function takes a caster and spell and presents the effective level the caster needs to be to cast the spell. More... | |
| int | monster_can_detect_enemy (object *op, object *enemy, rv_vector *rv) |
| Determine if we can 'detect' the enemy. More... | |
| int | monster_can_see_enemy (object *op, object *enemy) |
| Assuming no walls/barriers, lets check to see if its possible to see an enemy. More... | |
| void | monster_check_apply_all (object *monster) |
| Calls monster_check_apply() for all inventory objects. More... | |
| void | monster_check_doors (object *op, mapstruct *m, int x, int y) |
| Living creature attempts to open a door. More... | |
| void | monster_check_earthwalls (object *op, mapstruct *m, int x, int y) |
| Living creature attempts to hit an earthwall. More... | |
| object * | monster_check_enemy (object *npc, rv_vector *rv) |
| Checks npc->enemy and returns that enemy if still valid, NULL otherwise. More... | |
| void | monster_communicate (object *op, const char *txt) |
| This function looks for an object or creature that is listening to said text. More... | |
| int | monster_compute_path (object *source, object *target, int default_dir) |
| Computes a path from source to target. More... | |
| void | monster_do_living (object *op) |
| For a monster, regenerate hp and sp, potentially clear scared status. More... | |
| void | monster_do_say (const mapstruct *map, const char *message) |
| Output a NPC message on a map. More... | |
| object * | monster_find_nearest_enemy (object *npc, object *owner) |
| Returns the nearest enemy (monster or generator) which is visible to npc. More... | |
| object * | monster_find_throw_ob (object *op) |
| Find an item for the monster to throw. More... | |
| int | monster_move (object *op) |
| Main monster processing routine. More... | |
| void | monster_npc_call_help (object *op) |
| A monster calls for help against its enemy. More... | |
| void | monster_npc_say (object *npc, const char *cp) |
| Simple function to have some NPC say something. More... | |
| int | monster_stand_in_light (object *op) |
| Cache monster_stand_in_light_internal(). More... | |
| int | mood_change (object *op, object *caster, object *spell) |
| This covers the various spells that change the moods of monsters - makes them angry, peaceful, friendly, etc. More... | |
| int | move_disease (object *disease) |
| Ticks the clock for disease: infect, aggravate symptoms, ... More... | |
| void | move_firewall (object *op) |
| Move for FIREWALL. More... | |
| int | move_ob (object *op, int dir, object *originator) |
| Op is trying to move in direction dir. More... | |
| int | move_object (object *op, int dir) |
| Try to move op in the direction "dir". More... | |
| int | move_player (object *op, int dir) |
| Move player in the given direction. More... | |
| void | move_player_attack (object *op, int dir) |
| The player is also actually going to try and move (not fire weapons). More... | |
| void | move_player_mover (object *op) |
| This function takes a PLAYERMOVER as an argument, and performs the function of a player mover, which is: More... | |
| void | move_symptom (object *symptom) |
| Make the symptom do the nasty things it does. More... | |
| int | move_to (object *op, int x, int y) |
| Move an object one square toward a specified destination on the same map. More... | |
| char const * | newhash (char const *password) |
| int | object_teleport (object *op, mapstruct *map, int x, int y) |
| Move the specified object in a free spot around the map's x & y. More... | |
| int | ok_to_put_more (mapstruct *m, int16_t x, int16_t y, object *op, uint32_t immune_stop) |
| Returns true if it is ok to put spell op on the space/may provided. More... | |
| int | op_on_battleground (object *op, int *x, int *y, archetype **trophy) |
| Check if the given object (usually a player) is standing on a battleground tile. More... | |
| void | paralyze_living (object *op, int dam) |
| Paralyze a living thing. More... | |
| int | party_confirm_password (const partylist *party, const char *password) |
| Checks whether a given password matches the party's password. More... | |
| partylist * | party_find (const char *partyname) |
| Find a party by name. More... | |
| partylist * | party_form (object *op, const char *partyname) |
| Forms the party struct for a party called 'partyname'. More... | |
| partylist * | party_get_first (void) |
| Returns the first party from the list of all parties. More... | |
| const char * | party_get_leader (const partylist *party) |
| Returns the name of the party's leader. More... | |
| partylist * | party_get_next (const partylist *party) |
| Returns the next party from the list of all parties. More... | |
| const char * | party_get_password (const partylist *party) |
| Returns the party's password. More... | |
| void | party_join (object *op, partylist *party) |
| Makes a player join a party. More... | |
| void | party_leave (object *op) |
| Makes a player leave his party. More... | |
| void | party_obsolete_parties (void) |
| Remove unused parties (no players). More... | |
| void | party_remove (partylist *party) |
| Removes and frees a party. More... | |
| void | party_send_message (object *op, const char *message) |
| Send a message to all party members except the speaker. More... | |
| void | party_set_password (partylist *party, const char *password) |
| Sets a party's password. More... | |
| int | path_to_player (object *mon, object *pl, unsigned mindiff) |
| Returns the direction to the player, if valid. More... | |
| int | perceive_self (object *op) |
| Living thing wants to know information. More... | |
| void | perform_weather (void) |
| This routine slowly loads the world, patches it up due to the weather, and saves it back to disk. More... | |
| void | pets_attempt_follow (object *for_owner, int force) |
| Check pets so they try to follow their master around the world. More... | |
| void | pets_control_golem (object *op, int dir) |
| Makes the golem go in specified direction. More... | |
| void | pets_follow_owner (object *ob, object *owner) |
| A pet is trying to follow its owner. More... | |
| object * | pets_get_enemy (object *pet, rv_vector *rv) |
| Given that 'pet' is a friendly object, this function returns a monster the pet should attack, NULL if nothing appropriate is found. More... | |
| void | pets_move (object *ob) |
| Handles a pet's movement. More... | |
| void | pets_move_golem (object *op) |
| Handles a golem's movement. More... | |
| int | pets_should_arena_attack (object *pet, object *owner, object *target) |
| Determines if checks so pets don't attack players or other pets should be overruled by the arena petmode. More... | |
| int | pets_summon_golem (object *op, object *caster, int dir, object *spob) |
| Summons a monster. More... | |
| int | pets_summon_object (object *op, object *caster, object *spell_ob, int dir, const char *stringarg) |
| General purpose summoning function. More... | |
| void | pets_terminate (object *pet) |
| Removes a pet, taking care of clearning the owner's fields if needed. More... | |
| void | pets_terminate_all (object *owner) |
| Removes all pets someone owns. More... | |
| int | pick_lock (object *pl, int dir, object *skill) |
| Lock pick handling. More... | |
| bool | pick_up (object *op, object *alt) |
| Try to pick up an item. More... | |
| void | play_again (object *op) |
| Ask the player whether to play again or disconnect. More... | |
| int | player_arrest (object *who) |
| Put a player into jail, taking into account cursed exits and player's region. More... | |
| bool | player_can_find (object *op, object *ob) |
| Return true if player 'op' can see object 'op' for purpose of locating items for partial item matching or searching by tag. More... | |
| int | player_can_view (object *pl, object *op) |
| Check the player los field for viewability of the object op. More... | |
| SockList * | player_get_delayed_buffer (player *pl) |
| Get a delayed socket buffer, that will be sent after the player's tick is complete. More... | |
| void | player_set_state (player *pl, uint8_t state) |
| Set the player's state to the specified one. More... | |
| void | player_unready_range_ob (player *pl, object *ob) |
| Unready an object for a player. More... | |
| int | playername_ok (const char *cp) |
| Is the player name valid. More... | |
| int | players_on_map (mapstruct *m, int show_all) |
| Returns the count of players on a map, calculated from player list. More... | |
| void | plugins_display_list (object *op) |
| Displays a list of loaded plugins (keystrings and description) in the game log window. More... | |
| int | plugins_init_plugin (const char *libfile) |
| Try to load the specified plugin. More... | |
| int | plugins_remove_plugin (const char *id) |
| Unload the specified plugin. More... | |
| void | polymorph (object *op, object *who, int level) |
| Handles polymorphing an object, living or not. More... | |
| int | pray (object *pl, object *skill) |
| Praying skill handling. More... | |
| void | pray_at_altar (object *pl, object *altar, object *skill) |
| Player prays at altar. More... | |
| int | probe (object *op, object *caster, object *spell_ob, int dir, int level) |
| Try to get information about a living thing. More... | |
| void | process_events (void) |
| Process all active objects. More... | |
| void | process_object (object *op) |
| Main object move function. More... | |
| void | process_rain (void) |
| Keep track of how much rain has fallen in a given weathermap square. More... | |
| int | push_ob (object *who, int dir, object *pusher) |
| Something is pushing some other object. More... | |
| void | put_object_in_sack (object *op, object *sack, object *tmp, uint32_t nrof) |
| Something tries to put an object into another. More... | |
| void | quest_first_player_save (player *pl) |
| Ensure the quest state is correctly saved for a player. More... | |
| int | quest_get_player_state (player *pl, sstring quest_code) |
| Get the quest state for a player. More... | |
| void | quest_load_definitions (void) |
| void | quest_send_initial_states (player *pl) |
| Send the current quest states for the specified player, if the client supports those notifications. More... | |
| void | quest_set_player_state (player *pl, sstring quest_code, int state) |
| Set the state of a quest for a player. More... | |
| void | quest_start (player *pl, sstring quest_code, int state) |
| Start a quest for a player. More... | |
| int | quest_was_completed (player *pl, sstring quest_code) |
| Check if a quest was completed once for a player, without taking account the current state. More... | |
| object * | races_get_random_monster (const char *race, int level) |
| Get a random monster of specified race and level at most the specified one. More... | |
| void | read_map_log (void) |
| Reads temporary maps information from disk. More... | |
| int | real_world_temperature (int x, int y, mapstruct *m) |
| Compute the temperature for a specific square. More... | |
| void | receive_party_password (object *op, const char *password) |
| Player entered a party password. More... | |
| void | receive_play_again (object *op, char key) |
| Player replied to play again / disconnect. More... | |
| void | receive_player_name (object *op, const char *name) |
| A player just entered her name. More... | |
| void | receive_player_password (object *op, const char *password) |
| A player just entered her password, including for changing it. More... | |
| int | recharge (object *op, object *caster, object *spell_ob) |
| Recharge wands. More... | |
| void | recursive_roll (object *op, int dir, object *pusher) |
| An object is pushed by another which is trying to take its place. More... | |
| int | reflwall (mapstruct *m, int x, int y, object *sp_op) |
| Decides weither the (spell-)object sp_op will be reflected from the given mapsquare. More... | |
| void | regenerate_rod (object *rod) |
| Regenerates a rod's charges. More... | |
| void | register_all_ob_types (void) |
| Calls the intialization functions for all individual types. More... | |
| int | remove_curse (object *op, object *caster, object *spell) |
| This function removes the cursed/damned status on equipped items. More... | |
| void | remove_door (object *op) |
| Remove non locked doors. More... | |
| void | remove_locked_door (object *op) |
| Same as remove_door() but for locked doors. More... | |
| int | remove_trap (object *op, object *skill) |
| This skill will disarm any previously discovered trap. More... | |
| void | remove_unpaid_objects (object *op, object *env, int free_items) |
| This goes throws the inventory and removes unpaid objects, and puts them back in the map (location and map determined by values of env) or frees them. More... | |
| void | rod_adjust (object *rod) |
| Adjusts rod attributes. More... | |
| void | roll_again (object *op) |
| Ask the player what to do with the statistics. More... | |
| int | roll_stat (void) |
| This rolls four 1-6 rolls and sums the best 3 of the 4. More... | |
| void | roll_stats (object *op) |
| Roll the initial player's statistics. More... | |
| int | save_player (object *op, int flag) |
| Saves a player to disk. More... | |
| void | save_throw_object (object *op, uint32_t type, object *originator) |
| Object is attacked with some attacktype (fire, ice, ...). More... | |
| void | scroll_failure (object *op, int failure, int power) |
| op made some mistake with a scroll, this takes care of punishment. More... | |
| void | send_delayed_buffers (player *pl) |
| Send all delayed buffers for a player. More... | |
| void | send_news (const object *op) |
| Send the news to a player. More... | |
| void | send_rules (const object *op) |
| Send the rules to a player. More... | |
| void | server_main (int argc, char *argv[]) |
| Server main function. More... | |
| void | set_darkness_map (mapstruct *m) |
| Set the darkness level for a map, based on the time of the day. More... | |
| void | set_first_map (object *op) |
| This loads the first map an puts the player on it. More... | |
| void | set_map_timeout (mapstruct *oldmap) |
| Enable swapping for the given map. More... | |
| void | set_player_socket (player *p, socket_struct *ns) |
| This copies the data from the socket into the player structure. More... | |
| void | set_spell_skill (object *op, object *caster, object *spob, object *dest) |
| Utility function to assign the correct skill when casting. More... | |
| int | should_director_abort (const object *op, const object *victim) |
| Check if op should abort moving victim because of it's race or slaying. More... | |
| void | show_skills (object *op, const char *search) |
| Displays a player's skill list, and some other non skill related info (god, max weapon improvements, item power). More... | |
| void | shuffle_attack (object *op) |
| This routine shuffles the attack of op to one of the ones in the list. More... | |
| int | similar_direction (int a, int b) |
| Is direction a similar to direction b? Find out in this exciting function below. More... | |
| int | singing (object *pl, int dir, object *skill) |
| Singing skill handling. More... | |
| void | skill_attack (object *tmp, object *pl, int dir, const char *string, object *skill) |
| Core routine for use when we attack using a skills system. More... | |
| int | skill_ident (object *pl, object *skill) |
| Main identification skill handling. More... | |
| int | skill_throw (object *op, object *part, int dir, object *skill) |
| Throwing skill handling. More... | |
| int | slow_living_by (object *op, const int speed_penalty) |
| int | SP_level_dam_adjust (const object *caster, const object *spob) |
| Returns adjusted damage based on the caster. More... | |
| int | SP_level_duration_adjust (const object *caster, const object *spob) |
| Adjust the duration of the spell based on level. More... | |
| int | SP_level_range_adjust (const object *caster, const object *spob) |
| Adjust the range of the spell based on level. More... | |
| int16_t | SP_level_spellpoint_cost (object *caster, object *spell, int flags) |
| Scales the spellpoint cost of a spell by it's increased effectiveness. More... | |
| int | SP_level_wc_adjust (const object *caster, const object *spob) |
| Returns adjusted wc based on the caster and the spell. More... | |
| void | spell_effect (object *spob, int x, int y, mapstruct *map, object *originator) |
| Inserts into map a spell effect based on other_arch. More... | |
| void | spell_failure (object *op, int failure, int power, object *skill) |
| Handles the various effects for differing degrees of failure badness. More... | |
| int | spell_find_dir (mapstruct *m, int x, int y, object *exclude) |
| Search what direction a spell should go in, first the center square then some close squares in the given map at the given coordinates for live objects. More... | |
| void | spring_trap (object *trap, object *victim) |
| This function generalizes attacks by runes/traps. More... | |
| int | stand_near_hostile (object *who) |
| Determine if who is standing near a hostile creature. More... | |
| int | steal (object *op, int dir, object *skill) |
| Main stealing function. More... | |
| object * | stop_item (object *op) |
| An item (ARROW or such) stops moving. More... | |
| void | store_spell_expiry (object *spell) |
| Stores in the spell when to warn player of expiration. More... | |
| int | summon_hostile_monsters (object *op, int n, const char *monstername) |
| Summons hostile monsters and places them in nearby squares. More... | |
| int | swap_map (mapstruct *map) |
| Swaps a map to disk. More... | |
| int | tailor_god_spell (object *spellop, object *caster) |
| Changes the attributes of cone, smite, and ball spells as needed by the code. More... | |
| int | teleport (object *teleporter, uint8_t tele_type, object *user) |
| Teleport an item around a nearby random teleporter of specified type. More... | |
| void | tick_the_clock (void) |
| This performs the basic function of advancing the clock one tick forward. More... | |
| void | tick_weather (void) |
| Do the weather calculations in order. More... | |
| int | transfer_ob (object *op, int x, int y, int randomly, object *originator) |
| Move an object (even linked objects) to another spot on the same map. More... | |
| int | transport_can_hold (const object *transport, const object *op, int nrof) |
| Can transport hold object op? This is a pretty trivial function, but in the future, possible transport may have more restrictions or weight reduction like containers. More... | |
| int | trap_disarm (object *disarmer, object *trap, int risk, object *skill) |
| Try to disarm a trap/rune. More... | |
| int | trap_see (object *op, object *trap) |
| Should op see trap? More... | |
| int | trap_show (object *trap, object *where) |
| Handles showing a trap/rune detonation. More... | |
| int | use_alchemy (object *op) |
| Handle use_skill for alchemy-like items. More... | |
| int | use_oratory (object *pl, int dir, object *skill) |
| Oratory skill handling. More... | |
| int | use_skill (object *op, const char *string) |
| Similar to invoke command, it executes the skill in the direction that the user is facing. More... | |
| int | verify_player (const char *name, char *password) |
| This verify that a character of name exits, and that it matches password. More... | |
| int | write_gulfstreammap (const Settings *settings) |
| Save the gulf stream to localdir. More... | |
| int | write_humidmap (const Settings *settings) |
| Save humidity information to localdir. More... | |
| int | write_mark (object *op, object *spell, const char *msg) |
| This writes a rune that contains the appropriate message. More... | |
| int | write_on_item (object *pl, const char *params, object *skill) |
| Implement the 'inscription' skill, which checks for the required skills and marked items before running either write_note() or write_scroll(). More... | |
| int | write_pressuremap (const Settings *settings) |
| Save pressure information to localdir. More... | |
| int | write_rainfallmap (const Settings *settings) |
| Save rainfall information to localdir. More... | |
| int | write_rune (object *op, object *caster, object *spell, int dir, const char *runename) |
| Player is attempting to write a magical rune. More... | |
| int | write_skymap (void) |
| Write the sky map. More... | |
| int | write_temperaturemap (const Settings *settings) |
| Save temperature information to localdir. More... | |
| int | write_weather_images (void) |
| Dump all the weather data as an image. More... | |
| int | write_winddirmap (const Settings *settings) |
| Save wind direction to localdir. More... | |
| int | write_windspeedmap (const Settings *settings) |
| Save the wind speed to localdir. More... | |
| int account_change_password | ( | const char * | account_name, |
| const char * | current_password, | ||
| const char * | new_password | ||
| ) |
Change an account password.
It does error checking, but the caller might want to do checking before getting here.
| account_name | account name we are changing |
| current_password | current password for the account or NULL. This is the unencrypted password (password as entered by user). If NULL, the current password is not checked, suitable for resetting lost passwords. |
| new_password | new password to set, unencrypted. |
| 0 | password changed successfully. |
| 1 | account name, old or new password has invalid character. |
| 2 | account does not exist. |
| 3 | current password is invalid. |
Definition at line 627 of file account.cpp.
References account_check_string(), accounts, check_password(), newhash(), strcasecmp(), and strdup_local.
Referenced by account_password(), and command_accountpasswd().
Here is the call graph for this function:
Here is the caller graph for this function:| void account_char_add | ( | Account_Chars * | chars, |
| player * | pl | ||
| ) |
This adds a player to the list of accounts.
We check to see if the player has already been added to this account - if so, we just update the infromation. Note that all strings are filled in, even if that may just be a blank field. This simplifies a lot of the code instead of having to deal with NULL values. Note that this routine is also used to update existing entries - if the character already exists, we update it, otherwise it is added.
| chars | Existing list of characters for account. May be NULL. |
| pl | Player structure to add |
Definition at line 207 of file account_char.cpp.
References add_string(), object::arch, Account_Char::character_class, Account_Chars::chars, archetype::clone, Account_Char::face, object::face, free_string(), Account_Char::isDead, Account_Char::level, object::level, Account_Char::map, object::map, player::maplevel, Account_Char::name, Face::name, object::name, mapstruct::name, player::ob, Account_Char::party, player::party, partylist::partyname, and Account_Char::race.
Referenced by save_player().
Here is the call graph for this function:
Here is the caller graph for this function:| void account_char_free | ( | Account_Chars * | chars | ) |
This frees all data associated with the character information.
| chars | Data to free. The caller should make sure it no longer uses any data in this list. |
Definition at line 345 of file account_char.cpp.
References Account_Chars::account_name, Account_Chars::chars, chars_loaded, free_string(), and Account_Chars::ref_count.
Referenced by account_add_player_cmd(), free_newsocket(), init_connection(), key_confirm_quit(), kill_player_permadeath(), make_perma_dead(), send_account_players(), set_player_socket(), and unmake_perma_dead().
Here is the call graph for this function:
Here is the caller graph for this function:| Account_Chars* account_char_load | ( | const char * | account_name | ) |
For a given account name, load the character information and return it.
It is the responsibility of the caller to call account_char_free() on the returned value to free it.
| account_name | Name of the account. The name should be validated before this routine is called (eg, passed checks for legitimate characters and logged in) |
Definition at line 135 of file account_char.cpp.
References account_char_load_from_file(), Account_Chars::account_name, add_string(), chars_loaded, and Account_Chars::ref_count.
Referenced by account_add_player_cmd(), make_perma_dead(), send_account_players(), and unmake_perma_dead().
Here is the call graph for this function:
Here is the caller graph for this function:| void account_char_remove | ( | Account_Chars * | chars, |
| const char * | pl_name | ||
| ) |
This removes a character on this account.
This is typically used when a character has been deleted, and not for general cleanup
| chars | Existing list of characters for account. |
| pl_name | The name of the character |
Definition at line 313 of file account_char.cpp.
References Account_Char::character_class, Account_Chars::chars, Account_Char::face, free_string(), Account_Char::map, Account_Char::name, Account_Char::party, and Account_Char::race.
Here is the call graph for this function:| void account_char_save | ( | Account_Chars * | chars | ) |
Saves the character information for the given account.
| chars | previously loaded/generated list of character information for this account. |
Definition at line 158 of file account_char.cpp.
References ACCOUNT_DIR, Account_Chars::account_name, Account_Chars::chars, Settings::localdir, MAX_BUF, of_close(), of_open(), and settings.
Referenced by account_add_player_cmd(), free_newsocket(), key_confirm_quit(), kill_player_permadeath(), make_perma_dead(), save_player(), and unmake_perma_dead().
Here is the call graph for this function:
Here is the caller graph for this function:| int account_check_string | ( | const char * | str | ) |
Checks a string to make sure it does not have any invalid characters.
We are fairly permissive on character here. String must start with alphanumeric String must not contain :;/'[ String can not end if a space This string will get used for file/directory names, but so long as as characters are not included that are not illegal, one can still manipulate the file/directory by putting it in quotes. If one starts to block all characters that may get interperted by shells, a large number of characters now get blocked (|*]()!, etc), and deciding which should be allowed and not just becomes a judgement call, so easier to just allow all and have the user put it in quotes.
| str | string to check |
Definition at line 360 of file account.cpp.
References MAX_NAME.
Referenced by account_change_password(), account_new(), account_new_cmd(), account_password(), and create_player_cmd().
Here is the caller graph for this function:| const char* account_exists | ( | const char * | account_name | ) |
Checks the existing accounts, and see if this account exists.
This can also be used to get the official name for the account (eg, as user first entered, so Mark instead of mARk)
| account_name | account name we are looking for. |
Definition at line 296 of file account.cpp.
References accounts, and strcasecmp().
Referenced by account_login_cmd(), account_new(), and account_new_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| const char* account_get_account_for_char | ( | const char * | charname | ) |
This looks at all the accounts and sees if charname is associated with any of them.
| charname | character name to check for. |
Definition at line 579 of file account.cpp.
References accounts.
Referenced by account_add_player_cmd(), and save_player().
Here is the caller graph for this function:| linked_char* account_get_additional_chars | ( | const char * | account_name, |
| const Account_Chars * | chars, | ||
| int * | count | ||
| ) |
Get a list of character names linked to the specified account which are not listed in chars.
| account_name | account name. | |
| chars | known character names. | |
| [out] | count | will be incremented by the number of items returned. Not initialized before use. |
Definition at line 550 of file account.cpp.
References accounts, char_in_list(), Account_Chars::chars, linked_char::name, linked_char::next, and strcasecmp().
Referenced by send_account_players().
Here is the call graph for this function:
Here is the caller graph for this function:| char** account_get_players_for_account | ( | const char * | account_name | ) |
Returns an array of strings for the characters on this account - the array is null terminated.
In fact, it just returns the ac->character_names.
| account_name | name of the account to get the players for. |
Definition at line 519 of file account.cpp.
References accounts, and strcasecmp().
Referenced by account_play_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| int account_is_logged_in | ( | const char * | name | ) |
This checkes if an account is logged in.
It is mainly used because some operations should not be done on logged in accounts (keeping everything synchronized is harder.)
| name | name to look for. |
Definition at line 604 of file account.cpp.
References accounts_logged_in, and name.
Referenced by account_add_player_cmd().
Here is the caller graph for this function:| int account_link | ( | const char * | account_name, |
| const char * | player_name | ||
| ) |
Adds a player name to an account.
Player corresponds to the names used in the pl object, not the person sitting at the computer. This function presumes that the caller has done the work to verify that the player does in fact exist, and does any related work to update the player. What this function does is simply update the account structure.
| account_name | name of the account we are adding this player to. |
| player_name | name of this player. |
| 0 | player name added successfully. |
| 1 | could not find account of that name. |
Definition at line 444 of file account.cpp.
References accounts, ensure_available_characters(), strcasecmp(), and strdup_local.
Referenced by account_add_player_cmd(), and save_player().
Here is the call graph for this function:
Here is the caller graph for this function:| int account_login | ( | const char * | account_name, |
| const char * | account_password | ||
| ) |
Check if the given account exists, and whether the password is correct.
Note - if we do get a match, we update the last_login value - it is presumed that if someone knows the right accountname/password, that the account is effectively getting logged in.
| account_name | account name we are looking for. |
| account_password | password for the account. This is the unencrypted password (password as entered by user) |
Definition at line 318 of file account.cpp.
References account_password(), accounts, accounts_logged_in, check_password(), strcasecmp(), and time.
Referenced by account_login_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| void account_logout | ( | const char * | account_name | ) |
Remove 'account_name' from the list of logged in accounts.
Definition at line 337 of file account.cpp.
References accounts_logged_in.
Referenced by free_newsocket().
Here is the caller graph for this function:| int account_new | ( | const char * | account_name, |
| const char * | account_password | ||
| ) |
Adds an account.
It does error checking, but the caller might want to do checking before getting here.
| account_name | account name we are adding |
| account_password | password for the account. This is the unencrypted password (password as entered by user) |
| 0 | account added successfully. |
| 1 | name or password has invalid character. |
| 2 | account already exists. |
Definition at line 399 of file account.cpp.
References account_alloc(), account_check_string(), account_exists(), account_password(), accounts, accounts_loaded, account_struct::name, newhash(), account_struct::password, and strdup_local.
Referenced by account_new_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| int account_remove_player | ( | const char * | account_name, |
| const char * | player_name | ||
| ) |
Removes a player name from an account.
Player corresponds to the names used in the pl object, not the person sitting at the computer. This function presumes that the caller has done the work to verify that the player does in fact exist, and does any related work to update the player. What this function does is simply update the account structure.
| account_name | name of the account we are removing this player from. |
| player_name | name of this player. |
| 0 | player name removed successfully. |
| 1 | could not find account of that name. |
| 2 | player of this name not on account. |
Definition at line 474 of file account.cpp.
References accounts, and strcasecmp().
Referenced by account_add_player_cmd(), key_confirm_quit(), and kill_player_permadeath().
Here is the call graph for this function:
Here is the caller graph for this function:| void accounts_clear | ( | void | ) |
This is used purely by the test harness - by clearing the accounts, it can then verify that the data is added is loaded back into memory properly.
As such, we don't worry about memory cleanup, etc.
Definition at line 152 of file account.cpp.
References accounts, and accounts_loaded.
| void accounts_load | ( | void | ) |
This loads all the account entries into memory.
It is presumed to only be called once during the program startup.
Definition at line 161 of file account.cpp.
References account_alloc(), ACCOUNT_FILE, accounts, accounts_loaded, buf, bufferreader_destroy(), bufferreader_init_from_file(), bufferreader_next_line(), account_struct::character_names, account_struct::created, ensure_available_characters(), fields, account_struct::last_login, llevError, llevInfo, Settings::localdir, LOG(), MAX_BUF, account_struct::name, NUM_ACCOUNT_FIELDS, account_struct::num_characters, account_struct::password, settings, split_string(), and strdup_local.
Referenced by init().
Here is the call graph for this function:
Here is the caller graph for this function:| void accounts_save | ( | void | ) |
Save all the account information.
Since the data is stored in a flat file, if an update is needed for an account, the only way to save updates is to save all the data - there isn't an easy way to just add another player name for an account.
Definition at line 255 of file account.cpp.
References ACCOUNT_FILE, account_write_entry(), accounts, accounts_loaded, Settings::localdir, MAX_BUF, of_close(), of_open(), settings, and time.
Referenced by account_new_cmd(), cleanup(), and do_specials().
Here is the call graph for this function:
Here is the caller graph for this function:| player* add_player | ( | socket_struct * | ns, |
| int | flags | ||
| ) |
Tries to add player on the connection passwd in ns.
Player object is created and put on the first map, rules/news/motd are sent.
| ns | connection. |
| flags | flag values are define in player.h: ADD_PLAYER_NEW - If set, go right to new character creation - used in case of new account code. We don't display motd and other bits in this case either. ADD_PLAYER_NO_MAP - Do not set up map information - used in character login method >2 where we do not use the same starting map. |
Definition at line 469 of file player.cpp.
References add_friendly_object(), ADD_PLAYER_NEW, ADD_PLAYER_NO_MAP, ADD_PLAYER_NO_STATS_ROLL, CLEAR_FLAG, display_motd(), FLAG_FRIENDLY, flags, get_name(), get_player(), Ns_Avail, player::ob, player_set_state(), roll_again(), send_news(), send_rules(), set_first_map(), set_player_socket(), ST_ROLL_STAT, and socket_struct::status.
Referenced by add_me_cmd(), and create_player_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| void add_server_collect_hooks | ( | ) |
Definition at line 1082 of file init.cpp.
References assets_add_collector_hook(), load_materials(), and load_races().
Referenced by init().
Here is the call graph for this function:
Here is the caller graph for this function:Change items to gold nuggets.
Only works for players.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| 0 | op isn't a player. |
| 1 | op is a player. |
Definition at line 2306 of file spell_effect.cpp.
References alchemy_object(), object::contr, object::duration, FLAG_ALIVE, FLAG_IS_CAULDRON, FLAG_NO_PICK, FOR_INV_FINISH, FOR_INV_PREPARE, FOR_MAP_FINISH, FOR_MAP_PREPARE, get_map_flags(), GET_MAP_MOVE_BLOCK, socket_struct::look_position, object::map, MOVE_WALK, do_skill_cb_data::op, P_NO_MAGIC, P_OUT_OF_MAP, place_alchemy_objects(), PLAYER, QUERY_FLAG, player::socket, SP_level_dam_adjust(), SP_level_duration_adjust(), object::type, weight, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Generalization of staff_to_snake().
Makes a golem out of the caster's weapon. The golem is based on the archetype specified, modified by the caster's level and the attributes of the weapon. The weapon is inserted in the golem's inventory so that it falls to the ground when the golem dies. This code was very odd - code early on would only let players use the spell, yet the code was full of player checks. I've presumed that the code that only let players use it was correct, and removed all the other player checks. MSW 2003-01-06
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| dir | casting direction. |
| 0 | spell failure. |
| 1 | spell was successful. |
Definition at line 3065 of file spell_effect.cpp.
References a(), add_friendly_object(), add_string(), object::anim_speed, object::animation, object::arch, arch_to_object(), AT_PHYSICAL, ATNR_BLIND, ATNR_CONFUSION, ATNR_DEATH, ATNR_DEPLETE, ATNR_FEAR, ATNR_PARALYZE, ATNR_PHYSICAL, ATNR_POISON, ATNR_SLOW, ATNR_TURN_UNDEAD, object::attacktype, buf, caster_level(), CLEAR_FLAG, living::Con, object::contr, object::count, living::dam, living::Dex, do_skill_cb_data::dir, object::direction, draw_ext_info, draw_ext_info_format(), esrv_update_item(), living::exp, object::face, find_marked_object(), fix_object(), FLAG_ANIMATE, FLAG_APPLIED, FLAG_FRIENDLY, FLAG_MONSTER, FLAG_REMOVED, FLAG_UNPAID, FLAG_USE_WEAPON, free_string(), freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, GOLEM, player::golem_count, living::hp, object::last_anim, llevError, LOG(), m, object::magic, object::map, object::materialname, MAX, MAX_BUF, living::maxhp, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, object::name, archetype::name, name_to_material(), NDI_BLACK, NDI_UNIQUE, object::nrof, NROFATTACKS, object_find_free_spot(), object_insert_in_map_at(), object_insert_in_ob(), object_remove(), object_set_owner(), object_split(), object_update_speed(), do_skill_cb_data::op, P_OUT_OF_MAP, pets_control_golem(), PLAYER, QUERY_FLAG, query_name(), range_golem, player::ranges, object::resist, materialtype_t::save, SET_FLAG, set_spell_skill(), player::shoottype, SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), object::speed, object::speed_left, spell, object::state, object::stats, living::Str, object::type, UPD_NROF, living::wc, WEAPON, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| int apply_auto | ( | object * | op | ) |
Map was just loaded, handle op's initialization.
Generates shop floor's item, and treasures.
| op | object to initialize. |
Definition at line 211 of file main.cpp.
References CLEAR_FLAG, create_treasure(), mapstruct::difficulty, object::env, living::exp, FLAG_AUTO_APPLY, FLAG_BLESSED, FLAG_CURSED, FLAG_DAMNED, FLAG_IS_A_TEMPLATE, FLAG_UNPAID, FOR_INV_FINISH, FOR_INV_PREPARE, FREE_OBJ_NO_DESTROY_CALLBACK, generate_treasure(), GT_ENVIRONMENT, GT_ONLY_GOOD, HAS_RANDOM_ITEMS, living::hp, identify(), INS_NO_WALK_ON, object::map, MAX, object_free(), object_free_drop_inventory(), object_insert_in_map_at(), object_insert_in_ob(), object_remove(), QUERY_FLAG, object::randomitems, SET_FLAG, SHOP_FLOOR, object::stats, TREASURE, object::type, object::x, and object::y.
Referenced by apply_auto_fix(), auto_apply_fix_inventory(), and do_auto_apply().
Here is the call graph for this function:
Here is the caller graph for this function:| void apply_auto_fix | ( | mapstruct * | m | ) |
Go through the entire map (only the first time when an original map is loaded) and performs special actions for certain objects (most initialization of chests and creation of treasures and stuff).
Calls apply_auto() if appropriate.
| m | map to fix. |
Definition at line 258 of file main.cpp.
References apply_auto(), auto_apply_fix_inventory(), check_trigger(), CLASS, CONTAINER, create_treasure(), FLAG_AUTO_APPLY, FLAG_IS_LINKED, FLAG_MONSTER, FOR_MAP_FINISH, FOR_MAP_PREPARE, HAS_RANDOM_ITEMS, HEAD, m, MAP_HEIGHT, MAP_WIDTH, monster_check_apply_all(), object_update_speed(), PLAYER, PLAYER_CHANGER, QUERY_FLAG, SPELL, TIMED_GATE, TREASURE, TRIGGER_BUTTON, and TRIGGER_PEDESTAL.
Referenced by enter_unique_map(), generate_random_map(), and mapfile_load().
Here is the call graph for this function:
Here is the caller graph for this function:| void apply_builder_remove | ( | object * | pl, |
| int | dir | ||
| ) |
Item remover.
Removes first buildable item, either under or above the floor
| pl | player removing an item. |
| dir | direction the player is trying to remove. |
Definition at line 890 of file build_map.cpp.
References object::above, BUTTON, CF_HANDLE, DETECTOR, DOOR, draw_ext_info, draw_ext_info_format(), FLAG_IS_FLOOR, FLAG_IS_LINKED, FLOOR, freearr_x, freearr_y, GATE, GET_MAP_OB, llevError, LOG(), MAGIC_EAR, object::map, MAX_BUF, MSG_TYPE_APPLY, MSG_TYPE_APPLY_BUILD, name, NDI_UNIQUE, object_free_drop_inventory(), object_remove(), mapstruct::path, PEDESTAL, QUERY_FLAG, query_name(), remove_button_link(), SIGN, TIMED_GATE, object::type, WALL, object::x, and object::y.
Referenced by apply_map_builder().
Here is the call graph for this function:
Here is the caller graph for this function:Living thing is applying an object.
| pl | object causing op to be applied. |
| op | object being applied. |
| aflag | special (always apply/unapply) flags. Nothing is done with them in this function - they are passed to apply_special(). |
| quiet | if 1, suppresses the "don't know how to apply" and "you must get it first" messages as needed by apply_by_living_below(). There can still be "but you are floating high above the ground" messages. |
Definition at line 299 of file apply.cpp.
References object::anim_suffix, apply_anim_suffix(), apply_manual(), draw_ext_info, draw_ext_info_format(), object::env, FLAG_WAS_WIZ, FLAG_WIZ, MAX_BUF, METHOD_ERROR, METHOD_OK, METHOD_SILENT_ERROR, METHOD_UNHANDLED, MOVE_FLYING, object::move_type, MSG_TYPE_APPLY, MSG_TYPE_APPLY_ERROR, name, NDI_UNIQUE, object_free(), object_remove(), play_sound_map(), PLAYER, QUERY_FLAG, query_name(), SOUND_TYPE_ITEM, and object::type.
Referenced by apply_by_living_below(), apply_cmd(), and command_apply().
Here is the call graph for this function:
Here is the caller graph for this function:| void apply_by_living_below | ( | object * | pl | ) |
Attempt to apply the object 'below' the player.
If the player has an open container, we use that for below, otherwise we use the ground.
| pl | player. |
Definition at line 357 of file apply.cpp.
References apply_by_living(), object::below, object::container, object::contr, FLAG_IS_FLOOR, FOR_OB_AND_BELOW_FINISH, FOR_OB_AND_BELOW_PREPARE, object::inv, object::invisible, METHOD_OK, object::move_on, object::move_type, ob_apply(), QUERY_FLAG, TRANSPORT, player::transport, and object::type.
Referenced by cfapi_object_apply_below(), command_apply(), and knowledge_alchemy_attempt().
Here is the call graph for this function:
Here is the caller graph for this function:Checks to see if 'who' can apply object 'op'.
| who | living thing trying to apply op. |
| op | object applied. |
Definition at line 678 of file apply.cpp.
References object::body_info, object::body_used, BOW, CAN_APPLY_NEVER, CAN_APPLY_RESTRICTION, CAN_APPLY_UNAPPLY, CAN_APPLY_UNAPPLY_CHOICE, CAN_APPLY_UNAPPLY_MULT, FABS, FLAG_USE_ARMOUR, FLAG_USE_BOW, FLAG_USE_RANGE, FLAG_USE_RING, FLAG_USE_SHIELD, FLAG_USE_WEAPON, get_item_from_body_location(), object::inv, IS_ARMOR, IS_SHIELD, IS_WEAPON, NUM_BODY_LOCATIONS, object_find_by_type_applied(), PLAYER, QUERY_FLAG, RING, ROD, SHIELD, object::type, WAND, and WEAPON.
Referenced by apply_check_apply_restrictions(), and monster_check_apply().
Here is the call graph for this function:
Here is the caller graph for this function:Applies (race) changes to a player.
| pl | object to change. |
| change | what kind of changes to apply. Should be of type CLASS. |
| limit_stats | uses the AC_PLAYER_STAT defines from define.h: AC_PLAYER_STAT_LIMIT: Limit stats to racial maximum AC_PLAYER_STAT_NO_CHANGE: Do not make any stat adjustments |
Definition at line 1325 of file apply.cpp.
References AC_PLAYER_STAT_LIMIT, AC_PLAYER_STAT_NO_CHANGE, object::anim_speed, object::anim_suffix, animate_object(), object::animation, object::arch, buf, change_attr_value(), CHARISMA, CLASS, CLEAR_FLAG, archetype::clone, object::contr, object::face, object::facing, FLAG_ANIMATE, FLAG_USE_WEAPON, FORCE, GET_ANIM, get_attr_value(), give_initial_items(), MAX_BUF, Animations::name, NUM_STATS, object_find_by_name(), object_present_in_ob_by_name(), player::orig_stats, QUERY_FLAG, object::randomitems, rndm(), set_attr_value(), SET_FLAG, object::stats, try_find_animation(), and object::type.
Referenced by apply_race_and_class(), and player_changer_type_process().
Here is the call graph for this function:
Here is the caller graph for this function:| int apply_check_weapon_power | ( | const object * | who, |
| int | improves | ||
| ) |
This checks to see of the player (who) is sufficient level to use a weapon with improves improvements (typically last_eat).
We take an int here instead of the object so that the improvement code can pass along the increased value to see if the object is usable. we return 1 (true) if the player can use the weapon. See ../types/weapon_improver/weapon_improver.c
| who | living to check |
| improves | improvement level. |
Definition at line 793 of file apply.cpp.
References object::level.
Referenced by apply_special(), and improve_weapon().
Here is the caller graph for this function:| void apply_handle_yield | ( | object * | tmp | ) |
This checks whether the object has a "on_use_yield" field, and if so generated and drops matching item.
| tmp | item that was applied. |
Definition at line 122 of file apply.cpp.
References create_archetype(), drop(), object::env, INS_BELOW_ORIGINATOR, object::map, object_get_value(), object_insert_in_map_at(), object_insert_in_ob(), object::x, and object::y.
Referenced by food_type_apply(), poison_type_apply(), and potion_type_apply().
Here is the call graph for this function:
Here is the caller graph for this function:Main apply handler.
Checks for unpaid items before applying.
| op | object causing tmp to be applied. |
| tmp | object being applied. |
| aflag | special (always apply/unapply) flags. Nothing is done with them in this function - they are passed to apply_special(). |
Definition at line 259 of file apply.cpp.
References apply_check_race_restrictions(), object::contr, draw_ext_info, FLAG_APPLIED, FLAG_UNPAID, HEAD, METHOD_SILENT_ERROR, MSG_TYPE_APPLY, MSG_TYPE_APPLY_ERROR, NDI_UNIQUE, ob_apply(), play_sound_player_only(), PLAYER, QUERY_FLAG, SOUND_TYPE_ITEM, and object::type.
Referenced by apply_by_living(), cfapi_object_apply(), give_initial_items(), lightable_type_apply(), monster_apply_below(), monster_check_apply(), monster_use_scroll(), polymorph_living(), transmute_item_to_flower(), and write_scroll().
Here is the call graph for this function:
Here is the caller graph for this function:| void apply_map_builder | ( | object * | pl, |
| int | dir | ||
| ) |
Global building function.
This is the general map building function. Called when the player 'fires' a builder or remover object.
| pl | player building or removing. |
| dir | building direction. |
Definition at line 960 of file build_map.cpp.
References apply_builder_floor(), apply_builder_item(), apply_builder_remove(), apply_builder_wall(), apply_builder_window(), object::arch, can_build_over(), object::contr, draw_ext_info, find_archetype(), find_marked_object(), FLAG_IS_BUILDABLE, FLAG_UNPAID, FOR_OB_AND_ABOVE_FINISH, FOR_OB_AND_ABOVE_PREPARE, freearr_x, freearr_y, GET_MAP_OB, IS_PLAYER(), llevError, LOG(), object::map, MAP_HEIGHT, MAP_WIDTH, MATERIAL, MSG_TYPE_APPLY, MSG_TYPE_APPLY_BUILD, archetype::name, NDI_UNIQUE, object_create_arch(), object_decrease_nrof_by_one, mapstruct::path, QUERY_FLAG, range_builder, player::ranges, SET_FLAG, SIGN, object::slaying, ST_BD_BUILD, ST_BD_REMOVE, ST_MAT_FLOOR, ST_MAT_ITEM, ST_MAT_WALL, ST_MAT_WINDOW, object::subtype, object::type, object::x, and object::y.
Referenced by fire().
Here is the call graph for this function:
Here is the caller graph for this function:This is somewhat like key_change_class() above, except we know the race to change to, but we still basically need to do the same work (apply bonuses, update archetype, etc.)
| op | Player object |
| race | race to use - caller should do sanity checking that this is a valid race. |
| opclass | class to use - like race, caller should do sanity checking. |
| stats | If set, use these stats for the character, do not apply new ones. Note: It is required that the caller only use valid stat values (generated by check_race_and_class() for example), as this function will not do checking on the stats. |
Definition at line 1486 of file player.cpp.
References AC_PLAYER_STAT_NO_CHANGE, add_statbonus(), add_string(), allowed_class(), apply_changes_to_player(), object::arch, buf, object::carrying, CLEAR_FLAG, archetype::clone, object::contr, create_treasure(), esrv_add_spells(), esrv_new_player(), esrv_send_inventory(), esrv_update_item(), EVENT_BORN, EVENT_LOGIN, events_execute_global_event(), find_treasurelist(), fix_object(), FLAG_WIZ, free_string(), get_attr_value(), give_initial_items(), living::grace, socket_struct::host, living::hp, object::inv, player::is_wraith, link_player_skills(), Settings::localdir, make_path_to_file(), MAX_BUF, living::maxhp, living::maxsp, name, object::name, object::name_pl, NUM_STATS, object_copy(), object_find_by_name(), object_free(), object_remove(), object_set_msg(), object_update(), player::orig_stats, Settings::playerdir, pticks, object::randomitems, SET_ANIMATION, set_attr_value(), settings, player::socket, living::sp, stats, object::stats, strlcpy(), player::title, UP_OBJ_FACE, UPD_FACE, and object::weight.
Referenced by create_player_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:Apply an object.
This function doesn't check for unpaid items, but check other restrictions.
Usage example: apply_special (who, op, AP_UNAPPLY | AP_IGNORE_CURSE)
| who | object using op. It can be a monster. |
| op | object being used. Should be an equipment type item, eg, one which you put on and keep on for a while, and not something like a potion or scroll. |
| aflags | combination of AP_xxx flags. |
Definition at line 818 of file apply.cpp.
References AMULET, AP_APPLY, AP_BASIC_FLAGS, AP_IGNORE_CURSE, AP_NOPRINT, AP_UNAPPLY, apply_check_apply_restrictions(), apply_check_item_power(), apply_check_owner(), apply_check_personalized_blessings(), apply_check_weapon_power(), apply_update_ranged_skill(), ARMOUR, BOOTS, BOW, BRACERS, BUILDER, change_abil(), change_skill(), object::chosen_skill, CLOAK, object::contr, draw_ext_info, draw_ext_info_format(), object::env, esrv_update_item(), find_skill_by_name(), fix_object(), FLAG_APPLIED, FLAG_BEEN_APPLIED, FLAG_CURSED, FLAG_DAMNED, FLAG_KNOWN_CURSED, FLAG_READY_BOW, FLAG_READY_RANGE, FLAG_READY_SKILL, FLAG_READY_WEAPON, GIRDLE, GLOVES, HELMET, object::last_eat, llevError, LOG(), MAX_BUF, MSG_TYPE_APPLY, MSG_TYPE_APPLY_CURSED, MSG_TYPE_APPLY_ERROR, MSG_TYPE_APPLY_SUCCESS, MSG_TYPE_APPLY_UNAPPLY, NDI_UNIQUE, object::nrof, object_insert_in_ob(), object_split(), PLAYER, QUERY_FLAG, query_name(), object::race, range_bow, range_builder, range_misc, player::ranges, RING, ROD, SET_FLAG, SHIELD, player::shoottype, SKILL, object::skill, SKILL_TOOL, object::type, unapply_special(), UPD_FLAGS, UPD_NAME, UPD_NROF, UPD_WEIGHT, WAND, and WEAPON.
Referenced by adjust_skill_tool(), attack_hth(), change_skill(), drop_object(), find_throw_ob(), improve_armour(), improve_weapon(), legacy_ob_apply(), put_object_in_sack(), and stop_using_item().
Here is the call graph for this function:
Here is the caller graph for this function:Simple wrapper for attack_ob_simple(), will use hitter's values.
| op | victim. |
| hitter | attacker. |
Definition at line 937 of file attack.cpp.
References attack_ob_simple(), living::dam, HEAD, object::stats, and living::wc.
Referenced by do_skill_attack(), and pets_move_golem().
Here is the call graph for this function:
Here is the caller graph for this function:This function is called whenever a player has switched to a new god.
It handles basically all the stat changes that happen to the player, including the removal of godgiven items (from the former cult). Handles race restrictions on god, and will punish player if needed.
| op | player switching cults. |
| new_god | new god to worship. |
Definition at line 414 of file gods.cpp.
References add_string(), ARMOUR, ATNR_COLD, ATNR_ELECTRICITY, ATNR_FIRE, ATNR_POISON, BOOK, BOOTS, cast_magic_storm(), change_abil(), CLEAR_FLAG, object::contr, create_archetype(), determine_god(), draw_ext_info_format(), find_god(), FLAG_APPLIED, FLAG_BLIND, FLAG_MAKE_INVIS, FLAG_REFL_MISSILE, FLAG_REFL_SPELL, FLAG_SEE_IN_DARK, FLAG_STARTEQUIP, FLAG_STEALTH, FLAG_UNDEAD, FLAG_USE_ARMOUR, FLAG_USE_SHIELD, FLAG_USE_WEAPON, FLAG_XRAYS, follower_remove_given_items(), living::food, FOR_INV_FINISH, FOR_INV_PREPARE, FORCE, free_string(), get_archetype_by_type_subtype(), give_skill_by_name(), GLOVES, god_gives_present(), living::grace, HELMET, living::hp, treasurelist::items, object::last_eat, object::last_grace, object::last_heal, object::last_sp, object::level, link_player_skills(), LOOSE_MANA, living::luck, MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_GOD, object::name, NDI_NAVY, NDI_UNIQUE, treasure::next, NROFATTACKS, object_find_by_type_subtype(), object_free_drop_inventory(), object_present_in_ob_by_name(), object_remove(), object::path_attuned, object::path_denied, object::path_repelled, player_unready_range_ob(), PREFER_LOW, QUERY_FLAG, object::race, random_roll(), object::randomitems, remove_special_prayers(), object::resist, SET_FLAG, SHIELD, SK_PRAYING, SKILL, object::slaying, living::sp, SPELL, SPELLBOOK, object::stats, stop_using_item(), object::title, update_priest_flag(), WEAPON, and worship_forbids_use().
Referenced by command_setgod(), and pray_at_altar().
Here is the call graph for this function:
Here is the caller graph for this function:Blind a living thing.
| op | victim. |
| hitter | who is attacking. |
| dam | damage to deal. |
Definition at line 2358 of file attack.cpp.
References ATNR_BLIND, BLINDNESS, change_abil(), create_archetype(), draw_ext_info_format(), fix_object(), FLAG_APPLIED, FLAG_BLIND, living::food, MAX_BUF, MSG_TYPE_ATTACK, MSG_TYPE_ATTACK_DID_HIT, NDI_UNIQUE, object_get_owner(), object_insert_in_ob(), object_present_in_ob(), query_name(), object::resist, SET_FLAG, object::speed, and object::stats.
Referenced by hit_with_one_attacktype(), and scroll_failure().
Here is the call graph for this function:
Here is the caller graph for this function:Calculates amount of experience can be gained for successful use of a skill.
Here we take the view that a player must 'overcome an opponent' in order to gain experience. Examples include foes killed combat, finding/disarming a trap, stealing from somebeing, etc.
The gained experience is based primarily on the difference in levels, exp point value of vanquished foe, the relevant stats of the skill being used and modifications in the skills[] table.
For now, monsters and players will be treated differently. Below I give the algorithm for *PLAYER *experience gain. Monster exp gain is simpler. Monsters just get 10% of the exp of the opponent.
Players get a ratio, eg, opponent lvl / player level. This is then multiplied by various things. If simple exp is true, then this multiplier, include the level difference, is always 1. This revised method prevents some cases where there are big gaps in the amount you get just because you are now equal level vs lower level
Note that the experience is calculated for one "instance" of op, whatever its count.
| who | player/creature that used the skill. |
| op | object that was 'defeated'. |
| skill | used skill. If none, it should just point back to who or be NULL. |
Definition at line 691 of file skill_util.cpp.
References living::Cha, mapstruct::difficulty, living::exp, FLAG_ALIVE, object::level, llevDebug, LOG(), object::magic, object::map, MAX, object::name, do_skill_cb_data::op, PLAYER, QUERY_FLAG, RUNE, settings, Settings::simple_exp, SKILL, skill, object::stats, TRAP, and object::type.
Referenced by book_type_apply(), detect_curse_on_item(), detect_magic_on_item(), do_hidden_move(), find_traps(), hide(), identify_object_with_skill(), kill_object(), pick_lock(), remove_trap(), scroll_type_apply(), singing(), spellbook_type_apply(), steal(), use_oratory(), and write_scroll().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 2796 of file c_wiz.cpp.
References object::contr, player::ob, and player::party.
Referenced by command_follow().
Here is the caller graph for this function:Improve statistics of some living object.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| dir | casting direction. |
| 0 | spell failed. |
| 1 | spell was successful. |
Definition at line 2050 of file spell_effect.cpp.
References living::ac, add_refcount(), add_string(), arch_to_object(), AT_PHYSICAL, ATNR_GODPOWER, object::attacktype, change_abil(), create_archetype(), determine_god(), do_skill_cb_data::dir, draw_ext_info, draw_ext_info_format(), object::duration, find_god(), find_target_for_friendly_spell(), FLAG_APPLIED, FOR_INV_FINISH, FOR_INV_PREPARE, FORCE, FORCE_CHANGE_ABILITY, FORCE_NAME, free_string(), INS_ON_TOP, object::map, MIN, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, MSG_TYPE_SPELL_TARGET, object::name, object::name_pl, NDI_UNIQUE, NROFATTACKS, object_insert_in_map_at(), object_insert_in_ob(), do_skill_cb_data::op, object::other_arch, object::path_attuned, object::race, object::resist, SET_FLAG, object::slaying, SP_level_duration_adjust(), object::speed, object::speed_left, object::stats, store_spell_expiry(), object::subtype, and living::wc.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Let's try to infect something.
| op | who is casting. |
| caster | what object is casting. |
| spell | spell object to cast. |
| dir | cast direction. |
| 0 | no one caught anything. |
| 1 | at least one living was affected. |
Definition at line 1207 of file spell_attack.cpp.
References living::ac, ARCH_DETECT_MAGIC, arch_to_object(), caster_level(), create_archetype(), living::dam, do_skill_cb_data::dir, draw_ext_info, draw_ext_info_format(), living::exp, object::facing, FLAG_MONSTER, FOR_MAP_FINISH, FOR_MAP_PREPARE, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, HEAD, living::hp, infect_object(), object::last_eat, object::last_sp, object::level, m, object::magic, object::map, living::maxgrace, living::maxhp, living::maxsp, MOVE_FLY_LOW, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, object::name, NDI_UNIQUE, object_free_drop_inventory(), object_insert_in_map_at(), object_set_owner(), do_skill_cb_data::op, P_IS_ALIVE, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, set_spell_skill(), living::sp, SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), spell, object::stats, object::type, living::wc, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Cast some stat-improving spell.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| dir | casting direction. |
| silent | if non zero, don't say when the spell is already is effect. |
| 0 | spell failed. |
| 1 | spell was successful. |
Definition at line 1902 of file spell_effect.cpp.
References living::ac, add_refcount(), arch_to_object(), object::attacktype, change_abil(), CLEAR_FLAG, create_archetype(), do_skill_cb_data::dir, draw_ext_info, draw_ext_info_format(), object::duration, living::exp, find_target_for_friendly_spell(), FLAG_APPLIED, FLAG_NO_FIX_PLAYER, FLAG_SEE_IN_DARK, FLAG_XRAYS, FOR_INV_FINISH, FOR_INV_PREPARE, FORCE, FORCE_CHANGE_ABILITY, FORCE_NAME, free_string(), get_attr_value(), living::hp, INS_ON_TOP, object::map, object::move_type, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, object::name, object::name_pl, NDI_UNIQUE, no_gain_msgs, NROFATTACKS, NUM_STATS, object_insert_in_map_at(), object_insert_in_ob(), do_skill_cb_data::op, object::other_arch, PLAYER, QUERY_FLAG, object::race, object::resist, rndm(), set_attr_value(), SET_FLAG, SP_level_dam_adjust(), SP_level_duration_adjust(), object::speed, object::speed_left, object::stats, store_spell_expiry(), object::subtype, object::type, living::wc, object::x, and object::y.
Referenced by cast_spell(), and god_intervention().
Here is the call graph for this function:
Here is the caller graph for this function:This changes the light level for the entire map.
| op | who is casting. |
| spell | actual spell object. |
| 0 | light not affected. |
| 1 | light changed. |
Definition at line 3295 of file spell_effect.cpp.
References change_map_light(), draw_ext_info, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, NDI_UNIQUE, do_skill_cb_data::op, and spell.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Casts a cone spell.
| op | person firing the object. |
| caster | object casting the spell. |
| dir | direction to fire in. |
| spell | spell that is being fired. It uses other_arch for the archetype to fire. |
| 0 | couldn't cast. |
| 1 | successful cast. |
Definition at line 297 of file spell_attack.cpp.
References arch_to_object(), AT_FEAR, AT_GODPOWER, AT_HOLYWORD, AT_TURN_UNDEAD, object::attacktype, caster_level(), living::Cha, cone_drop(), object::count, d, living::dam, do_skill_cb_data::dir, draw_ext_info, object::duration, FLAG_UNDEAD, freearr_x, freearr_y, get_fear_bonus(), get_map_flags(), GET_MAP_MOVE_BLOCK, get_turn_bonus(), object::level, llevDebug, LOG(), m, object::map, living::maxhp, MOVE_FLY_LOW, object::move_on, object::move_type, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, NDI_UNIQUE, object_insert_in_map_at(), object_set_owner(), do_skill_cb_data::op, object::other_arch, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, object::range, RUNE, set_spell_skill(), living::sp, SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), spell, object::stats, tailor_god_spell(), object::type, living::Wis, object::x, and object::y.
Referenced by cast_spell(), cast_wonder(), prayer_failure(), and spell_failure().
Here is the call graph for this function:
Here is the caller graph for this function:A spell to make an altar your god's.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| 0 | no consecration happened. |
| 1 | an altar waas consecrated. |
Definition at line 2987 of file spell_effect.cpp.
References arch_to_object(), buf, caster_level(), determine_god(), draw_ext_info, draw_ext_info_format(), find_god(), FLAG_IS_BUILDABLE, FLAG_IS_FLOOR, FOR_BELOW_FINISH, FOR_BELOW_PREPARE, HOLY_ALTAR, INS_BELOW_ORIGINATOR, letter, object::level, llevError, LOG(), object::map, MAX_BUF, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, object::name, NDI_UNIQUE, object_insert_in_map_at(), object_remove(), do_skill_cb_data::op, QUERY_FLAG, SET_FLAG, spell, tolower, and try_find_archetype().
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| int cast_create_food | ( | object * | op, |
| object * | caster, | ||
| object * | spell_ob, | ||
| int | dir, | ||
| const char * | stringarg | ||
| ) |
Create food.
Allows the choice of what sort of food object to make. If stringarg is NULL, it will create food dependent on level –PeterM
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| dir | casting direction. |
| stringarg | optional parameter specifying what kind of items to create. |
| 0 | no food created. |
| food | was created. |
Definition at line 627 of file spell_effect.cpp.
References archetypes_for_each(), cast_create_obj(), archetype::clone, do_skill_cb_data::dir, draw_ext_info, DRINK, find_archetype_by_object_type_name(), living::food, FOOD, food_choice, food_each(), food_value_choice, identify(), is_identified(), MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, NDI_UNIQUE, object::nrof, object_copy(), object_new(), do_skill_cb_data::op, SP_level_duration_adjust(), object::stats, and object::value.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| int cast_create_missile | ( | object * | op, |
| object * | caster, | ||
| object * | spell, | ||
| int | dir, | ||
| const char * | stringarg | ||
| ) |
Create a missile (nonmagic - magic +4).
Will either create bolts or arrows based on whether a crossbow or bow is equiped. If neither, it defaults to arrows. Sets the plus based on the casters level. It is also settable with the invoke command. If the caster attempts to create missiles with too great a plus, the default is used. The # of arrows created also goes up with level, so if a 30th level mage wants LOTS of arrows, and doesn't care what the plus is he could create nonnmagic arrows, or even -1, etc...
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| dir | casting direction. |
| stringarg | optional parameter specifying what kind of items to create. |
| 0 | no missile created. |
| missiles | were created. |
Definition at line 493 of file spell_effect.cpp.
References BOW, cast_create_obj(), object::count, create_archetype(), do_skill_cb_data::dir, draw_ext_info_format(), find_artifactlist(), FLAG_IDENTIFIED, FREE_OBJ_NO_DESTROY_CALLBACK, give_artifact_abilities(), artifact::item, artifactlist::items, llevDebug, LOG(), object::magic, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, NDI_UNIQUE, object::nrof, object_find_by_type_applied(), object_free(), object_was_destroyed, do_skill_cb_data::op, pick_up(), PLAYER, object::race, SET_FLAG, object::slaying, SP_level_dam_adjust(), SP_level_duration_adjust(), spell, try_find_archetype(), object::type, and object::value.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Creates object new_op in direction dir or if that is blocked, beneath the player (op).
This is really just a simple wrapper function .
| op | who is casting. |
| new_op | object to insert. |
| dir | direction to insert into. Can be 0 to insert below. |
Definition at line 494 of file spell_util.cpp.
References do_skill_cb_data::dir, draw_ext_info, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, INS_BELOW_ORIGINATOR, m, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_INFO, NDI_UNIQUE, OB_TYPE_MOVE_BLOCK, object_insert_in_map_at(), do_skill_cb_data::op, P_OUT_OF_MAP, object::x, and object::y.
Referenced by cast_create_food(), cast_create_missile(), cast_create_town_portal(), and cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:This function cast the spell of town portal for op.
The spell operates in two passes. During the first one a place is marked as a destination for the portal. During the second one, 2 portals are created, one in the position the player cast it and one in the destination place. The portal are synchronized and 2 forces are inserted in the player to destruct the portal next time player creates a new portal pair. This spell has a side effect that it allows people to meet each other in a permanent, private, apartments by making a town portal from it to the town or another public place. So, check if the map is unique and if so return an error
Code by Tchize (david.delbecq@usa.net)
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| 0 | spell was insuccessful for some reason. |
| 1 | spell worked. |
Definition at line 1241 of file spell_effect.cpp.
References add_string(), ARCH_PORTAL_FAILED, cast_create_obj(), caster_level(), object::contr, create_archetype(), Settings::create_home_portals, draw_ext_info, EXIT_PATH, EXIT_X, EXIT_Y, FREE_AND_COPY, HUGE_BUF, mapstruct::last_reset_time, llevError, LOG(), object::map, map_path_unique(), MAP_PLAYER_UNIQUE, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, object::name, object::name_pl, NDI_NAVY, NDI_UNIQUE, object_free(), object_insert_in_map_at(), object_insert_in_ob(), object_remove(), object_set_msg(), do_skill_cb_data::op, mapstruct::path, object::race, ready_map_name(), settings, spell, town_portal_destroy_existing(), town_portal_find_force(), player::transport, mapstruct::unique, object::weapontype, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Curse an object, reducing its statistics.
| op | who is casting. |
| caster | what object is casting. |
| spell_ob | spell object to cast. |
| dir | cast direction. |
| 0 | curse had no effect. |
| 1 | something was cursed. |
Definition at line 800 of file spell_attack.cpp.
References living::ac, add_refcount(), arch_to_object(), change_abil(), create_archetype(), determine_god(), do_skill_cb_data::dir, object::direction, draw_ext_info, draw_ext_info_format(), object::duration, find_god(), fix_object(), FLAG_APPLIED, FOR_INV_FINISH, FOR_INV_PREPARE, FORCE, FORCE_CHANGE_ABILITY, FORCE_NAME, free_string(), get_pointed_target(), INS_ON_TOP, object::last_grace, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, MSG_TYPE_VICTIM, MSG_TYPE_VICTIM_SPELL, object::name, object::name_pl, NDI_UNIQUE, object_insert_in_map_at(), object_insert_in_ob(), do_skill_cb_data::op, object::other_arch, object::path_denied, object::path_repelled, PLAYER, object::race, object::range, SET_FLAG, SP_level_duration_adjust(), object::speed, object::speed_left, SPELL_GRACE, object::stats, object::subtype, object::type, living::wc, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Hit all monsters around the caster.
| op | who is casting. |
| caster | what object is casting. |
| spell_ob | spell object to cast. |
Definition at line 707 of file spell_attack.cpp.
References arch_to_object(), ATNR_MAGIC, object::attacktype, change_skill(), living::dam, object::duration, find_skill_by_name(), FLAG_ALIVE, FLAG_FRIENDLY, FOR_MAP_FINISH, FOR_MAP_PREPARE, friendly, get_map_flags(), HEAD, hit_player(), m, make_object_glow(), object::map, object_insert_in_map_at(), do_skill_cb_data::op, object::other_arch, P_IS_ALIVE, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, object::range, object::resist, object::skill, skill, SP_DESTRUCTION, SP_FAERY_FIRE, SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), object::stats, object::subtype, object::type, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Detect magic or invisible items.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
Definition at line 2580 of file spell_effect.cpp.
References ALTAR, object::arch, arch_to_object(), AT_MAGIC, object::attacktype, BOOK, BUTTON, caster_level(), CF_HANDLE, living::Cha, CLEAR_FLAG, determine_god(), esrv_send_item(), EXIT, find_god(), FLAG_ANIMATE, FLAG_CURSED, FLAG_DAMNED, FLAG_IDENTIFIED, FLAG_IS_FLOOR, FLAG_KNOWN_CURSED, FLAG_KNOWN_MAGICAL, FLAG_MAKE_INVIS, FLAG_MONSTER, FLAG_WIZ, object::flags, floor, living::food, FOR_INV_FINISH, FOR_INV_PREPARE, FOR_OB_AND_BELOW_FINISH, FOR_OB_AND_BELOW_PREPARE, FREE_AND_COPY, GATE, get_map_flags(), GET_MAP_TOP, object::glow_radius, HEAD, HOLE, HOLY_ALTAR, object::invisible, is_magical(), object::last_anim, object::level, level, LOCKED_DOOR, m, object::map, object::map_layer, object::more, object::move_allow, object::move_block, object::move_type, object::name, object_create_arch(), object_insert_in_map_at(), object_update_speed(), object_value_set(), do_skill_cb_data::op, P_OUT_OF_MAP, do_skill_cb_data::part, PLAYER, PREFER_HIGH, QUERY_FLAG, object::race, random_roll(), archetype::reference_count, RUNE, SET_FLAG, SIGN, object::slaying, SP_level_range_adjust(), SPECIAL_KEY, object::speed, object::speed_left, spell, object::stats, TELEPORTER, TRAPDOOR, TREASURE, TRIGGER_PEDESTAL, object::type, WEAPON, object::weight, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Handles op throwing objects of type 'DUST'.
This is much simpler in the new spell code - we basically just treat this as any other spell casting object.
| op | object throwing. |
| throw_ob | what to throw. |
| dir | direction to throw into. |
Definition at line 3954 of file player.cpp.
References cast_spell(), draw_ext_info_format(), find_skill_by_name(), FLAG_REMOVED, object::inv, llevError, LOG(), MSG_TYPE_APPLY, MSG_TYPE_APPLY_SUCCESS, object::name, NDI_UNIQUE, object_free_drop_inventory(), object_remove(), PLAYER, POTION, QUERY_FLAG, object::skill, and object::type.
Referenced by do_throw().
Here is the call graph for this function:
Here is the caller graph for this function:Basically destroys earthwalls in the area.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| 0 | op isn't a player. |
| 1 | op is a player. |
Definition at line 855 of file spell_effect.cpp.
References AT_PHYSICAL, FLAG_TEAR_DOWN, FOR_MAP_FINISH, FOR_MAP_PREPARE, get_map_flags(), GET_MAP_MOVE_BLOCK, hit_player(), m, object::map, do_skill_cb_data::op, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, object::range, SP_level_range_adjust(), object::type, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Heals something.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| dir | casting direction. |
Definition at line 1747 of file spell_effect.cpp.
References arch_present_in_ob(), arch_to_object(), AT_BLIND, AT_CONFUSION, AT_DISEASE, AT_POISON, cure_disease(), do_skill_cb_data::dir, draw_ext_info, find_target_for_friendly_spell(), living::food, FORCE, living::grace, living::hp, INS_ON_TOP, object::map, MAX_FOOD, living::maxgrace, living::maxhp, living::maxsp, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_HEAL, NDI_UNIQUE, object_insert_in_map_at(), object_present_in_ob_by_name(), do_skill_cb_data::op, PLAYER, poison, PREFER_HIGH, random_roll(), object::skill, living::sp, spell, object::stats, try_find_archetype(), object::type, object::x, and object::y.
Referenced by cast_spell(), and god_intervention().
Here is the call graph for this function:
Here is the caller graph for this function:Identifies objects in the players inventory/on the ground.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| 0 | nothing was identified. |
| 1 | at least one object was identified. |
Definition at line 2505 of file spell_effect.cpp.
References draw_ext_info, draw_ext_info_format(), esrv_update_item(), FOR_INV_FINISH, FOR_INV_PREPARE, FOR_MAP_FINISH, FOR_MAP_PREPARE, identify(), is_identified(), object::map, MAX_BUF, MSG_TYPE_ITEM, MSG_TYPE_ITEM_INFO, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, NDI_UNIQUE, ob_describe(), do_skill_cb_data::op, PLAYER, SP_level_dam_adjust(), spell, spell_effect(), object::type, UPD_FLAGS, UPD_NAME, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Makes the player or character invisible.
Note the spells to 'stack', but perhaps in odd ways. the duration for all is cumulative. In terms of invis undead/normal invis, it is the last one cast that will determine if you are invisible to undead or normal monsters. For improved invis, if you cast it with a one of the others, you lose the improved part of it, and the above statement about undead/ normal applies.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| 0 | invisibility was already in action. |
| 1 | op is now invisible. |
Definition at line 803 of file spell_effect.cpp.
References add_refcount(), object::contr, draw_ext_info, object::duration, FLAG_MAKE_INVIS, FREE_AND_CLEAR_STR, player::hidden, player::invis_race, object::invisible, makes_invisible_to(), MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, NDI_UNIQUE, object_update(), do_skill_cb_data::op, PLAYER, QUERY_FLAG, object::race, SP_level_duration_adjust(), player::tmp_invis, object::type, and UP_OBJ_FACE.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:This alters player's marked item's cursed or blessed status, based on the spell_ob's fields.
| op | player casting the spell. |
| spell_ob | spell itself. |
Definition at line 2454 of file spell_effect.cpp.
References CLEAR_FLAG, draw_ext_info, draw_ext_info_format(), esrv_update_item(), find_marked_object(), FLAG_BLESSED, FLAG_CURSED, FLAG_IDENTIFIED, FLAG_KNOWN_BLESSED, FLAG_KNOWN_CURSED, FLAG_STARTEQUIP, HUGE_BUF, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, name, NDI_UNIQUE, do_skill_cb_data::op, QUERY_FLAG, query_short_name(), SET_FLAG, and UPD_FLAGS.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Illuminates something on a map, or try to blind a living thing.
See the spells documentation file for why this is its own function.
| op | who is casting. |
| caster | what object is casting. |
| spell | spell object to cast. |
| dir | cast direction. |
| 0 | no effect. |
| 1 | lighting successful. |
Definition at line 1136 of file spell_attack.cpp.
References arch_to_object(), do_skill_cb_data::dir, draw_ext_info, FLAG_MONSTER, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, hit_player(), llevError, LOG(), m, object::map, map_find_by_flag(), MAX_LIGHT_RADII, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, NDI_UNIQUE, OB_TYPE_MOVE_BLOCK, object_insert_in_map_at(), do_skill_cb_data::op, P_IS_ALIVE, P_OUT_OF_MAP, SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), spell, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:This is really used mostly for spell fumbles and the like.
| op | what is casting this. |
| tmp | object to propagate. |
| lvl | how nasty should the propagation be. |
Definition at line 49 of file spell_effect.cpp.
References object::count, living::dam, object::duration, object::level, object::map, living::maxhp, object_insert_in_map_at(), do_skill_cb_data::op, object::range, object::stats, object::x, and object::y.
Referenced by alchemy_failure_effect(), become_follower(), god_examines_priest(), pray_at_altar(), prayer_failure(), and scroll_failure().
Here is the call graph for this function:
Here is the caller graph for this function:Polymorph spell casting.
| op | who is casting the spell. |
| caster | object used to cast spell. |
| spell_ob | spell itself. |
| dir | casting direction. 0 won't have any effect. |
Definition at line 425 of file spell_effect.cpp.
References object::above, arch_to_object(), caster_level(), do_skill_cb_data::dir, FLAG_IS_FLOOR, living::food, FOR_OB_AND_BELOW_FINISH, FOR_OB_AND_BELOW_PREPARE, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, GET_MAP_OB, level, m, object::map, MOVE_FLY_LOW, object_insert_in_map_at(), do_skill_cb_data::op, object::other_arch, P_NO_MAGIC, P_OUT_OF_MAP, polymorph(), QUERY_FLAG, object::range, SP_level_range_adjust(), object::speed_left, object::stats, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| int cast_raise_dead_spell | ( | object * | op, |
| object * | caster, | ||
| object * | spell, | ||
| int | dir, | ||
| const char * | arg | ||
| ) |
This handles the raise dead / resurrection spells.
So try to revive a player.
| op | who is doing the resurrecting. |
| caster | what is casting the spell (op or a scroll/rod). |
| spell | spell object. |
| dir | direction the spell is cast. |
| arg | name of the player to revive. |
| 0 | spell had no effect, or player couldn't revive. |
| 1 | player revived, or some nasty things happened. |
Definition at line 181 of file resurrection.cpp.
References arch_to_object(), CALLOC, caster_level(), CORPSE, draw_ext_info, draw_ext_info_format(), find_archetype(), FOR_MAP_FINISH, FOR_MAP_PREPARE, freearr_x, freearr_y, get_map_flags(), object::level, m, object::map, MAX_BUF, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, object::name, NDI_UNIQUE, object_free_drop_inventory(), object_insert_in_map_at(), object_remove(), P_OUT_OF_MAP, resurrect_player(), resurrection_fails(), safe_strncpy, object::slaying, spell, summon_hostile_monsters(), t, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:The priest points to a creature and causes a 'godly curse' to descend.
| op | who is casting. |
| caster | what object is casting. |
| dir | cast direction. |
| spell | spell object to cast. |
| 0 | spell had no effect. |
| 1 | something was affected by the spell. |
Definition at line 546 of file spell_attack.cpp.
References arch_to_object(), AT_DEATH, AT_GODPOWER, AT_HOLYWORD, object::attacktype, caster_level(), living::dam, determine_god(), do_skill_cb_data::dir, draw_ext_info, draw_ext_info_format(), object::duration, find_god(), FLAG_REFL_SPELL, FLAG_UNDEAD, get_pointed_target(), living::hp, HUGE_BUF, object::level, object::map, living::maxhp, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, object::name, NDI_UNIQUE, object_free_drop_inventory(), object_insert_in_map_at(), object_set_owner(), do_skill_cb_data::op, PREFER_LOW, QUERY_FLAG, query_name(), object::race, random_roll(), object::range, set_spell_skill(), SP_EXPLOSION, SP_level_dam_adjust(), SP_level_range_adjust(), spell, SPELL_EFFECT, SPELL_GRACE, SPELL_MANA, object::stats, object::subtype, tailor_god_spell(), object::title, object::type, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Main dispatch when someone casts a spell.
Will decrease mana/gr points, check for skill, confusion and such.
Note that this function is really a dispatch routine that calls other functions - it just blindly returns what ever value those functions return. So if your writing a new function that is called from this, it should also return 1 on success, 0 on failure.
if it is a player casting the spell (op->type == PLAYER, op == caster), this function will decrease the mana/grace appropriately. For other objects, the caller should do what it considers appropriate.
| op | creature that is owner of the object that is casting the spell - eg, the player or monster. |
| caster | actual object (wand, potion) casting the spell. can be same as op. |
| dir | direction to cast in. Note in some cases, if the spell is self only, dir really doesn't make a difference. |
| spell_ob | spell object that is being cast. From that, we can determine what to do. * |
| stringarg | any options that are being used. It can be NULL. Almost certainly, only players will set it. It is basically used as optional parameters to a spell (eg, item to create, information for marking runes, etc. |
Definition at line 1424 of file spell_util.cpp.
References alchemy(), object::anim_suffix, animate_weapon(), apply_anim_suffix(), object::arch, ARCH_SPELL_BLOCKED, ARCH_SPELL_BUNGLE, cast_bless(), cast_cause_disease(), cast_change_ability(), cast_change_map_lightlevel(), cast_cone(), cast_consecrate(), cast_create_food(), cast_create_missile(), cast_create_obj(), cast_create_town_portal(), cast_curse(), cast_destruction(), cast_detection(), cast_earth_to_dust(), cast_heal(), cast_identify(), cast_invisible(), cast_item_curse_or_bless(), cast_light(), cast_polymorph(), cast_raise_dead_spell(), cast_smite_spell(), cast_transfer(), cast_wonder(), cast_word_of_recall(), caster_level(), Settings::casting_time, object::casting_time, change_skill(), object::contr, create_archetype(), create_aura(), create_bomb(), determine_god(), dimension_door(), do_skill_cb_data::dir, dispel_rune(), draw_ext_info, draw_ext_info_format(), draw_magic_map(), player::encumbrance, FABS, find_random_spell_in_ob(), find_skill_by_name(), fire_arch_from_position(), fire_bolt(), fire_swarm(), FIREWALL, FLAG_ALIVE, FLAG_CONFUSED, FLAG_MONSTER, FLAG_WIZ, FLAG_WIZCAST, freearr_x, freearr_y, get_cleric_chance(), get_map_flags(), living::grace, handle_spell_confusion(), object::level, llevError, LOG(), magic_wall(), object::map, MAX, MAX_BUF, living::maxgrace, min_casting_level(), mood_change(), MSG_TYPE_APPLY, MSG_TYPE_APPLY_ERROR, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_MISSING, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_INFO, name, object::name, NDI_UNIQUE, object_get_owner(), do_skill_cb_data::op, P_NO_CLERIC, P_NO_MAGIC, object::path_attuned, object::path_denied, object::path_repelled, PATH_TIME_MULT, perceive_self(), pets_summon_golem(), pets_summon_object(), play_sound_map(), play_sound_player_only(), PLAYER, POTION, prayer_failure(), PREFER_HIGH, PREFER_LOW, probe(), QUERY_FLAG, query_name(), random_roll(), range_golem, range_magic, range_misc, range_none, recharge(), remove_curse(), rndm(), ROD, RUNE, SCROLL, settings, player::shoottype, object::skill, skill, SOUND_TYPE_SPELL, living::sp, SP_ALCHEMY, SP_ANIMATE_WEAPON, SP_AURA, SP_BLESS, SP_BOLT, SP_BOMB, SP_BULLET, SP_CAUSE_DISEASE, SP_CHANGE_ABILITY, SP_CHANGE_MANA, SP_CHANGE_MAP_LIGHT, SP_CHARGING, SP_CONE, SP_CONSECRATE, SP_CREATE_FOOD, SP_CREATE_MISSILE, SP_CURSE, SP_DESTRUCTION, SP_DETECTION, SP_DIMENSION_DOOR, SP_DISPEL_RUNE, SP_EARTH_TO_DUST, SP_ELEM_SHIELD, SP_FAERY_FIRE, SP_HEALING, SP_IDENTIFY, SP_INVISIBLE, SP_ITEM_CURSE_BLESS, SP_level_spellpoint_cost(), SP_LIGHT, SP_MAGIC_MAPPING, SP_MAGIC_MISSILE, SP_MAGIC_WALL, SP_MAKE_MARK, SP_MOOD_CHANGE, SP_MOVING_BALL, SP_PERCEIVE_SELF, SP_POLYMORPH, SP_PROBE, SP_RAISE_DEAD, SP_REMOVE_CURSE, SP_RUNE, SP_SMITE, SP_SUMMON_GOLEM, SP_SUMMON_MONSTER, SP_SWARM, SP_TOWN_PORTAL, SP_WONDER, SP_WORD_OF_RECALL, object::speed, object::speed_left, SPELL, object::spell, spell_consume_items(), spell_effect(), spell_failure(), Settings::spell_failure_effects, SPELL_GRACE, SPELL_MANA, object::spellarg, object::stats, strdup_local, object::subtype, TRUE, object::type, WAND, living::Wis, write_mark(), write_rune(), object::x, and object::y.
Referenced by altar_type_move_on(), cast_dust(), cast_wonder(), cfapi_object_cast(), command_cast_spell(), fire(), fire_misc_object(), monster_cast_spell(), monster_use_range(), move_aura(), move_firewall(), potion_type_apply(), scroll_type_apply(), and spring_trap().
Here is the caller graph for this function:This spell transfers sp from the player to another person.
We let the target go above their normal maximum SP.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
| dir | casting direction. |
| 0 | no transfer happened. |
| 1 | transfer happened. |
Definition at line 2838 of file spell_effect.cpp.
References caster_level(), charge_mana_effect(), do_skill_cb_data::dir, draw_ext_info, FLAG_ALIVE, FOR_MAP_FINISH, FOR_MAP_PREPARE, freearr_x, freearr_y, get_map_flags(), m, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, NDI_BLACK, do_skill_cb_data::op, P_IS_ALIVE, P_OUT_OF_MAP, QUERY_FLAG, living::sp, SP_level_dam_adjust(), spell, object::stats, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:wonder is really just a spell that will likely cast another spell.
| op | who is casting. |
| caster | what is casting. |
| dir | casting direction. |
| spell_ob | actual spell object. |
Definition at line 968 of file spell_effect.cpp.
References cast_cone(), cast_spell(), do_skill_cb_data::dir, generate_treasure(), object::level, llevError, LOG(), object::name, do_skill_cb_data::op, object::randomitems, rndm(), SP_WONDER, SPELL, object::subtype, and object::type.
Referenced by cast_spell(), and scroll_failure().
Here is the call graph for this function:
Here is the caller graph for this function:Word of recall causes the player to return 'home'.
we put a force into the player object, so that there is a time delay effect.
| op | who is casting. |
| caster | what is casting. |
| spell_ob | actual spell object. |
| 0 | op isn't a player. |
| 1 | word of recall initiated. |
Definition at line 906 of file spell_effect.cpp.
References add_string(), player::bed_x, player::bed_y, object::contr, create_archetype(), draw_ext_info, object::duration, EXIT_PATH, EXIT_X, EXIT_Y, FORCE_NAME, llevError, LOG(), MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_SUCCESS, NDI_UNIQUE, object_find_by_type_subtype(), object_insert_in_ob(), object_update_speed(), do_skill_cb_data::op, PLAYER, player::savebed_map, SP_level_duration_adjust(), SP_WORD_OF_RECALL, object::speed, object::speed_left, SPELL_EFFECT, object::subtype, time, and object::type.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:This function returns the effective level the spell is being cast at.
Note that I changed the repelled/attuned bonus to 2 from 5. This is because the new code compares casting_level against min_caster_level, so the difference is effectively 4
| caster | person casting the spell. |
| spell | spell object. |
Definition at line 194 of file spell_util.cpp.
References find_applied_skill_by_name(), object::level, level, object::path_attuned, object::path_repelled, PLAYER, skill, spell, and object::type.
Referenced by animate_weapon(), cast_cause_disease(), cast_cone(), cast_consecrate(), cast_create_town_portal(), cast_detection(), cast_polymorph(), cast_raise_dead_spell(), cast_smite_spell(), cast_spell(), cast_transfer(), charge_mana_effect(), create_aura(), fire_arch_from_position(), fire_swarm(), magic_wall(), mood_change(), pets_summon_golem(), pets_summon_object(), remove_curse(), SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), SP_level_spellpoint_cost(), SP_level_wc_adjust(), and write_rune().
Here is the call graph for this function:
Here is the caller graph for this function:| int cftimer_create | ( | int | id, |
| long | delay, | ||
| object * | ob, | ||
| int | mode | ||
| ) |
Creates a new timer.
| id | desired timer identifier. |
| delay | desired timer delay. |
| ob | object that will be linked to this timer. Should have an EVENT_TIMER handler. |
| mode | unit for delay, should be TIMER_MODE_SECONDS or TIMER_MODE_CYCLES. See timers.h. |
| TIMER_ERR_NONE | timer was successfully created. |
| TIMER_ERR_ID | invalid ID. |
| TIMER_ERR_MODE | invalid mode. |
| TIMER_ERR_OBJ | ob is NULL or has no EVENT_TIMER handler. |
Definition at line 97 of file timers.cpp.
References object::count, cftimer::delay, EVENT_CONNECTOR, EVENT_TIMER, MAX_TIMERS, cftimer::mode, cftimer::ob_tag, object_find_by_type_subtype(), seconds(), TIMER_ERR_ID, TIMER_ERR_MODE, TIMER_ERR_NONE, TIMER_ERR_OBJ, TIMER_MODE_CYCLES, TIMER_MODE_DEAD, TIMER_MODE_SECONDS, and timers_table.
Referenced by cfapi_timer_create().
Here is the call graph for this function:
Here is the caller graph for this function:| int cftimer_destroy | ( | int | id | ) |
Destroys an existing timer.
| id | identifier of the timer to destroy. |
| TIMER_ERR_NONE | no problem encountered. |
| TIMER_ERR_ID | unknown id - timer not found or invalid. |
Definition at line 128 of file timers.cpp.
References MAX_TIMERS, cftimer::mode, TIMER_ERR_ID, TIMER_ERR_NONE, TIMER_MODE_DEAD, and timers_table.
Referenced by cfapi_timer_destroy().
Here is the caller graph for this function:| int cftimer_find_free_id | ( | void | ) |
Finds a free ID for a new timer.
| TIMER_ERR_ID | no free ID available. |
| >=0 | an available ID. |
Definition at line 144 of file timers.cpp.
References MAX_TIMERS, TIMER_ERR_ID, TIMER_MODE_DEAD, and timers_table.
Referenced by cfapi_timer_create().
Here is the caller graph for this function:| void cftimer_init | ( | void | ) |
Initialize timers.
Definition at line 157 of file timers.cpp.
References MAX_TIMERS, and timers_table.
Referenced by init().
Here is the caller graph for this function:| void cftimer_process_timers | ( | void | ) |
Processes all timers.
Definition at line 44 of file timers.cpp.
References cftimer_process_event(), cftimer::delay, MAX_TIMERS, cftimer::mode, seconds(), TIMER_MODE_CYCLES, TIMER_MODE_DEAD, TIMER_MODE_SECONDS, and timers_table.
Referenced by server_main().
Here is the call graph for this function:
Here is the caller graph for this function:| void change_object | ( | object * | op | ) |
Replaces op with its other_arch if it has reached its end of life.
This routine doesnt seem to work for "inanimate" objects that are being carried, ie a held torch leaps from your hands!. Modified this routine to allow held objects. b.t.
| op | object to change. Will be removed and replaced. |
Definition at line 592 of file time.cpp.
References add_friendly_object(), object::arch, arch_to_object(), object::attack_movement, archetype::clone, object::env, env, FLAG_ALIVE, FLAG_FRIENDLY, FLAG_UNAGGRESSIVE, living::food, friendly, living::hp, INS_ABOVE_FLOOR_ONLY, INS_NO_MERGE, INS_NO_WALK_ON, LAMP, llevError, llevInfo, LOG(), object::map, archetype::more, object::name, object_find_multi_free_spot_around(), object_fix_multipart(), object_free_drop_inventory(), object_get_owner(), object_insert_in_map(), object_insert_in_ob(), object_insert_to_free_spot_or_free(), object_remove(), object_set_owner(), object::other_arch, PETMOVE, QUERY_FLAG, remove_friendly_object(), SET_FLAG, SIZEOFFREE1, object::stats, object::type, object::x, and object::y.
Referenced by hit_player(), and process_object().
Here is the call graph for this function:
Here is the caller graph for this function:This changes the object's skill to new_skill.
Note that this function doesn't always need to get used - you can now add skill exp to the player without the chosen_skill being set. This function is of most interest to players to update the various range information.
| who | living to change skill for. |
| new_skill | skill to use. If NULL, this just unapplies the current skill. |
| flag | has the current meaning:
|
| 0 | change failure. |
| 1 | success |
Definition at line 357 of file skill_util.cpp.
References AP_APPLY, AP_NOPRINT, AP_UNAPPLY, apply_special(), object::chosen_skill, object::contr, PLAYER, range_skill, player::shoottype, object::skill, and object::type.
Referenced by apply_special(), cast_destruction(), cast_spell(), command_rskill(), do_skill_attack(), and fire_bow().
Here is the call graph for this function:
Here is the caller graph for this function:| void check_active_maps | ( | void | ) |
Finds maps in memory to swap.
Definition at line 201 of file swap.cpp.
References first_map, mapstruct::in_memory, MAP_IN_MEMORY, mapstruct::next, swap_map(), and mapstruct::timeout.
Referenced by server_main().
Here is the call graph for this function:
Here is the caller graph for this function:| void check_bullet | ( | object * | op | ) |
Checks to see what op should do, given the space it is on (eg, explode, damage player, etc).
| op | object to check. |
Definition at line 217 of file spell_attack.cpp.
References object::attacktype, object::count, living::dam, explode_bullet(), FLAG_ALIVE, FLAG_REMOVED, FOR_MAP_FINISH, FOR_MAP_PREPARE, get_map_flags(), GET_MAP_MOVE_BLOCK, hit_player(), m, object::map, OB_TYPE_MOVE_BLOCK, object_free_drop_inventory(), object_remove(), object_was_destroyed, do_skill_cb_data::op, object::other_arch, P_IS_ALIVE, QUERY_FLAG, object::stats, object::x, and object::y.
Referenced by fire_arch_from_position(), and move_bullet().
Here is the call graph for this function:
Here is the caller graph for this function:| void check_login | ( | object * | op, |
| const char * | password | ||
| ) |
Actually login a player, load from disk and such.
| op | player. |
| password | if not NULL, the uncrypted password the user entered. If NULL, no password check is done, coming from the account code which already does authentication. |
Definition at line 522 of file login.cpp.
References add_string(), object::arch, player::bed_x, player::bed_y, player::bowtype, buf, object::carrying, living::Cha, check_password(), check_path(), CLEAR_FLAG, archetype::clone, living::Con, confirm_password(), containers, object::contr, living::Dex, player::digestion, draw_ext_info, draw_ext_info_format(), enter_player_maplevel(), esrv_add_spells(), esrv_new_player(), esrv_send_inventory(), esrv_send_pickup(), EVENT_LOGIN, events_execute_global_event(), final_free_player(), first_map_path, first_player, fix_object(), FLAG_FRIENDLY, FLAG_NO_FIX_PLAYER, FLAG_REMOVED, FLAG_USE_ARMOUR, FLAG_USE_SHIELD, FORCE, player::gen_grace, player::gen_hp, player::gen_sp, has_been_loaded(), player::has_directory, socket_struct::host, living::hp, i18n_get_language_by_code(), if(), living::Int, object::inv, is_dragon_pl(), player::is_old_wraith, player::is_wraith, key_inventory, keyrings, kill_player(), knowledge_send_known(), player::language, leave(), legal_range(), player::levgrace, player::levhp, player::levsp, link_player_skills(), player::listening, llevDebug, llevError, llevInfo, LO_NEWFILE, load_object(), Settings::localdir, LOG(), login_check_shutdown(), player::maplevel, MAX_BUF, player::mode, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_LOGIN, MSG_TYPE_ADMIN_PLAYER, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_SUCCESS, object::name, player::name_changed, NDI_ALL, NDI_DK_ORANGE, NDI_UNIQUE, player::next, player::no_shout, Ns_Dead, player::ob, object_find_by_name(), object_find_by_type_and_arch_name(), object_remove(), object_reset(), object_sum_weight(), object_update_speed(), player::orig_stats, player::partial_commands, player::party, party_confirm_password(), party_find(), party_form(), party_join(), party_rejoin_always, party_rejoin_no, party_set_password(), partylist::partyname, player::password, player::peaceful, player::petmode, PLAYER, player_set_own_title(), player_set_state(), Settings::playerdir, living::Pow, PROFILE_BEGIN, PROFILE_END, pticks, QUERY_FLAG, quest_send_initial_states(), range_none, player::rejoin_party, remove_unpaid_objects(), Settings::reset_loc_time, save_player(), player::savebed_map, Settings::search_items, player::search_str, set_dragon_name(), SET_FLAG, Settings::set_title, settings, player::shoottype, player::socket, object::speed, player::spellparam, ST_PLAYING, player::state, object::stats, living::Str, strdup_local, strlcpy(), player::ticks_played, time, player::title, TRUE, object::type, player::unapply, unapply_always, unapply_never, unapply_nochoice, player::unarmed_skill, socket_struct::update_look, player::usekeys, object::weight, living::Wis, wrong_password(), object::x, and object::y.
Referenced by account_play_cmd(), and receive_player_password().
Here is the call graph for this function:
Here is the caller graph for this function:| int check_name | ( | player * | me, |
| const char * | name | ||
| ) |
Ensure player's name is valid.
| me | player to report to. |
| name | name to check. |
| 0 | invalid name. |
| 1 | valid name. |
Definition at line 181 of file login.cpp.
References draw_ext_info, draw_ext_info_format(), MAX_NAME, me, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_LOGIN, name, NDI_UNIQUE, player::ob, and playername_ok().
Referenced by receive_player_name().
Here is the call graph for this function:
Here is the caller graph for this function:| bool check_password | ( | const char * | typed, |
| const char * | crypted | ||
| ) |
Hash a password and compare it to the stored version.
| typed | Password entered by the user (not hashed). |
| crypted | Stored password to check against (hashed). |
Definition at line 114 of file server.cpp.
References crypt_string(), llevError, and LOG().
Referenced by account_change_password(), account_login(), check_login(), receive_player_password(), and verify_player().
Here is the call graph for this function:
Here is the caller graph for this function:Possibly infect due to direct physical contact i.e., AT_PHYSICAL.
| victim | potential victim. |
| hitter | who is hitting. |
Definition at line 663 of file disease.cpp.
References DISEASE, FOR_INV_FINISH, FOR_INV_PREPARE, and infect_object().
Referenced by hit_with_one_attacktype().
Here is the call graph for this function:
Here is the caller graph for this function:| int check_pick | ( | object * | op | ) |
Sees if there is stuff to be picked up/picks up stuff, for players only.
| op | player to check for. |
| 1 | player should keep on moving. |
| 0 | player should stop. |
Definition at line 1732 of file player.cpp.
References object::contr, object::count, draw_ext_info, draw_ext_info_format(), FLAG_KNOWN_CURSED, FLAG_KNOWN_MAGICAL, FLAG_UNPAID, FOR_BELOW_FINISH, FOR_BELOW_PREPARE, is_valid_types_gen::found, GEM, m, MAX, player::mode, MONEY, MOVE_FLYING, object::move_type, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DEBUG, MSG_TYPE_COMMAND_SUCCESS, NDI_UNIQUE, object_can_pick(), object_matches_pickup_mode(), object_matches_string(), object_was_destroyed, pick_up(), price_base(), PU_ARMOUR, PU_ARROW, PU_BOOTS, PU_BOW, PU_CLOAK, PU_CONTAINER, PU_CURSED, PU_DEBUG, PU_DRINK, PU_FLESH, PU_FOOD, PU_GLOVES, PU_HELMET, PU_INHIBIT, PU_JEWELS, PU_KEY, PU_MAGIC_DEVICE, PU_MAGICAL, PU_MELEEWEAPON, PU_MISSILEWEAPON, PU_NEWMODE, PU_NOT_CURSED, PU_NOTHING, PU_POTION, PU_RATIO, PU_READABLES, PU_SHIELD, PU_SKILLSCROLL, PU_SPELLBOOK, PU_STOP, PU_VALUABLES, QUERY_FLAG, Settings::search_items, player::search_str, settings, and TRUE.
Referenced by move_player(), and stop_jump().
Here is the call graph for this function:
Here is the caller graph for this function:This checks to see if the race and class are legal.
Legal in this contexts means that after apply the race/class stat modifiers, the race is still in legal range.
| stats | The statistics to modify - this data is modified, so the caller can use it on the next update. |
| race | The race to try and apply. It can be NULL, in which case no race will be applied. |
| opclass | The class to apply. It can be NULL, in which case no class will be applied. |
Definition at line 1436 of file player.cpp.
References archetype::clone, get_attr_value(), Settings::max_stat, MIN_STAT, NUM_STATS, set_attr_value(), settings, stats, and object::stats.
Referenced by create_player_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| void check_spell_expiry | ( | object * | spell | ) |
Checks if player should be warned of soon expiring spell.
Should be called at each move of the spell. Will use key stored by store_spell_expiry(). If the spell effect/force isn't in a player's inventory, won't do anything.
| spell | force or spell whose effects will expire. |
Definition at line 2006 of file spell_util.cpp.
References draw_ext_info_format(), IS_PLAYER(), MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_PROTECTION_GAIN, NDI_NAVY, NDI_UNIQUE, object_get_value(), and spell.
Referenced by move_aura(), and remove_force().
Here is the call graph for this function:
Here is the caller graph for this function:Checks to see if player knows the spell.
If the name is the same as an existing spell, we presume they know it.
| op | object we're looking into. |
| name | spell name. Doesn't need to be a shared string. |
Definition at line 394 of file spell_util.cpp.
References name, object_find_by_type_and_name(), do_skill_cb_data::op, and SPELL.
Referenced by cfapi_object_check_spell(), command_learn_spell_or_prayer(), do_forget_spell(), do_learn_spell(), dragon_ability_gain(), god_intervention(), and spellbook_type_apply().
Here is the call graph for this function:
Here is the caller graph for this function:| int checkbanned | ( | const char * | login, |
| const char * | host | ||
| ) |
Check if a player and/or host is banned.
Wildcards can be used.
| login | player name to check; NULL to check only the host name. |
| host | host name to check. |
Definition at line 32 of file ban.cpp.
References BANFILE, BANISHFILE, buf, Settings::confdir, llevDebug, Settings::localdir, LOG(), MAX_BUF, and settings.
Referenced by new_connection(), and receive_player_password().
Here is the call graph for this function:
Here is the caller graph for this function:| void clean_tmp_files | ( | void | ) |
Save unique maps and clean up temporary map files unless recycling temporary maps.
The function name is somewhat misleading.
Definition at line 351 of file main.cpp.
References clean_tmp_map(), first_map, m, MAP_IN_MEMORY, Settings::recycle_tmp_maps, save_map(), SAVE_MODE_NORMAL, settings, swap_map(), and write_todclock().
Referenced by cleanup(), fatal(), and LOG().
Here is the call graph for this function:
Here is the caller graph for this function:| void cleanup | ( | void | ) |
Clean up everything and exit.
Definition at line 1262 of file server.cpp.
References accounts_save(), clean_tmp_files(), cleanupPlugins(), close_modules(), commands_clear(), free_all_artifacts(), free_all_god(), free_all_maps(), free_all_newserver(), free_all_readable(), free_all_recipes(), free_globals(), free_knowledge(), free_loader(), free_quest(), free_quest_definitions(), free_server(), free_style_maps(), i18n_free(), llevInfo, LOG(), metaserver2_exit(), object_free_all_data(), and write_book_archive().
Referenced by do_shutdown(), init_beforeplay(), make_doors(), parse_args(), server_dump_animations(), server_dump_bonuses(), and server_dump_faces().
Here is the call graph for this function:
Here is the caller graph for this function:| void cleanupPlugins | ( | void | ) |
Call the crossfire_plugin::closefunc on the various plugins, used at server shutdown.
Will not unload plugins. Free all items of plugins_list.
Definition at line 4639 of file plugins.cpp.
References plugins_list.
Referenced by cleanup().
Here is the caller graph for this function:| void clear_skill | ( | object * | who | ) |
This function just clears the chosen_skill and range_skill values in the player.
| who | living to clear. |
Definition at line 396 of file skill_util.cpp.
References object::chosen_skill, CLEAR_FLAG, object::contr, FLAG_READY_SKILL, PLAYER, range_none, range_skill, player::ranges, player::shoottype, and object::type.
Referenced by unapply_special().
Here is the caller graph for this function:| void close_modules | ( | ) |
Clean up all modules which are not disabled.
Definition at line 83 of file init.cpp.
References module_information::close, module_information::description, module_information::enabled, llevInfo, LOG(), modules, and module_information::name.
Referenced by cleanup().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_abil | ( | object * | op, |
| const char * | params | ||
| ) |
Changes an object's statistics.
| op | wizard. |
| params | parameters, should be "player statistic new_value". |
Definition at line 1819 of file c_wiz.cpp.
References living::Cha, living::Con, living::Dex, draw_ext_info, draw_ext_info_format(), FALSE, first_player, fix_object(), FLAG_WAS_WIZ, living::Int, Settings::max_stat, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::next, player::ob, player::orig_stats, living::Pow, Settings::real_wiz, SET_FLAG, settings, object::stats, living::Str, and living::Wis.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_accountpasswd | ( | object * | op, |
| const char * | params | ||
| ) |
Definition at line 1638 of file c_wiz.cpp.
References account_change_password(), draw_ext_info, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_accuse | ( | object * | op, |
| const char * | params | ||
| ) |
'accuse' command.
| op | player. |
| params | message. |
Definition at line 909 of file c_chat.cpp.
References basic_emote(), and EMOTE_ACCUSE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_addexp | ( | object * | op, |
| const char * | params | ||
| ) |
This adds exp to a player.
We now allow adding to a specific skill.
| op | wizard. |
| params | should be "player quantity [skill]". |
Definition at line 1676 of file c_wiz.cpp.
References buf, calc_perm_exp(), check_exp_adjust(), draw_ext_info, draw_ext_info_format(), living::exp, FALSE, find_skill_by_name(), first_player, FLAG_WAS_WIZ, MAX_BUF, MAX_NAME, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::next, player::ob, player_lvl_adj(), Settings::real_wiz, SET_FLAG, settings, skill, and object::stats.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_afk | ( | object * | op, |
| const char * | params | ||
| ) |
Toggles the afk status of a player.
'afk' command.
| op | player to toggle status for. |
| params | unused. |
Definition at line 775 of file c_misc.cpp.
References CLEAR_FLAG, draw_ext_info, FLAG_AFK, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, QUERY_FLAG, and SET_FLAG.
Referenced by commands_init().
Here is the caller graph for this function:| void command_apply | ( | object * | op, |
| const char * | params | ||
| ) |
'apply' command.
| op | player. |
| params | what to apply. |
Definition at line 251 of file c_object.cpp.
References object::above, AP_APPLY, AP_NULL, AP_OPEN, AP_UNAPPLY, apply_by_living(), apply_by_living_below(), object::container, draw_ext_info_format(), find_best_apply_object_match(), object::inv, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_applymode | ( | object * | op, |
| const char * | params | ||
| ) |
Players wants to change the apply mode, ie how to handle applying an item when no body slot available.
| op | player asking for change. |
| params | new mode. |
Definition at line 1277 of file c_misc.cpp.
References object::contr, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, types, player::unapply, unapply_always, unapply_never, and unapply_nochoice.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_archs | ( | object * | op, |
| const char * | params | ||
| ) |
| void command_arrest | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard jails player.
| op | wizard. |
| params | player to jail. |
Definition at line 821 of file c_wiz.cpp.
References draw_ext_info, draw_ext_info_format(), get_other_player_from_name(), llevInfo, LOG(), MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::ob, and player_arrest().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_banish | ( | object * | op, |
| const char * | params | ||
| ) |
Add player's IP to ban_file and kick them off the server.
I know most people have dynamic IPs but this is more of a short term solution if they have to get a new IP to play maybe they'll calm down. This uses the banish_file in the local directory *not *the ban_file The action is logged with a ! for easy searching. -tm
| op | DM banishing. |
| params | player to banish. Must be a complete name match. |
Definition at line 502 of file c_wiz.cpp.
References BANISHFILE, buf, command_kick2(), draw_ext_info, draw_ext_info_format(), get_other_player_from_name(), socket_struct::host, llevDebug, Settings::localdir, LOG(), MAX_BUF, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_ALL, NDI_RED, NDI_UNIQUE, player::ob, settings, player::socket, and time.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_beg | ( | object * | op, |
| const char * | params | ||
| ) |
'beg' command.
| op | player. |
| params | message. |
Definition at line 1272 of file c_chat.cpp.
References basic_emote(), and EMOTE_BEG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_bleed | ( | object * | op, |
| const char * | params | ||
| ) |
'bleed' command.
| op | player. |
| params | message. |
Definition at line 1283 of file c_chat.cpp.
References basic_emote(), and EMOTE_BLEED.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_blush | ( | object * | op, |
| const char * | params | ||
| ) |
'blush' command.
| op | player. |
| params | message. |
Definition at line 953 of file c_chat.cpp.
References basic_emote(), and EMOTE_BLUSH.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_body | ( | object * | op, |
| const char * | params | ||
| ) |
This command dumps the body information for object *op.
it doesn't care what the params are.
This is mostly meant as a debug command.
This is the 'body' command.
| op | player to display body info for. |
| params | unused |
Definition at line 173 of file c_misc.cpp.
References object::body_info, body_locations, object::body_used, draw_ext_info, draw_ext_info_format(), FLAG_USE_ARMOUR, FLAG_USE_WEAPON, i18n(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_BODY, NDI_UNIQUE, NUM_BODY_LOCATIONS, and QUERY_FLAG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_bounce | ( | object * | op, |
| const char * | params | ||
| ) |
'bounce' command.
| op | player. |
| params | message. |
Definition at line 755 of file c_chat.cpp.
References basic_emote(), and EMOTE_BOUNCE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_bow | ( | object * | op, |
| const char * | params | ||
| ) |
'bow' command.
| op | player. |
| params | message. |
Definition at line 931 of file c_chat.cpp.
References basic_emote(), and EMOTE_BOW.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_bowmode | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change the bowmode, how arrows are fired.
| op | player asking for change. |
| params | new mode. |
Definition at line 1318 of file c_misc.cpp.
References bow_bestarrow, bow_nw, player::bowtype, buf, object::contr, draw_ext_info, draw_ext_info_format(), is_valid_types_gen::found, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_finish(), stringbuffer_new(), and types.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_brace | ( | object * | op, |
| const char * | params | ||
| ) |
Player toggles her braced status.
| op | player. |
| params | brace status (on/off). |
Definition at line 2172 of file c_misc.cpp.
References player::braced, object::contr, draw_ext_info, fix_object(), MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, and onoff_value().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_burp | ( | object * | op, |
| const char * | params | ||
| ) |
'burp' command.
| op | player. |
| params | message. |
Definition at line 964 of file c_chat.cpp.
References basic_emote(), and EMOTE_BURP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cackle | ( | object * | op, |
| const char * | params | ||
| ) |
'cackle' command.
| op | player. |
| params | message. |
Definition at line 777 of file c_chat.cpp.
References basic_emote(), and EMOTE_CACKLE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cast | ( | object * | op, |
| const char * | params | ||
| ) |
'cast' command, prepares a spell for laster casting.
| op | player. |
| params | spell. |
Definition at line 50 of file c_range.cpp.
References command_cast_spell().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cast_spell | ( | object * | op, |
| const char * | params, | ||
| int | cast_now | ||
| ) |
Sets up to cast a spell.
Invoke casts a spell immediately, whereas cast just set up the range type.
| op | caster. |
| params | spell name. |
| cast_now | 0 to ready the spell, 1 to cast it immediately |
Definition at line 146 of file c_range.cpp.
References cast_spell(), object::contr, object::count, draw_ext_info_format(), object::facing, find_skill_by_name(), player::golem_count, lookup_spell_by_name(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_SUCCESS, MSG_TYPE_SKILL, MSG_TYPE_SKILL_MISSING, object::name, NDI_UNIQUE, object_find_by_tag(), object_free_drop_inventory(), object_get_value(), object_remove(), range_golem, range_magic, player::ranges, remove_friendly_object(), safe_strncpy, player::shoottype, show_matching_spells(), object::skill, SPELL, object::spell, player::spellparam, sstring, and object::type.
Referenced by command_cast(), and command_invoke().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_chat | ( | object * | op, |
| const char * | params | ||
| ) |
'chat' command.
| op | player. |
| params | message. |
Definition at line 221 of file c_chat.cpp.
References command_tell_all(), MSG_TYPE_COMMUNICATION_CHAT, and NDI_BLUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_chuckle | ( | object * | op, |
| const char * | params | ||
| ) |
'chuckle' command.
| op | player. |
| params | message. |
Definition at line 975 of file c_chat.cpp.
References basic_emote(), and EMOTE_CHUCKLE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_clap | ( | object * | op, |
| const char * | params | ||
| ) |
'clap' command.
| op | player. |
| params | message. |
Definition at line 942 of file c_chat.cpp.
References basic_emote(), and EMOTE_CLAP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cointoss | ( | object * | op, |
| const char * | params | ||
| ) |
'cointoss' command.
| op | player. |
| params | message. |
Definition at line 64 of file c_chat.cpp.
References buf, draw_ext_info_format(), ext_info_map_except(), object::map, MAX_BUF, MSG_TYPE_COMMUNICATION, MSG_TYPE_COMMUNICATION_RANDOM, object::name, NDI_UNIQUE, NDI_WHITE, and rndm().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cough | ( | object * | op, |
| const char * | params | ||
| ) |
'cough' command.
| op | player. |
| params | message. |
Definition at line 986 of file c_chat.cpp.
References basic_emote(), and EMOTE_COUGH.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_create | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard wants to create an object.
This function is a real mess, because we're stucking getting the entire item description in one block of text, so we just can't simply parse it - we need to look for double quotes for example. This could actually get much simpler with just a little help from the client - if we could get line breaks, it makes parsing much easier, eg, something like:
which is much easier to parse than dragon name "big nasty creature" hp 5 sp 30 for example.
| op | wizard. |
| params | object description. |
Definition at line 999 of file c_wiz.cpp.
References object::arch, arch_to_object(), archetype::clone, object::contr, player::count, object::count, create_treasure(), mapstruct::difficulty, dm_stack_pop(), dm_stack_push(), draw_ext_info, draw_ext_info_format(), FALSE, find_archetype_by_object_name(), find_artifactlist(), FLAG_ALIVE, FLAG_IDENTIFIED, FLAG_MONSTER, FLAG_WAS_WIZ, FREE_OBJ_NO_DESTROY_CALLBACK, give_artifact_abilities(), is_identifiable_type(), artifact::item, artifactlist::items, llevDebug, LOG(), object::map, MAX, MAX_BUF, monster_check_apply_all(), object::more, archetype::more, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, object::nrof, object_copy(), object_create_arch(), object_free(), object_give_identified_properties(), object_insert_in_map_at(), object_insert_in_ob(), object::other_arch, out_of_map(), POTION, QUERY_FLAG, object::randomitems, Settings::real_wiz, ROD, safe_strncpy, SCROLL, set_abs_magic(), SET_FLAG, set_magic(), set_variable(), settings, SPELL, SPELLBOOK, try_find_archetype(), object::type, WAND, object::x, and object::y.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cringe | ( | object * | op, |
| const char * | params | ||
| ) |
'cringe' command.
| op | player. |
| params | message. |
Definition at line 1294 of file c_chat.cpp.
References basic_emote(), and EMOTE_CRINGE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_cry | ( | object * | op, |
| const char * | params | ||
| ) |
'cry' command.
| op | player. |
| params | message. |
Definition at line 887 of file c_chat.cpp.
References basic_emote(), and EMOTE_CRY.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dance | ( | object * | op, |
| const char * | params | ||
| ) |
'dance' command.
| op | player. |
| params | message. |
Definition at line 733 of file c_chat.cpp.
References basic_emote(), and EMOTE_DANCE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_debug | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to see/change the debug level.
| op | player asking for information. |
| params | new debug value. |
Definition at line 893 of file c_misc.cpp.
References Settings::debug, draw_ext_info_format(), FABS, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, and settings.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_delete | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to totally delete her character.
| op | player wanting to delete her character. |
| params | unused. |
Definition at line 1889 of file c_misc.cpp.
References object::contr, CS_QUERY_SINGLECHAR, draw_ext_info, FLAG_WIZ, i18n(), MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, NDI_UNIQUE, player_set_state(), QUERY_FLAG, send_query(), player::socket, and ST_CONFIRM_QUIT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_diff | ( | object * | op, |
| const char * | params | ||
| ) |
Get a diff of specified items.
Second item is compared to first, and differences displayed.
Ryo, august 2004
| op | wizard. |
| params | object specifier. |
Definition at line 2622 of file c_wiz.cpp.
References object::contr, dm_stack_pop(), draw_ext_info, get_dm_object(), get_ob_diff(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, object_find_by_tag_global(), STACK_FROM_NUMBER, STACK_FROM_TOP, player::stack_items, player::stack_position, stringbuffer_finish(), and stringbuffer_new().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_disarm | ( | object * | op, |
| const char * | params | ||
| ) |
'disarm' command.
| op | player. |
| params | unused. |
Definition at line 224 of file c_object.cpp.
References do_skill_by_number(), and SK_DISARM_TRAPS.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dm | ( | object * | op, |
| const char * | params | ||
| ) |
Actual command to perhaps become dm.
Changed around a bit in version 0.92.2 to allow people on sockets to become dm, and allow better dm file
| op | player wishing to become wizard. |
| params | password. |
Definition at line 2214 of file c_wiz.cpp.
References do_wizard_dm().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dmhide | ( | object * | op, |
| const char * | params | ||
| ) |
A players wants to become DM and hide.
Let's see if that's authorized. Make sure to not tell anything to anyone.
| op | wizard. |
| params | password. |
Definition at line 2519 of file c_wiz.cpp.
References do_wizard_dm(), and do_wizard_hide().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dmtell | ( | object * | op, |
| const char * | params | ||
| ) |
Private communication, by a DM (can't be ignored by player).
| op | player trying to tell something to someone. |
| params | who to tell, and message. |
Definition at line 320 of file c_chat.cpp.
References do_tell().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_drop | ( | object * | op, |
| const char * | params | ||
| ) |
'drop' command.
| op | player. |
| params | what to drop. |
Definition at line 1306 of file c_object.cpp.
References CLEAR_FLAG, object::contr, player::count, draw_ext_info, draw_ext_info_format(), drop(), esrv_update_item(), fix_object(), FLAG_INV_LOCKED, FLAG_NO_DROP, FLAG_NO_FIX_PLAYER, FOR_INV_FINISH, FOR_INV_PREPARE, make_matcher(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, PLAYER, QUERY_FLAG, SET_FLAG, object::type, and UPD_WEIGHT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dropall | ( | object * | op, |
| const char * | params | ||
| ) |
Command to drop all items that have not been locked.
| op | player. |
| params | optional specifier, like 'armour', 'weapon' and such. |
Definition at line 1182 of file c_object.cpp.
References AMULET, ARMOUR, ARMOUR_IMPROVER, ARROW, BOOK, BOOTS, BOW, BRACERS, CLEAR_FLAG, CLOAK, CONTAINER, object::container, object::contr, player::count, draw_ext_info, DRINK, drop(), esrv_update_item(), fix_object(), FLAG_APPLIED, FLAG_INV_LOCKED, FLAG_NO_FIX_PLAYER, FLESH, FOOD, FOR_INV_FINISH, FOR_INV_PREPARE, GEM, GIRDLE, GLOVES, HELMET, object::inv, KEY, MONEY, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, PLAYER, POTION, QUERY_FLAG, RING, ROD, SCROLL, SET_FLAG, SHIELD, player::socket, SPECIAL_KEY, SPELLBOOK, object::type, UPD_WEIGHT, socket_struct::update_look, WAND, WEAPON, and WEAPON_IMPROVER.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dump | ( | object * | op, |
| const char * | params | ||
| ) |
Dumps the difference between an object and its archetype.
| op | wiard. |
| params | object to dump. |
Definition at line 1377 of file c_wiz.cpp.
References object::contr, draw_ext_info, FLAG_OBJ_ORIGINAL, get_dm_object(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, object_dump(), QUERY_FLAG, stringbuffer_finish(), and stringbuffer_new().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpabove | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to dump object above her.
| op | player asking for information. |
| params | unused. |
Definition at line 2902 of file c_wiz.cpp.
References object::above, and do_dump().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpallarchetypes | ( | object * | op, |
| const char * | params | ||
| ) |
Various archetypes-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 1005 of file c_misc.cpp.
References dump_all_archetypes().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpallmaps | ( | object * | op, |
| const char * | params | ||
| ) |
Various map-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 1047 of file c_misc.cpp.
References dump_all_maps().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpallobjects | ( | object * | op, |
| const char * | params | ||
| ) |
Various object-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 977 of file c_misc.cpp.
References object_dump_all().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpbelow | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to dump object below her.
| op | player asking for information. |
| params | unused. |
Definition at line 2887 of file c_wiz.cpp.
References object::below, and do_dump().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpfriendlyobjects | ( | object * | op, |
| const char * | params | ||
| ) |
Various friendly object-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 991 of file c_misc.cpp.
References dump_friendly_objects().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_dumpmap | ( | object * | op, |
| const char * | params | ||
| ) |
Various map-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 1033 of file c_misc.cpp.
References dump_map(), and object::map.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_east | ( | object * | op, |
| const char * | params | ||
| ) |
'east' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 57 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_empty | ( | object * | op, |
| const char * | params | ||
| ) |
'empty' command.
| op | player. |
| params | item specifier. |
Definition at line 1402 of file c_object.cpp.
References CONTAINER, draw_ext_info, empty_container(), find_best_object_match(), FOR_INV_FINISH, FOR_INV_PREPARE, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, and object::type.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_examine | ( | object * | op, |
| const char * | params | ||
| ) |
'examine' command.
| op | player. |
| params | optional item specifier. |
Definition at line 1441 of file c_object.cpp.
References draw_ext_info_format(), examine(), find_best_object_match(), FOR_BELOW_FINISH, FOR_BELOW_PREPARE, LOOK_OBJ, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_execute | ( | object * | pl, |
| char * | command | ||
| ) |
Handle a player-issued command.
| pl | player who is issuing the command |
| command | the actual command with its arguments. Will be modified in-place. |
Definition at line 456 of file commands.cpp.
References command, command_find(), object::contr, registered_command::extra, registered_command::func_extra, registered_command::func_std, player::has_hit, llevDebug, LOG(), object::speed_left, registered_command::time, and tolower.
Referenced by new_player_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_face | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to face a given direction.
| op | player. |
| params | additional parameters. |
Definition at line 111 of file c_new.cpp.
References draw_ext_info, draw_ext_info_format(), face_player(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_fire | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to start firing.
| op | player. |
| params | additional parameters. |
Definition at line 77 of file c_new.cpp.
References object::contr, draw_ext_info, player::fire_on, move_player(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_fire_stop | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to stop firing.
| op | player. |
| params | ignored. |
Definition at line 98 of file c_new.cpp.
References object::contr, and player::fire_on.
Referenced by commands_init().
Here is the caller graph for this function:| void command_fix_me | ( | object * | op, |
| const char * | params | ||
| ) |
Wrapper to fix a player.
| op | player asking to be fixed. |
| params | unused. |
Definition at line 1213 of file c_misc.cpp.
References fix_object(), and object_sum_weight().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_flip | ( | object * | op, |
| const char * | params | ||
| ) |
'flip' command.
| op | player. |
| params | message. |
Definition at line 997 of file c_chat.cpp.
References basic_emote(), and EMOTE_FLIP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_follow | ( | object * | op, |
| const char * | params | ||
| ) |
Follow a player, or stop following a player.
| op | Player follower |
| params | player to follow. If NULL, stop following player. |
Definition at line 2809 of file c_wiz.cpp.
References add_string(), can_follow(), object::contr, rv_vector::distance, draw_ext_info, draw_ext_info_format(), find_player_partial_name(), FLAG_WIZ, player::followed_player, FREE_AND_CLEAR_STR, get_rangevector(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_FAILURE, MSG_TYPE_COMMAND_SUCCESS, MSG_TYPE_COMMUNICATION, MSG_TYPE_COMMUNICATION_PARTY, object::name, NDI_UNIQUE, player::ob, and QUERY_FLAG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_forget_spell | ( | object * | op, |
| const char * | params | ||
| ) |
Command for players to forget a spell.
This command used to be available only to DMs.
| op | player |
| params | spell name to forget. |
Definition at line 2415 of file c_wiz.cpp.
References object::contr, do_forget_spell(), draw_ext_info, draw_ext_info_format(), lookup_spell_by_name(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, and spell.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_free | ( | object * | op, |
| const char * | params | ||
| ) |
Totally free an object.
| op | wizard. |
| params | object to free. |
Definition at line 1612 of file c_wiz.cpp.
References object::contr, dm_stack_pop(), draw_ext_info, FLAG_REMOVED, get_dm_object(), HEAD, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, object_free_drop_inventory(), object_remove(), QUERY_FLAG, and STACK_FROM_STACK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_freeze | ( | object * | op, |
| const char * | params | ||
| ) |
Freezes a player for a specified tick count, 100 by default.
| op | wizard freezing the player. |
| params | optional tick count, followed by player name. |
Definition at line 745 of file c_wiz.cpp.
References draw_ext_info, draw_ext_info_format(), get_other_player_from_name(), MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_RED, NDI_UNIQUE, player::ob, object::speed, and object::speed_left.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_frown | ( | object * | op, |
| const char * | params | ||
| ) |
'frown' command.
| op | player. |
| params | message. |
Definition at line 1008 of file c_chat.cpp.
References basic_emote(), and EMOTE_FROWN.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_gasp | ( | object * | op, |
| const char * | params | ||
| ) |
'gasp' command.
| op | player. |
| params | message. |
Definition at line 1019 of file c_chat.cpp.
References basic_emote(), and EMOTE_GASP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_giggle | ( | object * | op, |
| const char * | params | ||
| ) |
'giggle' command.
| op | player. |
| params | message. |
Definition at line 799 of file c_chat.cpp.
References basic_emote(), and EMOTE_GIGGLE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_glare | ( | object * | op, |
| const char * | params | ||
| ) |
'glare' command.
| op | player. |
| params | message. |
Definition at line 1030 of file c_chat.cpp.
References basic_emote(), and EMOTE_GLARE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_goto | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard teleports to a map.
| op | wizard teleporting. |
| params | map to teleport to. Can be absolute or relative path. |
Definition at line 724 of file c_wiz.cpp.
References do_goto(), draw_ext_info, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by command_loadtest(), and commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_grin | ( | object * | op, |
| const char * | params | ||
| ) |
'grin' command.
| op | player. |
| params | message. |
Definition at line 920 of file c_chat.cpp.
References basic_emote(), and EMOTE_GRIN.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_groan | ( | object * | op, |
| const char * | params | ||
| ) |
'groan' command.
| op | player. |
| params | message. |
Definition at line 1041 of file c_chat.cpp.
References basic_emote(), and EMOTE_GROAN.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_growl | ( | object * | op, |
| const char * | params | ||
| ) |
'growl' command.
| op | player. |
| params | message. |
Definition at line 832 of file c_chat.cpp.
References basic_emote(), and EMOTE_GROWL.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_gsay | ( | object * | op, |
| const char * | params | ||
| ) |
'gsay' command, talks to party.
| op | player. |
| params | message. |
Definition at line 75 of file c_party.cpp.
References command_party(), draw_ext_info, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_help | ( | object * | op, |
| const char * | params | ||
| ) |
Player is asking for some help.
| op | player asking for information. |
| params | what kind of help to ask for. |
Definition at line 1772 of file c_misc.cpp.
References command_list(), object::contr, Settings::datadir, display_help_file(), draw_ext_info_format(), find_help_file(), FLAG_WIZ, help_topics(), i18n_get_language_code(), player::language, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_INFO, NDI_UNIQUE, QUERY_FLAG, and settings.
Referenced by command_knowledge(), command_party(), command_quest(), command_shutdown(), and commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_hiccup | ( | object * | op, |
| const char * | params | ||
| ) |
'hiccup' command.
| op | player. |
| params | message. |
Definition at line 1052 of file c_chat.cpp.
References basic_emote(), and EMOTE_HICCUP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_hide | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard 'hide' command.
| op | DM wanting to hide. |
| params | ignored. |
Definition at line 389 of file c_wiz.cpp.
References do_wizard_hide().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_hiscore | ( | object * | op, |
| const char * | params | ||
| ) |
Player is asking for the hiscore.
| op | player asking for information. |
| params | options for the hiscore command (typically a match for the names) |
Definition at line 881 of file c_misc.cpp.
References hiscore_display().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_hug | ( | object * | op, |
| const char * | params | ||
| ) |
'hug' command.
| op | player. |
| params | message. |
Definition at line 876 of file c_chat.cpp.
References basic_emote(), and EMOTE_HUG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_insert_into | ( | object * | op, |
| const char * | params | ||
| ) |
Puts an object into another.
| op | wizard. |
| params | object specifier. |
Definition at line 2686 of file c_wiz.cpp.
References object::contr, dm_stack_pop(), draw_ext_info, draw_ext_info_format(), esrv_update_item(), FLAG_REMOVED, get_dm_object(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, object_find_by_tag_global(), object_insert_in_ob(), object_remove(), PLAYER, QUERY_FLAG, query_name(), STACK_FROM_NUMBER, STACK_FROM_TOP, player::stack_items, player::stack_position, object::type, UPD_NAME, UPD_NROF, and UPD_WEIGHT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_inventory | ( | object * | op, |
| const char * | params | ||
| ) |
Shows the inventory or some item.
| op | player. |
| params | object count to get the inventory of. If NULL then defaults to op. |
Definition at line 1335 of file c_wiz.cpp.
References draw_ext_info, inventory(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, and object_find_by_tag_global().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_invisible | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard wants to become invisible.
| op | wizard. |
| params | ignored. |
Definition at line 2226 of file c_wiz.cpp.
References draw_ext_info, object::invisible, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, object_update(), and UP_OBJ_FACE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_invoke | ( | object * | op, |
| const char * | params | ||
| ) |
'invoke' command, fires a spell immediately.
| op | player. |
| params | spell. |
Definition at line 38 of file c_range.cpp.
References command_cast_spell().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_kick | ( | object * | op, |
| const char * | params | ||
| ) |
Kicks a player from the server.
| op | DM kicking. |
| params | player to kick. Must be a full name match. |
Definition at line 556 of file c_wiz.cpp.
References command_kick2().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_kill_pets | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to get rid of pets.
| op | player. |
| params | unused. |
Definition at line 2196 of file c_misc.cpp.
References draw_ext_info, draw_ext_info_format(), free_objectlink(), get_friends_of(), list, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, object::name, NDI_UNIQUE, objectlink::next, objectlink::ob, object_get_owner(), pets_terminate(), pets_terminate_all(), and strcasecmp().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_kiss | ( | object * | op, |
| const char * | params | ||
| ) |
'kiss' command.
| op | player. |
| params | message. |
Definition at line 744 of file c_chat.cpp.
References basic_emote(), and EMOTE_KISS.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_knowledge | ( | object * | pl, |
| const char * | params | ||
| ) |
Handle the 'knowledge' for a player.
| pl | who is using the command. |
| params | additional parameters. |
Definition at line 1213 of file knowledge.cpp.
References command_help(), object::contr, knowledge_display(), knowledge_do_attempt(), knowledge_do_display(), knowledge_show(), llevError, LOG(), and object::name.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_language | ( | object * | op, |
| const char * | params | ||
| ) |
This is the 'language' command.
| op | player requesting the information. |
| params | optional language code ("en", "fr", etc.) |
Definition at line 130 of file c_misc.cpp.
References object::contr, draw_ext_info, draw_ext_info_format(), i18n_find_language_by_code(), i18n_list_languages(), player::language, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_laugh | ( | object * | op, |
| const char * | params | ||
| ) |
'laugh' command.
| op | player. |
| params | message. |
Definition at line 788 of file c_chat.cpp.
References basic_emote(), and EMOTE_LAUGH.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_learn_special_prayer | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard wants to learn a god-given spell.
| op | wizard. |
| params | spell name. |
Definition at line 2402 of file c_wiz.cpp.
References command_learn_spell_or_prayer().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_learn_spell | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard wants to learn a regular spell.
| op | wizard. |
| params | spell name. |
Definition at line 2390 of file c_wiz.cpp.
References command_learn_spell_or_prayer().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_lick | ( | object * | op, |
| const char * | params | ||
| ) |
'lick' command.
| op | player. |
| params | message. |
Definition at line 1063 of file c_chat.cpp.
References basic_emote(), and EMOTE_LICK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_list | ( | object * | pl, |
| bool | is_dm | ||
| ) |
Display the list of commands to a player.
| pl | player asking for commands. |
| is_dm | true if the player is a DM, false else. |
Definition at line 390 of file commands.cpp.
References COMMAND_TYPE_COMMUNICATION, COMMAND_TYPE_NORMAL, COMMAND_TYPE_WIZARD, draw_ext_info, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_INFO, NDI_UNIQUE, and show_commands().
Referenced by command_help().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_listen | ( | object * | op, |
| const char * | params | ||
| ) |
Change the player's listen level.
| op | player asking for information. |
| params | unused. |
Definition at line 1090 of file c_misc.cpp.
References object::contr, draw_ext_info_format(), player::listening, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_listplugins | ( | object * | op, |
| const char * | params | ||
| ) |
Lists all plugins currently loaded with their IDs and full names.
| op | wizard. |
| params | ignored. |
Definition at line 2443 of file c_wiz.cpp.
References plugins_display_list().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_loadplugin | ( | object * | op, |
| const char * | params | ||
| ) |
Loads the given plugin.
The DM specifies the name of the library to load (no pathname is needed). Do not ever attempt to load the same plugin more than once at a time, or bad things could happen.
| op | DM loading a plugin. |
| params | should be the plugin's name, eg cfpython.so |
Definition at line 2458 of file c_wiz.cpp.
References buf, draw_ext_info, draw_ext_info_format(), llevDebug, llevInfo, LOG(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, and plugins_init_plugin().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_loadtest | ( | object * | op, |
| const char * | params | ||
| ) |
This command will stress server.
It will basically load all world maps (so 900 maps).
| op | DM wanting to test the server. |
| params | option, must be "TRUE" for the test to happen. |
Definition at line 306 of file c_wiz.cpp.
References buf, command_goto(), draw_ext_info, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DEBUG, NDI_UNIQUE, settings, Settings::worldmapstartx, Settings::worldmapstarty, Settings::worldmaptilesx, and Settings::worldmaptilesy.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_lock_item | ( | object * | op, |
| const char * | params | ||
| ) |
Alternate way to lock/unlock items (command line).
| op | player |
| params | sent command line. |
Definition at line 2660 of file c_object.cpp.
References CLEAR_FLAG, draw_ext_info, draw_ext_info_format(), esrv_update_item(), find_best_object_match(), FLAG_INV_LOCKED, HUGE_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_FAILURE, name, NDI_UNIQUE, object_merge(), QUERY_FLAG, query_short_name(), SET_FLAG, and UPD_FLAGS.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_malloc | ( | object * | op, |
| const char * | params | ||
| ) |
Display memory information.
| op | player requesting information. |
| params | unused. |
Definition at line 796 of file c_misc.cpp.
References malloc_info().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_mapinfo | ( | object * | op, |
| const char * | params | ||
| ) |
'mapinfo' command.
| op | player requesting the information. |
| params | unused. |
Definition at line 809 of file c_misc.cpp.
References current_map_info().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_maps | ( | object * | op, |
| const char * | params | ||
| ) |
'maps' command.
| op | player requesting the information. |
| params | region to restrict to. |
Definition at line 835 of file c_misc.cpp.
References map_info().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_mark | ( | object * | op, |
| const char * | params | ||
| ) |
'mark' command, to mark an item for some effects (enchant armor, ...).
| op | player. |
| params | If empty, we print out the currently marked object. Otherwise, try to find a matching object - try best match first. |
Definition at line 1519 of file c_object.cpp.
References object::contr, object::count, draw_ext_info, draw_ext_info_format(), find_best_object_match(), find_marked_object(), player::mark, player::mark_count, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, name, NDI_UNIQUE, and query_name().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_me | ( | object * | op, |
| const char * | params | ||
| ) |
'me' command.
| op | player. |
| params | message. |
Definition at line 47 of file c_chat.cpp.
References buf, ext_info_map(), object::map, MAX_BUF, MSG_TYPE_COMMUNICATION, MSG_TYPE_COMMUNICATION_ME, object::name, NDI_BLUE, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_mon_aggr | ( | object * | op, |
| const char * | params | ||
| ) |
When DM is possessing a monster, flip aggression on and off, to allow better motion.
| op | wiard. |
| params | ignored. |
Definition at line 1405 of file c_wiz.cpp.
References CLEAR_FLAG, draw_ext_info, object::enemy, FLAG_FRIENDLY, FLAG_UNAGGRESSIVE, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, object_set_enemy(), QUERY_FLAG, and SET_FLAG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_motd | ( | object * | op, |
| const char * | params | ||
| ) |
Display the message of the day.
| op | player requesting the motd. |
| params | unused. |
Definition at line 215 of file c_misc.cpp.
References display_motd().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_news | ( | object * | op, |
| const char * | params | ||
| ) |
Display the server news.
| op | player requesting the news. |
| params | unused. |
Definition at line 241 of file c_misc.cpp.
References send_news().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_nod | ( | object * | op, |
| const char * | params | ||
| ) |
'nod' command.
| op | player. |
| params | message. |
Definition at line 722 of file c_chat.cpp.
References basic_emote(), and EMOTE_NOD.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_north | ( | object * | op, |
| const char * | params | ||
| ) |
'north' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 68 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_northeast | ( | object * | op, |
| const char * | params | ||
| ) |
'northeast' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 79 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_northwest | ( | object * | op, |
| const char * | params | ||
| ) |
'northwest' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 90 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_nowiz | ( | object * | op, |
| const char * | params | ||
| ) |
Steps down from wizard mode.
| op | wizard. |
| params | ignored. |
Definition at line 2080 of file c_wiz.cpp.
References CLEAR_FLAG, object::contr, draw_ext_info, FLAG_WAS_WIZ, FLAG_WIZ, FLAG_WIZCAST, FLAG_WIZPASS, player::hidden, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, NDI_ALL, NDI_LT_GREEN, NDI_UNIQUE, Settings::real_wiz, settings, TRUE, unhide(), and update_los().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_orcknuckle | ( | object * | op, |
| const char * | params | ||
| ) |
Plays the "orcknucke" game.
If there is an "dice" archetype in server arches, this command will require the player to have at least 4 dice to play. There is a 5% chance to lose one dice at each play. Dice can be made through alchemy (finding the recipe is left as an exercice to the player). Note that the check is on the name 'dice', so you can have multiple archetypes for that name, they'll be all taken into account.
| op | player who plays. |
| params | string sent by the player. Ignored. |
Definition at line 108 of file c_chat.cpp.
Referenced by commands_init().
Here is the caller graph for this function:| void command_overlay_reset | ( | object * | op, |
| const char * | params | ||
| ) |
Removes the overlay for op's current map.
| op | DM acting. |
| params | ignored. |
Definition at line 589 of file c_wiz.cpp.
References create_overlay_pathname(), draw_ext_info, object::map, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, mapstruct::path, and stats.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_overlay_save | ( | object * | op, |
| const char * | params | ||
| ) |
Saves the op's map as an overlay - objects are persisted.
| op | DM wanting to save. |
| params | ignored. |
Definition at line 568 of file c_wiz.cpp.
References draw_ext_info, object::map, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_SUCCESS, NDI_UNIQUE, save_map(), and SAVE_MODE_OVERLAY.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_party | ( | object * | op, |
| const char * | params | ||
| ) |
'party' command, subdivided in different sub commands.
| op | player. |
| params | additional parameters. 1. |
Definition at line 97 of file c_party.cpp.
References buf, command_help(), object::contr, draw_ext_info, draw_ext_info_format(), get_party_password(), list_players(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, MSG_TYPE_COMMUNICATION, MSG_TYPE_COMMUNICATION_PARTY, object::name, NDI_UNIQUE, NDI_WHITE, player::party, party_find(), party_form(), party_get_first(), party_get_leader(), party_get_next(), party_get_password(), party_join(), party_leave(), party_send_message(), party_set_password(), and partylist::partyname.
Referenced by command_gsay(), and commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_party_rejoin | ( | object * | op, |
| const char * | params | ||
| ) |
Handles the 'party_rejoin' command.
| op | player. |
| params | optional parameters. |
Definition at line 307 of file c_party.cpp.
References object::contr, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, NDI_UNIQUE, rejoin_modes, and player::rejoin_party.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_passwd | ( | object * | pl, |
| const char * | params | ||
| ) |
Player is asking to change password.
| pl | player. |
| params | unused. |
Definition at line 2236 of file c_misc.cpp.
References object::contr, CS_QUERY_HIDEINPUT, draw_ext_info, i18n(), socket_struct::login_method, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, player_set_state(), send_query(), player::socket, and ST_CHANGE_PASSWORD_OLD.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_patch | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard wants to altar an object.
| op | wizard. |
| params | object and what to patch. |
Definition at line 1493 of file c_wiz.cpp.
References object::contr, object::count, draw_ext_info, draw_ext_info_format(), FALSE, FLAG_WAS_WIZ, get_dm_object(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, Settings::real_wiz, SET_FLAG, set_variable(), and settings.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_peaceful | ( | object * | op, |
| const char * | params | ||
| ) |
Player toggles her peaceful status.
| op | player. |
| params | unused. |
Definition at line 2124 of file c_misc.cpp.
References object::contr, draw_ext_info, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, and player::peaceful.
Referenced by commands_init().
Here is the caller graph for this function:| void command_petmode | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change how her pets behave.
| op | player asking for change. |
| params | new mode. |
Definition at line 1437 of file c_misc.cpp.
References object::contr, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, pet_arena, pet_defend, pet_normal, pet_sad, player::petmode, and types.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_pickup | ( | object * | op, |
| const char * | params | ||
| ) |
'pickup' command.
| op | player. |
| params | pickup mode. Can be empty to display the current mode. |
Definition at line 2311 of file c_object.cpp.
References object::contr, display_new_pickup(), draw_ext_info, draw_ext_info_format(), get_pickup_mode_index(), llevDebug, LOG(), player::mode, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, pickup_modes, PU_NEWMODE, and set_pickup_mode().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_players | ( | object * | op, |
| const char * | params | ||
| ) |
Display all known players.
| op | player asking for information. |
| params | unused. |
Definition at line 1227 of file c_misc.cpp.
References buf, closedir(), draw_ext_info_format(), Settings::localdir, MAX_BUF, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, opendir(), Settings::playerdir, readdir(), settings, st, and t.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_poke | ( | object * | op, |
| const char * | params | ||
| ) |
'poke' command.
| op | player. |
| params | message. |
Definition at line 898 of file c_chat.cpp.
References basic_emote(), and EMOTE_POKE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_possess | ( | object * | op, |
| const char * | params | ||
| ) |
DM can possess a monster.
Basically, this tricks the client into thinking a given monster, is actually the player it controls. This allows a DM to inhabit a monster's body, and run around the game with it. This function is severely broken - it has tons of hardcoded values,
| op | wizard wanting to possess something. |
| params | monster to possess. |
Definition at line 1432 of file c_wiz.cpp.
References object::body_info, buf, object::contr, do_some_living(), draw_ext_info, esrv_new_player(), esrv_send_inventory(), fix_object(), FLAG_WIZ, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, NUM_BODY_LOCATIONS, player::ob, object_find_by_name_global(), object_find_by_tag_global(), PLAYER, SET_FLAG, and object::type.
Here is the call graph for this function:| void command_pout | ( | object * | op, |
| const char * | params | ||
| ) |
'pout' command.
| op | player. |
| params | message. |
Definition at line 1074 of file c_chat.cpp.
References basic_emote(), and EMOTE_POUT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_printlos | ( | object * | op, |
| const char * | params | ||
| ) |
Various LOS-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 1061 of file c_misc.cpp.
References print_los().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_puke | ( | object * | op, |
| const char * | params | ||
| ) |
'puke' command.
| op | player. |
| params | message. |
Definition at line 821 of file c_chat.cpp.
References basic_emote(), and EMOTE_PUKE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_purge_quest | ( | object * | op, |
| const char * | param | ||
| ) |
Definition at line 2853 of file c_wiz.cpp.
References draw_ext_info, free_quest(), MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_purge_quest_definitions | ( | object * | op, |
| const char * | param | ||
| ) |
Definition at line 2859 of file c_wiz.cpp.
References assets_collect(), ASSETS_QUESTS, Settings::datadir, draw_ext_info, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, NDI_UNIQUE, and settings.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_quest | ( | object * | op, |
| const char * | params | ||
| ) |
Command handler for 'quest'.
| op | player asking for information, warning emitted if not a player. |
| params | extra parameters for command. |
Definition at line 745 of file quest.cpp.
References quest_definition::client_code, quest_state::code, command_help(), object::contr, draw_ext_info, draw_ext_info_format(), find_player_partial_name(), FLAG_WIZ, get_quest(), get_quest_by_number(), i18n(), llevError, LOG(), MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_FAILURE, MSG_TYPE_COMMAND_QUESTS, MSG_TYPE_COMMAND_SUCCESS, name, object::name, NDI_UNIQUE, quest_state::next, player::ob, QUERY_FLAG, quest_get_by_code(), quest_info(), quest_list(), quest_set_state(), and quest_player::quests.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_quit | ( | object * | op, |
| const char * | params | ||
| ) |
Tell players to use the 'delete' command.
Too many new players have accidentally deleted their characters because they didn't carefully read the warning that the original 'quit' command gave.
Definition at line 1873 of file c_misc.cpp.
References draw_ext_info, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, and NDI_UNIQUE.
Referenced by commands_init().
Here is the caller graph for this function:| void command_recollect | ( | object * | op, |
| const char * | params | ||
| ) |
Definition at line 1531 of file c_wiz.cpp.
References Socket_Info::allocated_sockets, assets_finish_archetypes_for_play(), first_player, load_assets(), player::next, reset_faces_sent(), and socket_info.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| command_registration command_register | ( | const char * | name, |
| uint8_t | type, | ||
| command_function | func, | ||
| float | time | ||
| ) |
Register a player-issued command.
The only cause of failure is trying to override an existing command with one having a different type.
| name | command name. |
| type | type of the command, one of COMMAND_TYPE_xxx. |
| func | function to call for the command. |
| time | how long the command takes. |
Definition at line 101 of file commands.cpp.
References do_register(), name, time, and is_valid_types_gen::type.
Referenced by cfapi_register_command(), and cfweather_init().
Here is the call graph for this function:
Here is the caller graph for this function:| command_registration command_register_extra | ( | const char * | name, |
| const char * | extra, | ||
| uint8_t | type, | ||
| command_function_extra | func, | ||
| float | time | ||
| ) |
Register a player-issued command with an extra parameter.
This allow commands that need a supplemental fixed argument. The only cause of failure is trying to override an existing command with one having a different type.
| name | command name. |
| extra | extra data to give the command, must not be null. |
| type | type of the command, one of COMMAND_TYPE_xxx. |
| func | function to call for the command. |
| time | how long the command takes. |
Definition at line 526 of file commands.cpp.
References do_register(), name, time, and is_valid_types_gen::type.
Referenced by cfapi_register_command().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_remove | ( | object * | op, |
| const char * | params | ||
| ) |
Remove an object from its position.
| op | wizard. |
| params | object to remove. |
Definition at line 1565 of file c_wiz.cpp.
References object::contr, dm_stack_pop(), draw_ext_info, draw_ext_info_format(), FLAG_REMOVED, get_dm_object(), HEAD, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, name, NDI_UNIQUE, object_remove(), object_update_speed(), PLAYER, QUERY_FLAG, query_name(), object::speed, STACK_FROM_STACK, and object::type.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_rename_item | ( | object * | op, |
| const char * | params | ||
| ) |
Changing the custom name of an item.
Syntax is: rename <what object> to <new name>
Names are considered for all purpose having a length <=127 (max length sent to client by server).
| op | player. |
| params | how to rename. |
Definition at line 2474 of file c_object.cpp.
References buf, CUSTOM_NAME_FIELD, draw_ext_info, draw_ext_info_format(), esrv_update_item(), find_best_object_match(), find_marked_object(), FOR_INV_FINISH, FOR_INV_PREPARE, MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, name, NDI_UNIQUE, object::nrof, object_get_value(), object_merge(), object_set_value(), query_base_name(), sstring, UPD_NAME, and VERY_BIG_BUF.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_reply | ( | object * | op, |
| const char * | params | ||
| ) |
Reply to last person who told you something [mids 01/14/2002].
Must have been told something by someone first.
| op | who is telling. |
| params | message to say. |
Definition at line 336 of file c_chat.cpp.
References object::contr, draw_ext_info, draw_ext_info_format(), find_player(), FLAG_WIZ, player::hidden, player::last_tell, MAX_NAME, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMUNICATION, MSG_TYPE_COMMUNICATION_TELL, object::name, NDI_ORANGE, NDI_UNIQUE, player::ob, QUERY_FLAG, and safe_strncpy.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_reset | ( | object * | op, |
| const char * | params | ||
| ) |
Resets a map.
| op | wizard. |
| params | map to reset. Can be "." for current op's map, or a map path. |
Definition at line 1885 of file c_wiz.cpp.
References add_string(), object::contr, draw_ext_info, draw_ext_info_format(), enter_exit(), EXIT_PATH, EXIT_X, EXIT_Y, first_player, flush_old_maps(), FREE_AND_CLEAR_STR_IF, FREE_OBJ_NO_DESTROY_CALLBACK, has_been_loaded(), HUGE_BUF, llevDebug, llevError, LOG(), m, object::map, MAP_IN_MEMORY, map_remove_unique_files(), MAP_SWAPPED, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_RED, NDI_UNIQUE, player::next, player::ob, object_free(), object_insert_in_map_at(), object_new(), object_remove(), mapstruct::path, path_combine_and_normalize(), SAVE_ERROR_PLAYER, SAVE_ERROR_UCREATION, sstring, strlcpy(), swap_map(), player::transport, object::x, and object::y.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_resistances | ( | object * | op, |
| const char * | params | ||
| ) |
Players wants to know her resistances.
| op | player asking for information. |
| params | unused. |
Definition at line 1597 of file c_misc.cpp.
References ATNR_INTERNAL, atnr_is_dragon_enabled(), attacktype_desc, change_resist_msg, draw_ext_info, draw_ext_info_format(), FORCE, is_dragon_pl(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_INFO, NDI_UNIQUE, NROFATTACKS, object_find_by_type_and_arch_name(), and object::resist.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_rotateshoottype | ( | object * | op, |
| const char * | params | ||
| ) |
'rotateshoottype' command, switch range attack.
| op | player. |
| params | arguments to the command. '+' selects next range, other values previous range. |
Definition at line 343 of file c_range.cpp.
References object::contr, legal_range(), range_bottom, range_none, range_size, send_updated_shoottype(), and player::shoottype.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_rskill | ( | object * | pl, |
| const char * | params | ||
| ) |
'ready_skill' command.
| pl | player. |
| params | skill name. |
Definition at line 161 of file c_object.cpp.
References change_skill(), draw_ext_info, draw_ext_info_format(), find_skill_by_name(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_SKILL, MSG_TYPE_SKILL_MISSING, NDI_UNIQUE, and skill.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_rules | ( | object * | op, |
| const char * | params | ||
| ) |
Display the server rules.
| op | player requesting the rules. |
| params | unused. |
Definition at line 228 of file c_misc.cpp.
References send_rules().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_run | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to start running.
| op | player. |
| params | additional parameters. |
Definition at line 41 of file c_new.cpp.
References object::contr, draw_ext_info, move_player(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, and player::run_on.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_run_stop | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to stop running.
| op | player. |
| params | ignored. |
Definition at line 64 of file c_new.cpp.
References object::contr, and player::run_on.
Referenced by commands_init().
Here is the caller graph for this function:| void command_save | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to get saved.
| op | player. |
| params | unused. |
Definition at line 2098 of file c_misc.cpp.
References draw_ext_info, living::exp, get_map_flags(), object::map, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, P_NO_CLERIC, save_player(), object::stats, object::x, and object::y.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_say | ( | object * | op, |
| const char * | params | ||
| ) |
'say' command.
| op | player. |
| params | message. |
Definition at line 34 of file c_chat.cpp.
References monster_communicate().
Referenced by cfapi_object_say(), and commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_scream | ( | object * | op, |
| const char * | params | ||
| ) |
'scream' command.
| op | player. |
| params | message. |
Definition at line 843 of file c_chat.cpp.
References basic_emote(), and EMOTE_SCREAM.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_search | ( | object * | op, |
| const char * | params | ||
| ) |
'search' command.
| op | player. |
| params | unused. |
Definition at line 212 of file c_object.cpp.
References do_skill_by_number(), and SK_FIND_TRAPS.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_search_items | ( | object * | op, |
| const char * | params | ||
| ) |
'search-items' command.
| op | player. |
| params | options. |
Definition at line 2429 of file c_object.cpp.
References object::contr, draw_ext_info, draw_ext_info_format(), FALSE, fix_object(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, NDI_UNIQUE, Settings::search_items, player::search_str, and settings.
Referenced by commands_init(), and kill_player_not_permadeath().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_setgod | ( | object * | op, |
| const char * | params | ||
| ) |
Sets the god for some objects.
| op | DM wanting to change an object. |
| params | command options. Should contain two values, first the object to change, followed by the god to change it to. |
Definition at line 418 of file c_wiz.cpp.
References become_follower(), draw_ext_info, draw_ext_info_format(), find_god(), find_object_both(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, PLAYER, and object::type.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_settings | ( | object * | op, |
| const char * | ignored | ||
| ) |
Wizard wants to know some server settings, so display.
| op | wizard asking for settings. |
| ignored | ignored additional text. |
Definition at line 2914 of file c_wiz.cpp.
References Settings::allow_denied_spells_writing, Settings::casting_time, Settings::create_home_portals, Settings::death_penalty_level, Settings::death_penalty_ratio, draw_ext_info, draw_ext_info_format(), Settings::item_power_factor, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, NDI_UNIQUE, Settings::no_player_stealing, Settings::not_permadeth, Settings::permanent_exp_ratio, Settings::resurrection, Settings::set_friendly_fire, Settings::set_title, settings, Settings::spell_encumbrance, and Settings::spell_failure_effects.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shake | ( | object * | op, |
| const char * | params | ||
| ) |
'shake' command.
| op | player. |
| params | message. |
Definition at line 810 of file c_chat.cpp.
References basic_emote(), and EMOTE_SHAKE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shiver | ( | object * | op, |
| const char * | params | ||
| ) |
'shiver' command.
| op | player. |
| params | message. |
Definition at line 1085 of file c_chat.cpp.
References basic_emote(), and EMOTE_SHIVER.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shoottype | ( | object * | op, |
| const char * | params | ||
| ) |
'shoottype' command, set range attack.
| op | player. |
| params | arguments to the command. |
Definition at line 369 of file c_range.cpp.
References object::contr, draw_ext_info_format(), legal_range(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, range_bow, range_builder, range_golem, range_magic, range_misc, range_none, range_size, range_skill, send_updated_shoottype(), and player::shoottype.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shout | ( | object * | op, |
| const char * | params | ||
| ) |
'shout' command.
| op | player. |
| params | message. |
Definition at line 210 of file c_chat.cpp.
References command_tell_all(), MSG_TYPE_COMMUNICATION_SHOUT, and NDI_RED.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_showpets | ( | object * | op, |
| const char * | params | ||
| ) |
Players wants to know her pets.
| op | player asking for information. |
| params | unused. |
Definition at line 1481 of file c_misc.cpp.
References living::ac, living::Cha, living::Con, living::dam, living::Dex, draw_ext_info, draw_ext_info_format(), free_objectlink(), get_friends_of(), living::hp, living::Int, object::level, list, living::maxhp, living::maxsp, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, object::name, NDI_UNIQUE, objectlink::next, objectlink::ob, living::Pow, living::sp, object::stats, living::Str, living::wc, and living::Wis.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shrug | ( | object * | op, |
| const char * | params | ||
| ) |
'shrug' command.
| op | player. |
| params | message. |
Definition at line 1096 of file c_chat.cpp.
References basic_emote(), and EMOTE_SHRUG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_shutdown | ( | object * | op, |
| const char * | params | ||
| ) |
Totally shutdowns the server.
| op | wizard shutting down the server. |
| params | When to shut down the server. |
Definition at line 658 of file c_wiz.cpp.
References command_help(), draw_ext_info, draw_ext_info_format(), llevInfo, LOG(), MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, object::name, NDI_ALL, NDI_UNIQUE, shutdown_s::next_warn, SHUTDOWN_IDLE, SHUTDOWN_NONE, shutdown_state, SHUTDOWN_TIME, shutdown_s::time, time, and shutdown_s::type.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_sigh | ( | object * | op, |
| const char * | params | ||
| ) |
'sigh' command.
| op | player. |
| params | message. |
Definition at line 854 of file c_chat.cpp.
References basic_emote(), and EMOTE_SIGH.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_skills | ( | object * | op, |
| const char * | params | ||
| ) |
Player is asking for her skills.
Just show player's their skills for now. Dm's can already see skills w/ inventory command - b.t.
| op | player. |
| params | optional skill restriction. |
Definition at line 1365 of file c_wiz.cpp.
References show_skills().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_slap | ( | object * | op, |
| const char * | params | ||
| ) |
'slap' command.
| op | player. |
| params | message. |
Definition at line 1107 of file c_chat.cpp.
References basic_emote(), and EMOTE_SLAP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_smile | ( | object * | op, |
| const char * | params | ||
| ) |
'smile' command.
| op | player. |
| params | message. |
Definition at line 766 of file c_chat.cpp.
References basic_emote(), and EMOTE_SMILE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_smirk | ( | object * | op, |
| const char * | params | ||
| ) |
'smirk' command.
| op | player. |
| params | message. |
Definition at line 1118 of file c_chat.cpp.
References basic_emote(), and EMOTE_SMIRK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_snap | ( | object * | op, |
| const char * | params | ||
| ) |
'snap' command.
| op | player. |
| params | message. |
Definition at line 1129 of file c_chat.cpp.
References basic_emote(), and EMOTE_SNAP.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_sneeze | ( | object * | op, |
| const char * | params | ||
| ) |
'sneeze' command.
| op | player. |
| params | message. |
Definition at line 1140 of file c_chat.cpp.
References basic_emote(), and EMOTE_SNEEZE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_snicker | ( | object * | op, |
| const char * | params | ||
| ) |
'snicker' command.
| op | player. |
| params | message. |
Definition at line 1151 of file c_chat.cpp.
References basic_emote(), and EMOTE_SNICKER.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_sniff | ( | object * | op, |
| const char * | params | ||
| ) |
'sniff' command.
| op | player. |
| params | message. |
Definition at line 1162 of file c_chat.cpp.
References basic_emote(), and EMOTE_SNIFF.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_snore | ( | object * | op, |
| const char * | params | ||
| ) |
'snore' command.
| op | player. |
| params | message. |
Definition at line 1173 of file c_chat.cpp.
References basic_emote(), and EMOTE_SNORE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_sound | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change sound status.
| op | player asking for change. |
| params | unused. |
Definition at line 1910 of file c_misc.cpp.
References object::contr, draw_ext_info, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, SND_MUTE, player::socket, and socket_struct::sound.
Referenced by commands_init().
Here is the caller graph for this function:| void command_south | ( | object * | op, |
| const char * | params | ||
| ) |
'south' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 101 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_southeast | ( | object * | op, |
| const char * | params | ||
| ) |
'southeast' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 112 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_southwest | ( | object * | op, |
| const char * | params | ||
| ) |
'southwest' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 123 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_speed | ( | object * | op, |
| const char * | params | ||
| ) |
Changes the server speed.
| op | wizard. |
| params | new speed, or NULL to see the speed. |
Definition at line 1732 of file c_wiz.cpp.
References draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, reset_sleep(), set_tick_duration(), and tick_duration.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_spit | ( | object * | op, |
| const char * | params | ||
| ) |
'spit' command.
| op | player. |
| params | message. |
Definition at line 1184 of file c_chat.cpp.
References basic_emote(), and EMOTE_SPIT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_ssdumptable | ( | object * | op, |
| const char * | params | ||
| ) |
Various string-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 1019 of file c_misc.cpp.
References SS_DUMP_TABLE, and ss_dump_table().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_stack_clear | ( | object * | op, |
| const char * | params | ||
| ) |
Empty DM item stack.
| op | wizard. |
| params | ignored. |
Definition at line 2596 of file c_wiz.cpp.
References object::contr, draw_ext_info, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, NDI_UNIQUE, and player::stack_position.
Referenced by commands_init().
Here is the caller graph for this function:| void command_stack_list | ( | object * | op, |
| const char * | params | ||
| ) |
Displays stack contents.
| op | wizard. |
| params | ignored. |
Definition at line 2565 of file c_wiz.cpp.
References object::contr, object::count, draw_ext_info, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, object::name, NDI_UNIQUE, object_find_by_tag_global(), player::stack_items, and player::stack_position.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_stack_pop | ( | object * | op, |
| const char * | params | ||
| ) |
Pop the stack top.
| op | wizard. |
| params | ignored. |
Definition at line 2534 of file c_wiz.cpp.
References object::contr, and dm_stack_pop().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_stack_push | ( | object * | op, |
| const char * | params | ||
| ) |
Push specified item on stack.
| op | wizard. |
| params | object specifier. |
Definition at line 2547 of file c_wiz.cpp.
References object::contr, object::count, dm_stack_push(), get_dm_object(), and STACK_FROM_NUMBER.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_statistics | ( | object * | pl, |
| const char * | params | ||
| ) |
Prints out some useful information for the character.
Everything we print out can be determined by the docs, so we aren't revealing anything extra - rather, we are making it convenient to find the values. params have no meaning here.
| pl | player asking for information. |
| params | unused. |
Add preliminary damage per second calculations here
Definition at line 1121 of file c_misc.cpp.
References object::arch, buf, living::Cha, archetype::clone, living::Con, object::contr, living::dam, living::Dex, draw_ext_info, draw_ext_info_format(), living::exp, object::expmul, FMT64, i18n(), living::Int, object::level, level_exp(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_STATISTICS, NDI_UNIQUE, player::orig_stats, player::peaceful, living::Pow, safe_strncpy, seconds(), object::stats, living::Str, tick_duration, player::ticks_played, object::weapon_speed, and living::Wis.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_stats | ( | object * | op, |
| const char * | params | ||
| ) |
Displays the statistics of a player.
| op | wizard. |
| params | player's name. |
Definition at line 1762 of file c_wiz.cpp.
References living::ac, living::Cha, living::Con, living::dam, living::Dex, draw_ext_info, draw_ext_info_format(), living::exp, find_player_partial_name(), FMT64, living::food, living::grace, living::hp, living::Int, living::maxhp, living::maxsp, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::ob, living::Pow, living::sp, object::stats, living::Str, living::wc, and living::Wis.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_stay | ( | object * | op, |
| const char * | params | ||
| ) |
'stay' command.
Used to specify to fire under oneself.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 145 of file c_move.cpp.
References object::contr, fire(), and player::fire_on.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_strings | ( | object * | op, |
| const char * | params | ||
| ) |
Various string-related statistics.
| op | player asking for information. |
| params | unused. |
Definition at line 847 of file c_misc.cpp.
References draw_ext_info, draw_ext_info_format(), HUGE_BUF, MSG_TYPE_COMMAND, MSG_TYPE_LAST, NDI_UNIQUE, ss_dump_statistics(), ss_dump_table(), SS_DUMP_TOTALS, and stats.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_strut | ( | object * | op, |
| const char * | params | ||
| ) |
'strut' command.
| op | player. |
| params | message. |
Definition at line 1195 of file c_chat.cpp.
References basic_emote(), and EMOTE_STRUT.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_style_map_info | ( | object * | op, |
| const char * | params | ||
| ) |
Displays information about styles loaded for random maps.
| op | wizard. |
| params | ignored. |
Definition at line 2763 of file c_wiz.cpp.
References draw_ext_info, draw_ext_info_format(), FOR_MAP_FINISH, FOR_MAP_PREPARE, MAP_HEIGHT, map_size(), MAP_WIDTH, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_MAPS, NDI_UNIQUE, mapstruct::next, and styles.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_sulk | ( | object * | op, |
| const char * | params | ||
| ) |
'sulk' command.
| op | player. |
| params | message. |
Definition at line 865 of file c_chat.cpp.
References basic_emote(), and EMOTE_SULK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_summon | ( | object * | op, |
| const char * | params | ||
| ) |
Summons player near DM.
| op | DM. |
| params | player to summon. |
Definition at line 866 of file c_wiz.cpp.
References add_string(), draw_ext_info, draw_ext_info_format(), enter_exit(), EXIT_PATH, EXIT_X, EXIT_Y, FREE_OBJ_NO_DESTROY_CALLBACK, freearr_x, freearr_y, get_other_player_from_name(), object::map, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::ob, object_find_free_spot(), object_free(), object_new(), mapstruct::path, object::x, and object::y.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_swap | ( | object * | op, |
| const char * | params | ||
| ) |
Mark a map as ready for swapping.
Definition at line 907 of file c_wiz.cpp.
References draw_ext_info, has_been_loaded(), HUGE_BUF, m, object::map, MAP_IN_MEMORY, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_SUCCESS, NDI_UNIQUE, mapstruct::path, and path_combine_and_normalize().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_take | ( | object * | op, |
| const char * | params | ||
| ) |
This takes (picks up) an item.
| op | player who issued the command. |
| params | string to match against the item name. |
Definition at line 797 of file c_object.cpp.
References object::above, object::below, CLEAR_FLAG, object::container, object::contr, player::count, draw_ext_info, draw_ext_info_format(), esrv_update_item(), fix_object(), FLAG_NO_FIX_PLAYER, FOR_BELOW_FINISH, FOR_BELOW_PREPARE, FOR_OB_AND_BELOW_FINISH, FOR_OB_AND_BELOW_PREPARE, is_valid_types_gen::found, object::inv, object::invisible, make_matcher(), matcher_params::missed, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, MSG_TYPE_COMMAND_FAILURE, object::name, NDI_UNIQUE, pick_up(), PLAYER, SET_FLAG, object::type, and UPD_WEIGHT.
Referenced by commands_init(), and knowledge_alchemy_attempt().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_teleport | ( | object * | op, |
| const char * | params | ||
| ) |
Teleport next to target player.
| op | DM teleporting. |
| params | options sent by player. |
Definition at line 933 of file c_wiz.cpp.
References add_string(), object::contr, draw_ext_info, draw_ext_info_format(), enter_exit(), EXIT_PATH, EXIT_X, EXIT_Y, find_player_partial_name(), FREE_OBJ_NO_DESTROY_CALLBACK, freearr_x, freearr_y, player::hidden, object::map, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, player::ob, object_find_free_spot(), object_free(), object_new(), mapstruct::path, object::x, and object::y.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_tell | ( | object * | op, |
| const char * | params | ||
| ) |
Private communication.
| op | player trying to tell something to someone. |
| params | who to tell, and message. |
Definition at line 308 of file c_chat.cpp.
References do_tell().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_thank | ( | object * | op, |
| const char * | params | ||
| ) |
'thank' command.
| op | player. |
| params | message. |
Definition at line 1206 of file c_chat.cpp.
References basic_emote(), and EMOTE_THANK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_think | ( | object * | op, |
| const char * | params | ||
| ) |
'think' command.
| op | player. |
| params | message. |
Definition at line 1305 of file c_chat.cpp.
References basic_emote(), and EMOTE_THINK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_throw | ( | object * | op, |
| const char * | params | ||
| ) |
'throw' command.
A little special because we do want to pass the full params along as it includes the object to throw.
| op | player. |
| params | what to throw. |
Definition at line 239 of file c_object.cpp.
References do_skill_by_number(), and SK_THROWING.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_time | ( | object * | op, |
| const char * | params | ||
| ) |
Players asks for the time.
| op | player asking for information. |
| params | unused. |
Definition at line 868 of file c_misc.cpp.
References time_info().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_title | ( | object * | op, |
| const char * | params | ||
| ) |
Player wishes to change her title.
| op | player asking for change. |
| params | new title. |
Definition at line 2047 of file c_misc.cpp.
References buf, object::contr, draw_ext_info, FALSE, HUGE_BUF, is_dragon_pl(), MAX_BUF, MAX_NAME, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, player_get_title(), player_has_own_title(), player_set_own_title(), Settings::set_title, and settings.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_toggle_shout | ( | object * | op, |
| const char * | params | ||
| ) |
A simple toggle for the no_shout field.
AKA the MUZZLE command.
| op | wizard toggling. |
| params | player to mute/unmute. |
Definition at line 615 of file c_wiz.cpp.
References object::contr, draw_ext_info, draw_ext_info_format(), EVENT_MUZZLE, events_execute_global_event(), get_other_player_from_name(), MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_DM, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_ORANGE, NDI_RED, NDI_UNIQUE, player::no_shout, and player::ob.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_twiddle | ( | object * | op, |
| const char * | params | ||
| ) |
'twiddle' command.
| op | player. |
| params | message. |
Definition at line 1217 of file c_chat.cpp.
References basic_emote(), and EMOTE_TWIDDLE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_unarmed_skill | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change prefered unarmed skill.
| op | player asking for change. |
| params | new mode. |
Definition at line 1381 of file c_misc.cpp.
References add_string(), object::contr, draw_ext_info_format(), find_skill_by_name(), free_string(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, skill, player::unarmed_skill, and unarmed_skills.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_unloadplugin | ( | object * | op, |
| const char * | params | ||
| ) |
Unloads the given plugin.
The DM specified the ID of the library to unload. Note that some things may behave strangely if the correct plugins are not loaded.
| op | DM unloading a plugin. |
| params | should be the plugin's internal name, eg Python |
Definition at line 2490 of file c_wiz.cpp.
References draw_ext_info, draw_ext_info_format(), init_signals(), llevInfo, LOG(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_DM, MSG_TYPE_COMMAND_ERROR, object::name, NDI_UNIQUE, and plugins_remove_plugin().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_unregister | ( | command_registration | command | ) |
Unregister a previously registered command.
| command | identifier returned by command_register() or command_register_extra(). |
Definition at line 535 of file commands.cpp.
References command, and registered_commands.
Referenced by cfapi_unregister_command(), and cfweather_close().
Here is the caller graph for this function:| void command_use | ( | object * | op, |
| const char * | params | ||
| ) |
Try to use an item on another.
Items are checked for key/values matching.
| op | player. |
| params | sent string, with all parameters. |
Definition at line 2703 of file c_object.cpp.
References object::arch, recipe::arch_name, create_archetype(), draw_ext_info, draw_ext_info_format(), find_best_object_match(), find_recipe_for_tool(), recipe::ingred, recipe::ingred_count, IS_PLAYER(), MAX_BUF, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_FAILURE, linked_char::name, object::name, archetype::name, NDI_UNIQUE, object::nrof, object_decrease_nrof_by_one, object_insert_in_ob(), strlcpy(), and recipe::yield.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_usekeys | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change how keys are used.
| op | player asking for information. |
| params | unused. |
Definition at line 1556 of file c_misc.cpp.
References containers, object::contr, draw_ext_info_format(), key_inventory, keyrings, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, types, and player::usekeys.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_uskill | ( | object * | pl, |
| const char * | params | ||
| ) |
'use_skill' command.
| pl | player. |
| params | skill to use, and optional parameters. |
Definition at line 144 of file c_object.cpp.
References draw_ext_info, MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_ERROR, NDI_UNIQUE, and use_skill().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_version | ( | object * | op, |
| const char * | params | ||
| ) |
Server version.
| op | player asking for information. |
| params | unused. |
Definition at line 1076 of file c_misc.cpp.
References draw_ext_info_format(), FULL_VERSION, MSG_TYPE_ADMIN, MSG_TYPE_ADMIN_VERSION, and NDI_UNIQUE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_wave | ( | object * | op, |
| const char * | params | ||
| ) |
'wave' command.
| op | player. |
| params | message. |
Definition at line 1228 of file c_chat.cpp.
References basic_emote(), and EMOTE_WAVE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_west | ( | object * | op, |
| const char * | params | ||
| ) |
'west' command.
| op | player. |
| params | optional parameters for moving (fire, run). |
Definition at line 134 of file c_move.cpp.
References move_internal().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_whereabouts | ( | object * | op, |
| const char * | params | ||
| ) |
'whereabouts' command.
Displays how many players are in which regions.
| op | player requesting information. |
| params | unused. |
Definition at line 482 of file c_misc.cpp.
References all_regions, region::counter, draw_ext_info, draw_ext_info_format(), first_player, get_region_by_map(), get_region_longname(), llevError, LOG(), object::map, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, player::next, and player::ob.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_whereami | ( | object * | op, |
| const char * | params | ||
| ) |
'whereami' command.
| op | player requesting the information. |
| params | unused. |
Definition at line 822 of file c_misc.cpp.
References current_region_info().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_whistle | ( | object * | op, |
| const char * | params | ||
| ) |
'whistle' command.
| op | player. |
| params | message. |
Definition at line 1239 of file c_chat.cpp.
References basic_emote(), and EMOTE_WHISTLE.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_who | ( | object * | op, |
| const char * | params | ||
| ) |
'who' command.
| op | player requesting the information. |
| params | optional region to limit the information to. |
Definition at line 623 of file c_misc.cpp.
References get_region_from_string(), and list_players().
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_wimpy | ( | object * | op, |
| const char * | params | ||
| ) |
Player wants to change how soon she'll flee.
| op | player. |
| params | new value. |
Definition at line 2142 of file c_misc.cpp.
References draw_ext_info, draw_ext_info_format(), MSG_TYPE_COMMAND, MSG_TYPE_COMMAND_CONFIG, NDI_UNIQUE, and object::run_away.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_wink | ( | object * | op, |
| const char * | params | ||
| ) |
'wink' command.
| op | player. |
| params | message. |
Definition at line 1250 of file c_chat.cpp.
References basic_emote(), and EMOTE_WINK.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_wizcast | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard toggling "cast everywhere" ability.
| op | player asking for information. |
| params | unused. |
Definition at line 947 of file c_misc.cpp.
References CLEAR_FLAG, draw_ext_info, FLAG_WIZCAST, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, onoff_value(), QUERY_FLAG, and SET_FLAG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_wizpass | ( | object * | op, |
| const char * | params | ||
| ) |
Wizard toggling wall-crossing.
| op | player asking for information. |
| params | unused. |
Definition at line 917 of file c_misc.cpp.
References CLEAR_FLAG, draw_ext_info, FLAG_WIZPASS, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, onoff_value(), QUERY_FLAG, and SET_FLAG.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void command_yawn | ( | object * | op, |
| const char * | params | ||
| ) |
'yawn' command.
| op | player. |
| params | message. |
Definition at line 1261 of file c_chat.cpp.
References basic_emote(), and EMOTE_YAWN.
Referenced by commands_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void commands_clear | ( | ) |
Clear all registered commands.
Definition at line 346 of file commands.cpp.
References next_registration, and registered_commands.
Referenced by cleanup().
Here is the caller graph for this function:| void commands_init | ( | void | ) |
Init standard commands.
Wizard commands.
Definition at line 108 of file commands.cpp.
References command_abil(), command_accountpasswd(), command_accuse(), command_addexp(), command_afk(), command_apply(), command_applymode(), command_arrest(), command_banish(), command_beg(), command_bleed(), command_blush(), command_body(), command_bounce(), command_bow(), command_bowmode(), command_brace(), command_burp(), command_cackle(), command_cast(), command_chat(), command_chuckle(), command_clap(), command_cointoss(), command_cough(), command_create(), command_cringe(), command_cry(), command_dance(), command_debug(), command_delete(), command_diff(), command_disarm(), command_dm(), command_dmhide(), command_dmtell(), command_drop(), command_dropall(), command_dump(), command_dumpabove(), command_dumpallarchetypes(), command_dumpallmaps(), command_dumpallobjects(), command_dumpbelow(), command_dumpfriendlyobjects(), command_dumpmap(), command_east(), command_empty(), command_examine(), command_face(), command_fire(), command_fire_stop(), command_fix_me(), command_flip(), command_follow(), command_forget_spell(), command_free(), command_freeze(), command_frown(), command_gasp(), command_giggle(), command_glare(), command_goto(), command_grin(), command_groan(), command_growl(), command_gsay(), command_help(), command_hiccup(), command_hide(), command_hiscore(), command_hug(), command_insert_into(), command_inventory(), command_invisible(), command_invoke(), command_kick(), command_kill_pets(), command_kiss(), command_knowledge(), command_language(), command_laugh(), command_learn_special_prayer(), command_learn_spell(), command_lick(), command_listen(), command_listplugins(), command_loadplugin(), command_loadtest(), command_lock_item(), command_malloc(), command_mapinfo(), command_maps(), command_mark(), command_me(), command_mon_aggr(), command_motd(), command_news(), command_nod(), command_north(), command_northeast(), command_northwest(), command_nowiz(), command_orcknuckle(), command_overlay_reset(), command_overlay_save(), command_partial_commands(), command_party(), command_party_rejoin(), command_passwd(), command_patch(), command_peaceful(), command_petmode(), command_pickup(), command_players(), command_poke(), command_pout(), command_printlos(), command_puke(), command_purge_quest(), command_purge_quest_definitions(), command_quest(), command_quit(), command_recollect(), command_remove(), command_rename_item(), command_reply(), command_reset(), command_resistances(), command_rotateshoottype(), command_rskill(), command_rules(), command_run(), command_run_stop(), command_save(), command_say(), command_scream(), command_search(), command_search_items(), command_setgod(), command_settings(), command_shake(), command_shiver(), command_shoottype(), command_shout(), command_showpets(), command_shrug(), command_shutdown(), command_sigh(), command_skills(), command_slap(), command_smile(), command_smirk(), command_snap(), command_sneeze(), command_snicker(), command_sniff(), command_snore(), command_sound(), command_south(), command_southeast(), command_southwest(), command_speed(), command_spit(), command_ssdumptable(), command_stack_clear(), command_stack_list(), command_stack_pop(), command_stack_push(), command_statistics(), command_stats(), command_stay(), command_strings(), command_strut(), command_style_map_info(), command_sulk(), command_summon(), command_swap(), command_take(), command_teleport(), command_tell(), command_thank(), command_think(), command_throw(), command_time(), command_title(), command_toggle_shout(), command_twiddle(), command_unarmed_skill(), command_unloadplugin(), command_use(), command_usekeys(), command_uskill(), command_version(), command_wave(), command_west(), command_whereabouts(), command_whereami(), command_whistle(), command_who(), command_wimpy(), command_wink(), command_wizcast(), command_wizpass(), command_yawn(), RC, RN, and RW.
Referenced by init().
Here is the caller graph for this function:| void cone_drop | ( | object * | op | ) |
Drops an object based on what is in the cone's "other_arch".
| op | what object should drop. |
Definition at line 265 of file spell_attack.cpp.
References add_refcount(), arch_to_object(), free_string(), object::level, object::map, object_get_owner(), object_insert_in_map_at(), object_set_owner(), do_skill_cb_data::op, object::other_arch, object::skill, object::x, and object::y.
Referenced by cast_cone(), and move_cone().
Here is the call graph for this function:
Here is the caller graph for this function:| void confirm_password | ( | object * | op | ) |
Ask the player to confirm her password during creation.
| op | player. |
Definition at line 1012 of file player.cpp.
References object::contr, CS_QUERY_HIDEINPUT, i18n(), player_set_state(), send_query(), player::socket, and ST_CONFIRM_PASSWORD.
Referenced by check_login().
Here is the call graph for this function:
Here is the caller graph for this function:Confuse a living thing.
| op | victim. |
| hitter | who is attacking, unused. |
| dam | damage to deal, unused. |
Definition at line 2315 of file attack.cpp.
References add_string(), ATNR_CONFUSION, create_archetype(), draw_ext_info, object::duration, FLAG_APPLIED, FLAG_CONFUSED, FORCE, FORCE_CONFUSION, FORCE_NAME, free_string(), MAX, MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_BAD_EFFECT_START, object::name, NDI_UNIQUE, object_insert_in_ob(), object_present_in_ob_by_name(), PLAYER, QUERY_FLAG, object::resist, SET_FLAG, object::speed, object::subtype, and object::type.
Referenced by charge_mana_effect(), hit_with_one_attacktype(), prayer_failure(), scroll_failure(), spell_failure(), and write_scroll().
Here is the call graph for this function:
Here is the caller graph for this function:| void counterspell | ( | object * | op, |
| int | dir | ||
| ) |
Nullifies spell effects.
Basically, if the object has a magic attacktype, this may nullify it.
| op | counterspell object. |
| dir | direction it was cast in. |
Definition at line 2911 of file spell_effect.cpp.
References AT_COUNTERSPELL, AT_MAGIC, object::attacktype, do_skill_cb_data::dir, FLAG_MONSTER, living::food, FOR_MAP_FINISH, FOR_MAP_PREPARE, freearr_x, freearr_y, get_map_flags(), HEAD, living::hp, object::level, m, object::map, object_free(), object_get_owner(), object_remove(), do_skill_cb_data::op, P_OUT_OF_MAP, QUERY_FLAG, rndm(), RUNE, object::speed_left, SPELL_EFFECT, object::stats, object::type, object::x, and object::y.
Referenced by hit_map().
Here is the call graph for this function:
Here is the caller graph for this function:Create an aura spell object and put it in the player's inventory.
This is also used for elemental shields - the creation is the same just the 'move' code is different.
| op | who is casting. |
| caster | what is casting. |
| spell | actual spell object. |
Definition at line 3327 of file spell_effect.cpp.
References add_refcount(), arch_present_in_ob(), arch_to_object(), object::attacktype, caster_level(), change_abil(), create_archetype(), living::dam, draw_ext_info, object::duration, fix_object(), FLAG_APPLIED, FORCE, FORCE_CHANGE_ABILITY, FORCE_NAME, free_string(), object::level, MAX, MSG_TYPE_SPELL, MSG_TYPE_SPELL_SUCCESS, object::name, object::name_pl, NDI_UNIQUE, NROFATTACKS, object_insert_in_ob(), object_present_in_ob_by_name(), object_set_owner(), do_skill_cb_data::op, PLAYER, object::range, object::resist, SET_FLAG, set_spell_skill(), SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), object::speed, spell, object::stats, store_spell_expiry(), object::subtype, and object::type.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Create a bomb.
| op | who is casting. |
| caster | what object is casting. |
| dir | cast direction. |
| spell | spell object to cast. |
| 0 | no bomb was placed. |
| 1 | bomb was placed on map. |
Definition at line 447 of file spell_attack.cpp.
References arch_to_object(), object::attacktype, living::dam, do_skill_cb_data::dir, draw_ext_info, object::duration, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, m, object::map, MOVE_WALK, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, NDI_UNIQUE, object_insert_in_map_at(), object_set_owner(), do_skill_cb_data::op, P_OUT_OF_MAP, object::range, set_spell_skill(), SP_level_dam_adjust(), SP_level_duration_adjust(), SP_level_range_adjust(), spell, object::stats, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| bool csv_contains | ( | std::string | list, |
| std::string | item, | ||
| std::string | delim = "," |
||
| ) |
Split list by comma, then see if item matches anything in the list.
Definition at line 302 of file c_object.cpp.
References list.
Referenced by sack_race_can_contain().
Here is the caller graph for this function:Do the cure disease stuff, from the spell "cure disease".
| sufferer | who is getting cured. |
| caster | spell object used for curing. If NULL all diseases are removed, else only those of lower level than caster or randomly chosen. |
| skill | skill to give experience to, can be NULL. |
| 0 | no disease was cured. |
| 1 | at least one disease was cured. |
Definition at line 685 of file disease.cpp.
References change_exp(), DISEASE, draw_ext_info, draw_ext_info_format(), living::exp, FLAG_STARTEQUIP, FOR_INV_FINISH, FOR_INV_PREPARE, object::level, MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_BAD_EFFECT_END, MSG_TYPE_SPELL, MSG_TYPE_SPELL_HEAL, NDI_UNIQUE, object_free_drop_inventory(), object_remove(), PREFER_LOW, QUERY_FLAG, random_roll(), remove_symptoms(), skill, and object::stats.
Referenced by cast_heal(), and restore_player().
Here is the call graph for this function:
Here is the caller graph for this function:| void dead_player | ( | object * | op | ) |
Kill a player on a permanent death server with resurrection.
| op | player to kill. |
Definition at line 297 of file resurrection.cpp.
References llevError, Settings::localdir, LOG(), make_perma_dead(), MAX_BUF, object::name, Settings::playerdir, and settings.
Referenced by kill_player_permadeath().
Here is the call graph for this function:
Here is the caller graph for this function:| void delete_character | ( | const char * | name | ) |
Totally deletes a character.
The contents of its directory are effectively totally removed. Used when a player 'quits' the game, or dies on a server with permadeath and no resurrect.
| name | player to delete. |
Definition at line 88 of file login.cpp.
References buf, Settings::localdir, MAX_BUF, name, Settings::playerdir, remove_directory(), and settings.
Referenced by key_confirm_quit(), and kill_player_permadeath().
Here is the call graph for this function:
Here is the caller graph for this function:| void destroy_object | ( | object * | op | ) |
Recursively object_free_drop_inventory() op and its inventory.
| op | object to totally object_free_drop_inventory(). |
Definition at line 209 of file login.cpp.
References FLAG_REMOVED, object::inv, object_free_drop_inventory(), object_remove(), and QUERY_FLAG.
Referenced by save_player(), and trap_disarm().
Here is the call graph for this function:
Here is the caller graph for this function:Runs a 'detect curse' check on a given item.
| pl | player detecting a curse. |
| tmp | object to check for curse |
| skill | detect skill object. |
Definition at line 712 of file skills.cpp.
References calc_skill_exp(), esrv_update_item(), FLAG_CURSED, FLAG_DAMNED, FLAG_IDENTIFIED, FLAG_KNOWN_CURSED, object::item_power, NROF(), QUERY_FLAG, SET_FLAG, skill, and UPD_FLAGS.
Referenced by do_skill_detect_curse(), and examine_autoidentify().
Here is the call graph for this function:
Here is the caller graph for this function:Runs a 'detect magic' check on a given item.
| pl | player detecting magic. |
| tmp | object to check for magic |
| skill | detect skill object. |
Definition at line 761 of file skills.cpp.
References calc_skill_exp(), esrv_update_item(), FLAG_IDENTIFIED, FLAG_KNOWN_MAGICAL, is_magical(), object::item_power, NROF(), QUERY_FLAG, SET_FLAG, skill, and UPD_FLAGS.
Referenced by do_skill_detect_magic(), and examine_autoidentify().
Here is the call graph for this function:
Here is the caller graph for this function:| const char* determine_god | ( | object * | op | ) |
Determines if op worships a god.
Returns the godname if they do or "none" if they have no god. In the case of an NPC, if they have no god, we try and guess who they should worship based on their race. If that fails we give them a random one.
| op | object to get name of. |
Definition at line 55 of file gods.cpp.
References add_string(), find_god(), FLAG_ALIVE, get_god_for_race(), get_rand_god(), object::name, object_find_by_type_subtype(), PLAYER, QUERY_FLAG, object::race, SK_PRAYING, SKILL, SPELL, SPELL_EFFECT, object::title, and object::type.
Referenced by become_follower(), cast_bless(), cast_consecrate(), cast_curse(), cast_detection(), cast_smite_spell(), cast_spell(), cfapi_object_get_property(), hit_player(), hit_with_one_attacktype(), kill_player_not_permadeath(), mood_change(), perceive_self(), pets_summon_golem(), pets_summon_object(), pray_at_altar(), prayer_failure(), ring_bell(), show_skills(), and tailor_god_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Determines the archetype for holy servant and god avatar.
Possible monsters are stored as invisible books in god's inventory, one having the right name is selected randomly.
| god | god for which we want something. |
| type | what the summon type is. Must be a shared string. |
Definition at line 676 of file gods.cpp.
References BOOK, archetype::clone, object::invisible, treasure::item, treasurelist::items, llevError, LOG(), object::name, treasure::next, object::other_arch, object::randomitems, rndm(), is_valid_types_gen::type, and object::type.
Referenced by pets_summon_golem().
Here is the call graph for this function:
Here is the caller graph for this function:Teleport through some doors and space.
| op | who is casting. |
| caster | what is casting. |
| spob | actual spell object. |
| dir | casting direction. |
| 0 | spell failure. |
| 1 | spell was successful. |
Definition at line 1609 of file spell_effect.cpp.
References object::contr, player::count, do_skill_cb_data::dir, draw_ext_info, esrv_map_scroll(), FABS, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, m, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_ERROR, MSG_TYPE_SPELL_FAILURE, NDI_UNIQUE, ob_apply(), OB_TYPE_MOVE_BLOCK, object_insert_in_map_at(), object_remove(), do_skill_cb_data::op, P_BLOCKSVIEW, P_IS_ALIVE, P_NO_MAGIC, P_OUT_OF_MAP, PLAYER, player_update_bg_music(), object::range, player::socket, SP_level_range_adjust(), object::speed, object::speed_left, TRANSPORT, player::transport, object::type, object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:Someone is trying to disarm a rune.
The actual attempt is done in trap_disarm().
| op | object trying to disarm. |
| skill | skill to disarm runes. |
| dir | direction to disarm. |
| 0 | rune wasn't disarmed. |
| 1 | a rune was disarmed. |
Definition at line 304 of file rune.cpp.
References draw_ext_info, FOR_MAP_FINISH, FOR_MAP_PREPARE, freearr_x, freearr_y, get_map_flags(), m, object::map, MSG_TYPE_SPELL, MSG_TYPE_SPELL_FAILURE, MSG_TYPE_SPELL_SUCCESS, NDI_UNIQUE, object_find_by_type2(), object_free_drop_inventory(), object_remove(), P_OUT_OF_MAP, RUNE, SIGN, skill, TRAP, trap_disarm(), object::x, and object::y.
Referenced by cast_spell().
Here is the call graph for this function:
Here is the caller graph for this function:| void display_motd | ( | const object * | op | ) |
Sends the message of the day to the player.
| op | player to send to. |
Definition at line 139 of file player.cpp.
References buf, Settings::confdir, draw_ext_info, HUGE_BUF, MAX_BUF, motd, Settings::motd, MSG_SUBTYPE_NONE, MSG_TYPE_MOTD, NDI_GREEN, NDI_UNIQUE, safe_strcat(), and settings.
Referenced by add_player(), command_motd(), and receive_player_password().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 2865 of file c_wiz.cpp.
References object::contr, object::count, dm_stack_push(), draw_ext_info, MSG_SUBTYPE_NONE, MSG_TYPE_COMMAND, NDI_UNIQUE, object_dump(), stringbuffer_finish(), and stringbuffer_new().
Referenced by command_dumpabove(), command_dumpbelow(), and examine_cmd().
Here is the call graph for this function:
Here is the caller graph for this function:| void do_forget_spell | ( | object * | op, |
| const char * | spell | ||
| ) |
Erases spell from player's inventory.
Will inform player of loss.
| op | player. |
| spell | spell name to forget. |
Definition at line 187 of file apply.cpp.
References check_spell_known(), object::contr, draw_ext_info_format(), esrv_remove_spell(), llevError, LOG(), MSG_TYPE_APPLY, MSG_TYPE_APPLY_CURSED, NDI_NAVY, NDI_UNIQUE, object_free(), object_remove(), PLAYER, player_unready_range_ob(), spell, and object::type.
Referenced by cfapi_object_forget_spell(), command_forget_spell(), and spellbook_type_apply().
Here is the call graph for this function:
Here is the caller graph for this function:| void do_goto | ( | object * | op, |
| const char * | name, | ||
| int | x, | ||
| int | y | ||
| ) |
Definition at line 151 of file c_move.cpp.
References add_string(), enter_exit(), EXIT_PATH, EXIT_X, EXIT_Y, FREE_OBJ_NO_DESTROY_CALLBACK, object::map, name, object::name, object_free(), and object_new().
Referenced by command_goto().
Here is the call graph for this function:
Here is the caller graph for this function:Player is trying to harvest something.
| pl | player trying to harvest. |
| dir | direction. |
| skill | skill being used. |
In the past, things were made harvestable by adding randomitems. This is not ideal, because randomitems are treasurelist-generated on map load, which means that if common items (e.g. mountains) are harvestable, then we have to do a lot of extra work generating junk that probably nobody will use.
Instead of doing that, check for a harvestitems field. The value will be used as the name of a treasurelist and we only generate it when it is being harvested.
We still have to keep the old way of treasurelist harvestables working, even though this can be much slower.
Definition at line 2260 of file c_misc.cpp.
References object::carrying, change_exp(), object::chosen_skill, create_treasure(), mapstruct::difficulty, draw_ext_info_format(), object::env, find_treasurelist(), FLAG_MONSTER, FOR_INV_FINISH, FOR_INV_PREPARE, FOR_MAP_FINISH, FOR_MAP_PREPARE, is_valid_types_gen::found, FREE_OBJ_FREE_INVENTORY, freearr_x, freearr_y, get_map_flags(), get_weight_limit(), i18n(), INS_BELOW_ORIGINATOR, IS_PLAYER(), level, llevError, LOG(), LOOK_OBJ, object::map, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, object::name, NDI_WHITE, object::nrof, object_create_arch(), object_find_free_spot(), object_free(), object_get_value(), object_insert_in_map_at(), object_insert_in_ob(), object_remove(), object_set_value(), object_split(), object_value_set(), P_OUT_OF_MAP, QUERY_FLAG, random_roll(), rndm(), SIZEOFFREE, SK_EXP_ADD_SKILL, object::skill, skill, speed, object::speed, object::speed_left, sstring, object::stats, living::Str, t, try_find_archetype(), object::weight, object::x, and object::y.
Here is the call graph for this function:| void do_hidden_move | ( | object * | op | ) |
For hidden creatures - a chance of becoming 'unhidden' every time they move - as we subtract off 'invisibility' AND, for players, if they move into a ridiculously unhideable spot (surrounded by clear terrain in broad daylight).
-b.t.
| op | object moving. |
Definition at line 4060 of file player.cpp.
References calc_skill_exp(), change_exp(), object::contr, mapstruct::difficulty, draw_ext_info, hide, hideability(), object::invisible, object::level, make_visible(), object::map, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, NDI_UNIQUE, object_find_by_type_subtype(), PLAYER, PREFER_LOW, random_roll(), player::run_on, SK_HIDING, SKILL, object::skill, and object::type.
Referenced by face_player(), monster_move(), and move_player().
Here is the call graph for this function:
Here is the caller graph for this function:Actually makes op learn spell.
Informs player of new spell and binding.
| op | player who'll learn the spell. |
| spell | spell to learn. |
| special_prayer | 1 for god-given prayer, 0 else. |
Definition at line 146 of file apply.cpp.
References check_spell_known(), object::contr, draw_ext_info_format(), esrv_add_spells(), FLAG_STARTEQUIP, llevError, LOG(), MSG_TYPE_APPLY, MSG_TYPE_APPLY_SUCCESS, NDI_UNIQUE, object_copy(), object_insert_in_ob(), object_new(), play_sound_player_only(), PLAYER, QUERY_FLAG, SET_FLAG, SOUND_TYPE_SPELL, spell, and object::type.
Referenced by cfapi_object_learn_spell(), command_learn_spell_or_prayer(), dragon_ability_gain(), god_intervention(), and spellbook_type_apply().
Here is the call graph for this function:
Here is the caller graph for this function:Main skills use function-similar in scope to cast_spell().
We handle all requests for skill use outside of some combat here. We require a separate routine outside of fire() so as to allow monsters to utilize skills.
This is changed (2002-11-30) from the old method that returned exp - no caller needed that info, but it also prevented the callers from know if a skill was actually used, as many skills don't give any exp for their direct use (eg, throwing).
Gives experience if appropriate.
| op | The object actually using the skill |
| part | actual part using the skill, used by throwing for monsters |
| skill | The skill used by op |
| dir | The direction in which the skill is used |
| string | A parameter string, necessary to use some skills |
| 0 | skill failure. |
| 1 | use of the skill was successful. |
Definition at line 443 of file skill_util.cpp.
References apply_anim_suffix(), attack_hth(), attack_melee_weapon(), CLEAR_FLAG, object::contr, do_skill_cb_data::dir, do_skill_cb(), draw_ext_info, find_traps(), fix_object(), FLAG_APPLIED, give_skill_by_name(), hide, jump(), llevError, LOG(), meditate(), MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, object_find_by_type_and_skill(), do_skill_cb_data::op, do_skill_cb_data::part, pick_lock(), PLAYER, player_start_repeat(), pray(), QUERY_FLAG, remove_trap(), player::repeat_func_data, SET_FLAG, shop_describe(), singing(), SK_AIR_MAGIC, SK_ALCHEMY, SK_BARGAINING, SK_BOWYER, SK_CLAWING, SK_CLIMBING, SK_DET_CURSE, SK_DET_MAGIC, SK_DISARM_TRAPS, SK_EARTH_MAGIC, SK_EVOCATION, SK_FIND_TRAPS, SK_FIRE_MAGIC, SK_FLAME_TOUCH, SK_HARVESTING, SK_HIDING, SK_INSCRIPTION, SK_JEWELER, SK_JUMPING, SK_KARATE, SK_LEVITATION, SK_LITERACY, SK_LOCKPICKING, SK_MEDITATION, SK_MISSILE_WEAPON, SK_ONE_HANDED_WEAPON, SK_ORATORY, SK_PRAYING, SK_PUNCHING, SK_PYROMANCY, SK_SET_TRAP, SK_SINGING, SK_SMITHERY, SK_SORCERY, SK_STEALING, SK_SUMMONING, SK_THAUMATURGY, SK_THROWING, SK_TWO_HANDED_WEAPON, SK_USE_MAGIC_ITEM, SK_WATER_MAGIC, SK_WOODSMAN, SK_WRAITH_FEED, SKILL, skill, skill_ident(), skill_throw(), steal(), object::type, use_alchemy(), use_oratory(), and write_on_item().
Referenced by do_skill_by_number(), do_skill_cb(), fire(), monster_use_skill(), player_attack_door(), and use_skill().
Here is the call graph for this function:
Here is the caller graph for this function:| void do_some_living | ( | object * | op | ) |
Regenerate hp/sp/gr, decreases food.
This only works for players. Will grab food if needed, or kill player.
| op | player to regenerate for. |
Definition at line 3299 of file player.cpp.
References object::contr, living::food, player::gen_hp, player::gen_sp, living::maxhp, living::maxsp, ST_PLAYING, player::state, and object::stats.
Referenced by command_possess(), and process_players1().
Here is the caller graph for this function:| void dragon_ability_gain | ( | object * | who, |
| int | atnr, | ||
| int | level | ||
| ) |
When a dragon-player gains a new stage of evolution, he gets some treasure.
| who | the dragon player. |
| atnr | the attack-number of the ability focus. |
| level | ability level. |
Definition at line 365 of file main.cpp.
References object::anim_speed, animate_object(), object::animation, arch_to_object(), AT_PHYSICAL, ATNR_COLD, ATNR_ELECTRICITY, ATNR_FIRE, ATNR_POISON, object::attacktype, buf, check_spell_known(), archetype::clone, object::direction, do_learn_spell(), draw_ext_info, draw_ext_info_format(), esrv_send_item(), object::face, find_skill_by_name(), find_treasurelist(), FLAG_SEE_IN_DARK, FLAG_STEALTH, FLAG_XRAYS, FORCE, HUGE_BUF, object::inv, object::invisible, treasure::item, treasurelist::items, object::last_anim, level, llevDebug, LOG(), treasure::magic, MAX_BUF, object::msg, MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_RACE, MSG_TYPE_ITEM, MSG_TYPE_ITEM_ADD, name, object::name, NDI_BLUE, NDI_UNIQUE, treasure::next, NRSPELLPATHS, object_find_by_arch_name(), object_insert_in_ob(), object::path_attuned, PLAYER, QUERY_FLAG, query_short_name(), SET_FLAG, SK_CLAWING, object::skill, SKILL_TOOL, SPELL, SPELLBOOK, spellpathnames, object::state, object::subtype, and object::type.
Referenced by dragon_level_gain().
Here is the call graph for this function: