Crossfire Server, Branches 1.12
R18729
|
#include <global.h>
#include <object.h>
#include <sproto.h>
#include <living.h>
#include <skills.h>
#include <spells.h>
#include <book.h>
Go to the source code of this file.
Functions | |
static int | adj_stealchance (object *op, object *victim, int roll) |
static int | attempt_hide (object *op, object *skill) |
static int | attempt_jump (object *pl, int dir, int spaces, object *skill) |
static int | attempt_pick_lock (object *door, object *pl, object *skill) |
static int | attempt_steal (object *op, object *who, object *skill) |
static int | do_skill_detect_curse (object *pl, object *skill) |
static int | do_skill_detect_magic (object *pl, object *skill) |
static int | do_skill_ident (object *pl, int obj_class, object *skill) |
static int | do_skill_ident2 (object *tmp, object *pl, int obj_class, object *skill) |
static int | do_throw (object *op, object *part, object *toss_item, int dir, object *skill) |
static object * | find_throw_ob (object *op, const char *request) |
int | find_traps (object *pl, object *skill) |
int | hide (object *op, object *skill) |
int | jump (object *pl, int dir, object *skill) |
static object * | make_throw_ob (object *orig) |
void | meditate (object *pl, object *skill) |
int | pick_lock (object *pl, int dir, object *skill) |
int | pray (object *pl, object *skill) |
int | remove_trap (object *op, object *skill) |
int | singing (object *pl, int dir, object *skill) |
int | skill_ident (object *pl, object *skill) |
int | skill_throw (object *op, object *part, int dir, const char *params, object *skill) |
int | steal (object *op, int dir, object *skill) |
static void | stop_jump (object *pl) |
int | use_oratory (object *pl, int dir, object *skill) |
static int | write_note (object *pl, object *item, const char *msg, object *skill) |
int | write_on_item (object *pl, const char *params, object *skill) |
static int | write_scroll (object *pl, object *scroll, object *skill) |
This file contains core skill handling.
Definition in file skills.c.
Computes stealing chance. Increased values indicate better attempts.
op | who is stealing. |
victim | who to steal from. |
roll | dice roll. |
Definition at line 57 of file skills.c.
References ARMOUR, obj::below, BODY_ARMS, obj::body_info, obj::body_used, BOW, draw_ext_info(), FLAG_APPLIED, FLAG_SLEEP, FLAG_UNAGGRESSIVE, GLOVES, obj::inv, obj::invisible, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, NDI_UNIQUE, PLAYER, QUERY_FLAG, SHIELD, obj::type, WEAPON, and obj::weight.
Referenced by attempt_steal().
Someone is trying to hide. The user becomes undetectable (not just 'invisible') for a short while (success and duration dependant on player SK_level, dexterity, charisma, and map difficulty). Players have a good chance of becoming 'unhidden' if they move and like invisiblity will be come visible if they attack Implemented by b.t. (thoma) July 7, 1995 - made hiding possible for monsters. -b.t. s@as tro.p su.e du
op | living trying to hide. |
skill | hiding skill. |
0 | op couldn't hide. |
1 | op successfully hide. |
Definition at line 467 of file skills.c.
References obj::contr, liv::Dex, die_roll(), mapdef::difficulty, obj::hide, hideability(), obj::invisible, obj::level, obj::map, PLAYER, PREFER_LOW, stand_near_hostile(), obj::stats, pl::tmp_invis, and obj::type.
Referenced by hide().
Someone is trying to jump.
pl | living trying to jump. |
dir | direction to jump in. |
spaces | distance to jump. |
skill | jumping skill. |
Definition at line 554 of file skills.c.
References obj::above, calc_skill_exp(), obj::contr, draw_ext_info(), draw_ext_info_format(), esrv_map_scroll(), obj::facing, FLAG_MONSTER, FLAG_WIZ, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, GET_MAP_OB, pl::hidden, obj::map, MOVE_FLY_LOW, obj::move_on, obj::move_type, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, obj::name, NDI_UNIQUE, OB_TYPE_MOVE_BLOCK, P_OUT_OF_MAP, pl::party, PLAYER, QUERY_FLAG, remove_ob(), skill_attack(), pl::socket, stop_jump(), obj::type, obj::x, and obj::y.
Referenced by jump().
Attempt to pick a lock. Handles traps.
door | lock to pick. |
pl | player picking. |
skill | locking skill. |
0 | no lock was picked. |
1 | door was locked. |
Definition at line 366 of file skills.c.
References liv::Dex, die_roll(), mapdef::difficulty, obj::inv, obj::level, obj::map, PREFER_LOW, remove_door(), RUNE, spring_trap(), obj::stats, TRAP, and obj::type.
Referenced by pick_lock().
Steal objects. When stealing: dependent on the intelligence/wisdom of whom you're stealing from (op in attempt_steal), offset by your dexterity and skill at stealing. They may notice your attempt, whether successful or not.
op | target (person being pilfered). |
who | person doing the stealing. |
skill | stealing skill object. |
0 | nothing was stolen. |
1 | something was stolen. |
Definition at line 127 of file skills.c.
References adj_stealchance(), can_detect_enemy(), CLEAR_FLAG, liv::Dex, die_roll(), draw_ext_info(), draw_ext_info_format(), EXPERIENCE, FLAG_APPLIED, FLAG_INV_LOCKED, FLAG_NO_STEAL, FLAG_STARTEQUIP, FLAG_UNAGGRESSIVE, FLAG_WAS_WIZ, FLAG_WIZ, obj::hide, liv::Int, obj::inv, obj::invisible, obj::level, make_visible(), MAX_BUF, MAX_STAT, MSG_TYPE_ITEM, MSG_TYPE_ITEM_REMOVE, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_VICTIM, MSG_TYPE_VICTIM_STEAL, NDI_UNIQUE, Settings::no_player_stealing, npc_call_help(), pick_up(), PLAYER, PREFER_LOW, QUERY_FLAG, query_name(), random_roll(), SET_FLAG, settings, snprintf(), SPELL, obj::stats, obj::type, was_destroyed, and liv::Wis.
Referenced by steal().
Check for cursed object with the 'detect curse' skill.
pl | player detecting. |
skill | detect skill object. |
Definition at line 686 of file skills.c.
References obj::above, obj::below, calc_skill_exp(), can_pick(), esrv_update_item(), FLAG_CURSED, FLAG_DAMNED, FLAG_IDENTIFIED, FLAG_IS_CAULDRON, FLAG_KNOWN_CURSED, GET_MAP_OB, obj::inv, obj::invisible, obj::item_power, obj::level, obj::map, QUERY_FLAG, SET_FLAG, UPD_FLAGS, obj::x, and obj::y.
Referenced by skill_ident().
Check for magic object with the 'detect magic' skill.
pl | player detecting. |
skill | detect skill object. |
Definition at line 727 of file skills.c.
References obj::above, obj::below, calc_skill_exp(), can_pick(), esrv_update_item(), FLAG_IDENTIFIED, FLAG_KNOWN_MAGICAL, GET_MAP_OB, obj::inv, obj::invisible, is_magical(), obj::item_power, obj::level, obj::map, QUERY_FLAG, SET_FLAG, UPD_FLAGS, obj::x, and obj::y.
Referenced by skill_ident().
Workhorse for skill_ident() -b.t.
pl | player identifying. |
obj_class | type of objects to identify. |
skill | skill to give experience to. |
Definition at line 821 of file skills.c.
References obj::above, obj::below, can_see_monsterP(), do_skill_ident2(), freearr_x, freearr_y, get_map_flags(), GET_MAP_OB, obj::inv, obj::level, obj::map, P_OUT_OF_MAP, obj::x, and obj::y.
Referenced by skill_ident().
Helper function for do_skill_ident, so that we can loop over inventory AND objects on the ground conveniently.
tmp | object to try to identify. |
pl | object identifying. |
obj_class | object type to identify. |
skill | identification skill. |
Definition at line 771 of file skills.c.
References calc_skill_exp(), die_roll(), draw_ext_info_format(), FLAG_IDENTIFIED, FLAG_NO_SKILL_IDENT, identify(), liv::Int, obj::invisible, obj::item_power, obj::level, obj::magic, MAX_BUF, obj::msg, MSG_TYPE_ITEM, MSG_TYPE_ITEM_INFO, MSG_TYPE_SKILL, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, need_identify(), ob_describe(), PLAYER, PREFER_LOW, QUERY_FLAG, rndm(), SET_FLAG, obj::stats, and obj::type.
Referenced by do_skill_ident().
|
static |
Op throws any object toss_item. This code was borrowed from fire_bow.
op | living thing throwing something. |
part | part of op throwing. |
toss_item | item thrown. |
dir | direction to throw. |
skill | throwing skill. |
0 | skill use failed. |
1 | skill was successfully used. |
Definition at line 1906 of file skills.c.
References add_string(), obj::carrying, cast_dust(), obj::count, liv::dam, dam_bonus, liv::Dex, dex_bonus, obj::direction, draw_ext_info(), draw_ext_info_format(), EVENT_THROW, execute_event(), FLAG_IS_THROWN, FLAG_STARTEQUIP, liv::food, free_string(), freearr_x, freearr_y, GET_ANIM_ID, get_map_flags(), GET_MAP_MOVE_BLOCK, get_split_ob(), insert_ob_in_map(), insert_ob_in_ob(), obj::inv, obj::last_sp, obj::level, llevDebug, LOG(), M_CLOTH, M_GLASS, M_LEATHER, M_ORGANIC, M_PAPER, obj::magic, make_throw_ob(), obj::map, obj::material, MAX_BUF, max_carry, MAX_STAT, MIN, MOVE_FLY_LOW, obj::move_on, obj::move_type, MOVE_WALK, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, obj::name, NDI_UNIQUE, NUM_ANIMATIONS, ob_process(), P_OUT_OF_MAP, PLAYER, POT_DUST, POTION, QUERY_FLAG, query_name(), remove_ob(), SCRIPT_FIX_ACTIVATOR, SET_ANIMATION, set_owner(), obj::skill, obj::speed, speed_bonus, obj::speed_left, obj::stats, liv::Str, obj::subtype, thaco_bonus, obj::type, update_ob_speed(), was_destroyed, liv::wc, obj::weight, weight_limit, obj::x, and obj::y.
Referenced by skill_throw().
Find an object to throw. If we request an object, then we search for it in the inventory of the owner (you've got to be carrying something in order to throw it!). If we didnt request an object, then the top object in inventory (that is "throwable", ie no throwing your skills away!) is the object of choice. Also check to see if object is 'throwable' (ie not applied cursed obj, worn, etc).
op | object wishing to throw. |
request | requested item to throw. |
Definition at line 1777 of file skills.c.
References AP_NO_MERGE, AP_UNAPPLY, apply_special(), obj::below, draw_ext_info_format(), find_marked_object(), FLAG_APPLIED, FLAG_CURSED, FLAG_DAMNED, FLAG_INV_LOCKED, FLAG_UNPAID, obj::inv, obj::invisible, llevError, LOG(), MAX_BUF, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, obj::name, NDI_UNIQUE, QUERY_FLAG, query_name(), obj::type, and WEAPON.
Referenced by skill_throw().
Checks for traps on the spaces around the player or in certain objects.
pl | player searching. |
skill | find trap skill object. |
Definition at line 1207 of file skills.c.
References obj::above, obj::below, calc_skill_exp(), liv::Cha, draw_ext_info(), FLAG_MONSTER, freearr_x, freearr_y, get_map_flags(), GET_MAP_OB, obj::inv, obj::map, MSG_TYPE_SKILL, MSG_TYPE_SKILL_SUCCESS, NDI_BLACK, obj::owner, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, RUNE, obj::stats, TRAP, trap_see(), trap_show(), obj::type, obj::x, and obj::y.
Referenced by do_skill().
Main hide handling.
op | living trying to hide. |
skill | hiding skill. |
Definition at line 498 of file skills.c.
References attempt_hide(), calc_skill_exp(), draw_ext_info(), FLAG_MAKE_INVIS, obj::hide, obj::invisible, obj::level, make_visible(), MSG_TYPE_ATTRIBUTE, MSG_TYPE_ATTRIBUTE_GOOD_EFFECT_END, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, PLAYER, QUERY_FLAG, obj::type, UP_OBJ_FACE, and update_object().
Referenced by do_hidden_move(), and do_skill().
Jump skill handling. This is both a new type of movement for player/monsters and an attack as well. Perhaps we should allow more spaces based on level, eg, level 50 jumper can jump several spaces?
pl | object jumping. |
dir | direction to jump to. |
skill | jumping skill. |
Definition at line 651 of file skills.c.
References attempt_jump(), obj::carrying, liv::Dex, draw_ext_info(), obj::level, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, NDI_UNIQUE, obj::stats, and liv::Str.
Referenced by do_skill().
We construct the 'carrier' object in which we will insert the object that is being thrown. This combination becomes the 'thrown object'. -b.t.
orig | object to wrap. |
Definition at line 1865 of file skills.c.
References CLEAR_FLAG, copy_object(), liv::dam, FLAG_APPLIED, FLAG_CHANGING, get_object(), insert_ob_in_ob(), llevError, LOG(), QUERY_FLAG, obj::stats, THROWN_OBJ, and obj::type.
Referenced by do_throw().
Meditation skill handling.
This skill allows the player to regain a few sp or hp for a brief period of concentration. The amount of time needed to concentrate and the # of points regained is dependant on the level of the user.
Depending on the level, the player can wear armour or not.
pl | livng meditating, should be a player. |
skill | meditation skill. |
Definition at line 1390 of file skills.c.
References ARMOUR, obj::below, BOOTS, draw_ext_info(), FLAG_APPLIED, FLAG_READY_WEAPON, GLOVES, HELMET, liv::hp, obj::inv, obj::last_heal, obj::last_sp, obj::level, liv::maxhp, liv::maxsp, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_SUCCESS, NDI_BLACK, NDI_UNIQUE, PLAYER, QUERY_FLAG, SHIELD, liv::sp, obj::stats, and obj::type.
Referenced by do_skill().
Lock pick handling.
Implementation by bt. (thoma) monster implementation 7-7-95 by bt. s@as tro.p su.e du
pl | player picking the lock. |
dir | direction to pick. |
skill | lock picking skill. |
Definition at line 400 of file skills.c.
References obj::above, attempt_pick_lock(), calc_skill_exp(), DOOR, draw_ext_info(), obj::facing, freearr_x, freearr_y, GET_MAP_OB, LOCKED_DOOR, obj::map, obj::move_block, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, out_of_map(), obj::type, obj::x, and obj::y.
Referenced by do_skill().
Praying skill handling.
When this skill is called from do_skill(), it allows the player to regain lost grace points at a faster rate. -b.t.
This always returns 0 - return value is used by calling function such that if it returns true, player gets exp in that skill. This the effect here can be done on demand, we probably don't want to give infinite exp by returning true in any cases.
pl | object praying, should be a player. |
skill | praying skill. |
Definition at line 1341 of file skills.c.
References obj::below, draw_ext_info(), liv::grace, HOLY_ALTAR, obj::last_grace, MAX_BUF, liv::maxgrace, MSG_TYPE_SKILL, MSG_TYPE_SKILL_SUCCESS, obj::name, NDI_BLACK, obj::other_arch, PLAYER, pray_at_altar(), snprintf(), obj::stats, and obj::type.
Referenced by do_skill().
This skill will disarm any previously discovered trap. the algorithm is based (almost totally) on the old command_disarm() - b.t.
op | player disarming. Must be on a map. |
skill | disarming skill. |
Definition at line 1272 of file skills.c.
References obj::above, obj::below, calc_skill_exp(), liv::Cha, liv::exp, FLAG_MONSTER, freearr_x, freearr_y, get_map_flags(), GET_MAP_OB, obj::inv, obj::level, obj::map, obj::owner, P_OUT_OF_MAP, PLAYER, QUERY_FLAG, RUNE, obj::stats, TRAP, trap_disarm(), trap_show(), obj::type, obj::x, and obj::y.
Referenced by do_skill().
Singing skill handling. This skill allows the player to pacify nearby creatures. There are few limitations on who/what kind of non-player creatures that may be pacified. Right now, a player may pacify creatures which have Int == 0. In this routine, once successfully pacified the creature gets Int=1. Thus, a player may only pacify a creature once. BTW, I appologize for the naming of the skill, I couldnt think of anything better! -b.t.
pl | player singing. |
dir | direction to sing in. |
skill | singing skill object. |
Definition at line 1123 of file skills.c.
References obj::above, calc_skill_exp(), liv::Cha, draw_ext_info_format(), FLAG_FRIENDLY, FLAG_HITBACK, FLAG_MONSTER, FLAG_NO_STEAL, FLAG_SPLITTING, FLAG_UNAGGRESSIVE, FLAG_UNDEAD, freearr_x, freearr_y, get_map_flags(), GET_MAP_OB, obj::head, liv::Int, obj::level, obj::map, MAX_BUF, MIN, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, P_IS_ALIVE, P_OUT_OF_MAP, PLAYER, PREFER_HIGH, QUERY_FLAG, query_name(), random_roll(), SET_FLAG, SIZEOFFREE, obj::stats, obj::type, obj::x, and obj::y.
Referenced by do_skill().
Main identification skill handling.
pl | player identifying. |
skill | identification skill. |
Definition at line 872 of file skills.c.
References AMULET, ARMOUR, ARROW, BOOK, BOOTS, BOW, BRACERS, CLOAK, CONTAINER, do_skill_detect_curse(), do_skill_detect_magic(), do_skill_ident(), draw_ext_info(), DRINK, FLESH, FOOD, GEM, GIRDLE, GLOVES, HELMET, HORN, INORGANIC, llevError, LOG(), MSG_TYPE_SKILL, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, PLAYER, POISON, POTION, RING, ROD, SCROLL, SHIELD, SK_ALCHEMY, SK_BOWYER, SK_DET_CURSE, SK_DET_MAGIC, SK_JEWELER, SK_LITERACY, SK_SMITHERY, SK_THAUMATURGY, SK_WOODSMAN, SPELLBOOK, obj::subtype, obj::type, WAND, and WEAPON.
Referenced by do_skill().
Throwing skill handling.
op | object throwing. |
part | actual part of op throwing. |
dir | direction to throw into. |
params | optional message, used to find object to throw. |
skill | throwing skill. |
0 | skill use failed. |
1 | skill was successfully used. |
Definition at line 2181 of file skills.c.
References do_throw(), find_mon_throw_ob(), find_throw_ob(), PLAYER, and obj::type.
Referenced by do_skill().
Main stealing function.
op | thief. |
dir | direction to steal from. |
skill | stealing skill. |
Definition at line 290 of file skills.c.
References obj::above, obj::attack_movement, attempt_steal(), obj::below, calc_skill_exp(), obj::contr, FLAG_FRIENDLY, FLAG_MONSTER, FLAG_WIZ, freearr_x, freearr_y, get_map_flags(), GET_MAP_MOVE_BLOCK, GET_MAP_OB, get_owner(), obj::head, pl::hidden, obj::map, OB_TYPE_MOVE_BLOCK, P_IS_ALIVE, P_OUT_OF_MAP, PETMOVE, PLAYER, QUERY_FLAG, obj::type, obj::x, and obj::y.
Referenced by do_skill().
|
static |
End of jump. Restore the map.
pl | player. |
Definition at line 536 of file skills.c.
References fix_object(), insert_ob_in_map(), and obj::map.
Referenced by attempt_jump().
Oratory skill handling. Players using this skill can 'charm' a monster – into working for them. It can only be used on non-special (see below) 'neutral' creatures. -b.t. (thoma) s@as tro.p su.e du
pl | player trying to convince a monster. |
dir | direction to orate in. |
skill | oratory skill object. |
Definition at line 976 of file skills.c.
References obj::above, add_friendly_object(), obj::attack_movement, calc_skill_exp(), liv::Cha, CLEAR_FLAG, draw_ext_info(), draw_ext_info_format(), liv::exp, FLAG_FRIENDLY, FLAG_MONSTER, FLAG_UNAGGRESSIVE, FREE_AND_COPY, freearr_x, freearr_y, get_map_flags(), GET_MAP_OB, get_owner(), obj::head, liv::Int, obj::level, obj::map, MAX_BUF, obj::more, obj::msg, MSG_TYPE_SKILL, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, P_IS_ALIVE, P_OUT_OF_MAP, PETMOVE, PLAYER, PREFER_HIGH, PREFER_LOW, QUERY_FLAG, query_name(), random_roll(), remove_friendly_object(), SET_FLAG, set_owner(), obj::skill, obj::stats, obj::type, obj::x, and obj::y.
Referenced by do_skill().
This routine allows players to inscribe messages in ordinary 'books' (anything that is type BOOK). b.t.
pl | player writing. |
item | book to write into. |
msg | message to write. |
skill | writing skill object. |
Definition at line 1451 of file skills.c.
References add_string(), BOOK, BOOK_BUF, book_overflow(), copy_object(), decrease_ob, draw_ext_info(), draw_ext_info_format(), EVENT_TRIGGER, execute_event(), free_string(), get_object(), insert_ob_in_ob(), obj::msg, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, NDI_UNIQUE, obj::nrof, query_short_name(), SCRIPT_FIX_ALL, obj::skill, snprintf(), strcasestr_local(), and obj::type.
Referenced by write_on_item().
Writing skill handling.
Wrapper for write_note() and write_scroll().
pl | player writing. |
params | message to inscribe. |
skill | writing skill. |
Definition at line 1695 of file skills.c.
References BOOK, archt::clone, draw_ext_info(), draw_ext_info_format(), find_marked_object(), find_skill_by_name(), FLAG_BLIND, FLAG_UNPAID, FLAG_WIZ, get_archetype_by_type_subtype(), MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_MISSING, NDI_UNIQUE, PLAYER, QUERY_FLAG, SCROLL, SK_LITERACY, SKILL, obj::skill, obj::type, write_note(), and write_scroll().
Referenced by do_skill(), and inscribe_scroll_cmd().
This routine allows players to inscribe spell scrolls of spells which they know. Backfire effects are possible with the severity of the backlash correlated with the difficulty of the scroll that is attempted. -b.t. thoma s@as tro.p su.e du
pl | player writing a scroll. |
scroll | object to write into. |
skill | writing skill. |
Definition at line 1532 of file skills.c.
References Settings::allow_denied_spells_writing, obj::arch, calc_skill_exp(), archt::clone, confuse_living(), obj::contr, copy_object(), decrease_ob, drain_specific_stat(), draw_ext_info(), draw_ext_info_format(), EVENT_TRIGGER, execute_event(), liv::exp, find_random_spell_in_ob(), FLAG_CONFUSED, free_object(), get_object(), liv::grace, insert_ob_in_ob(), liv::Int, obj::inv, obj::level, manual_apply(), MAX, MAX_BUF, MSG_TYPE_SKILL, MSG_TYPE_SKILL_ERROR, MSG_TYPE_SKILL_FAILURE, MSG_TYPE_SKILL_SUCCESS, obj::name, NDI_UNIQUE, obj::nrof, obj::path_attuned, obj::path_denied, obj::path_repelled, PREFER_HIGH, PREFER_LOW, QUERY_FLAG, query_name(), random_roll(), range_magic, pl::ranges, remove_ob(), SCROLL, settings, liv::sp, SP_level_spellpoint_cost(), SPELL_GRACE, SPELL_MANA, obj::stats, obj::type, and obj::value.
Referenced by write_on_item().