#include "hack.h"
#include "edog.h"
Defines | |
#define | quest_arti_hits_leader(obj, mon) (obj->oartifact && is_quest_artifact(obj) && (mon->data->msound == MS_LEADER)) |
Functions | |
STATIC_DCL int | FDECL (throw_obj,(struct obj *, int)) |
STATIC_DCL void | NDECL (autoquiver) |
STATIC_DCL int | FDECL (gem_accept,(struct monst *, struct obj *)) |
STATIC_DCL void | FDECL (tmiss,(struct obj *, struct monst *)) |
STATIC_DCL int | FDECL (throw_gold,(struct obj *)) |
STATIC_DCL void | FDECL (check_shop_obj,(struct obj *, XCHAR_P, XCHAR_P, BOOLEAN_P)) |
STATIC_DCL void | FDECL (breakobj,(struct obj *, XCHAR_P, XCHAR_P, BOOLEAN_P, BOOLEAN_P)) |
STATIC_DCL void | FDECL (breakmsg,(struct obj *, BOOLEAN_P)) |
STATIC_DCL boolean | FDECL (toss_up,(struct obj *, BOOLEAN_P)) |
STATIC_DCL boolean | FDECL (throwing_weapon,(struct obj *)) |
STATIC_DCL void | FDECL (sho_obj_return_to_u,(struct obj *obj)) |
STATIC_DCL boolean | FDECL (mhurtle_step,(genericptr_t, int, int)) |
STATIC_OVL int | throw_obj (struct obj *obj, int shotlimit) |
int | dothrow () |
static void | autoquiver () |
int | dofire () |
void | hitfloor (struct obj *obj) |
boolean | walk_path (coord *src_cc, coord *dest_cc, check_proc, genericptr_t arg) |
boolean | hurtle_step (genericptr_t arg, int x, int y) |
STATIC_OVL boolean | mhurtle_step (genericptr_t arg, int x, int y) |
void | hurtle (int dx, int dy, int range, boolean verbose) |
void | mhurtle (struct monst *mon, int dx, int dy, int range) |
STATIC_OVL void | check_shop_obj (struct obj *obj, xchar x, xchar y, boolean broken) |
STATIC_OVL boolean | toss_up (struct obj *obj, boolean hitsroof) |
STATIC_OVL boolean | throwing_weapon (struct obj *obj) |
STATIC_OVL void | sho_obj_return_to_u (struct obj *obj) |
void | throwit (struct obj *obj, long wep_mask, boolean twoweap) |
int | omon_adj (struct monst *mon, struct obj *obj, boolean mon_notices) |
STATIC_OVL void | tmiss (struct obj *obj, struct monst *mon) |
int | thitmonst (struct monst *mon, struct obj *obj) |
STATIC_OVL int | gem_accept (struct monst *mon, struct obj *obj) |
int | hero_breaks (struct obj *obj, xchar x, xchar y, boolean from_invent) |
int | breaks (struct obj *obj, xchar x, xchar y) |
STATIC_OVL void | breakobj (struct obj *obj, xchar x, xchar y, boolean hero_caused, boolean from_invent) |
boolean | breaktest (struct obj *obj) |
STATIC_OVL void | breakmsg (struct obj *obj, boolean in_view) |
STATIC_OVL int | throw_gold (struct obj *obj) |
Variables | |
static NEARDATA const char | toss_objs [] |
static NEARDATA const char | bullets [] |
struct obj * | thrownobj = 0 |
boolean | notonhead |
#define quest_arti_hits_leader | ( | obj, | |
mon | |||
) | (obj->oartifact && is_quest_artifact(obj) && (mon->data->msound == MS_LEADER)) |
Referenced by thitmonst().
static void autoquiver | ( | ) | [static] |
References ammo_and_launcher, FLINT, GEM_CLASS, GLASS, invent, is_ammo, is_missile, obj::nobj, obj::oartifact, objects, obj::oclass, otmp, obj::otyp, obj::owornmask, P_DAGGER, ROCK, setuqwep(), throwing_weapon(), uquiver, uslinging, uswapwep, uwep, and WEAPON_CLASS.
Referenced by dofire().
References ACID_VENOM, BLINDING_VENOM, CREAM_PIE, CRYSTAL_BALL, CRYSTAL_PLATE_MAIL, Doname2(), EGG, EXPENSIVE_CAMERA, LENSES, MELON, MIRROR, pline(), POT_WATER, POTION_CLASS, RING_CLASS, something, and WAND_CLASS.
Referenced by breaks(), hero_breaks(), throwit(), and toss_up().
STATIC_OVL void breakobj | ( | struct obj * | obj, |
xchar | x, | ||
xchar | y, | ||
boolean | hero_caused, | ||
boolean | from_invent | ||
) |
References A_WIS, AM_CHAOTIC, AM_MASK, AM_NONE, angry_priest(), body_part(), breathless, change_luck(), check_shop_obj(), costly_spot(), create_camera_demon(), monst::data, delobj(), distu, EGG, exercise(), EXPENSIVE_CAMERA, EYE, eyecount, FALSE, haseyes, in_rooms(), inside_shop(), IS_ALTAR, Is_astralevel, levl, LOW_PM, make_angry_shk(), makeplural(), min, MIRROR, moves, NEARDATA, pline(), POT_BLOOD, POT_OIL, POT_VAMPIRE_BLOOD, POT_WATER, POTION_CLASS, potionbreathe(), shop_keeper(), SHOPBASE, splatter_burning_oil(), stolen_value(), TRUE, u, you::ushops, you::ux, you::uy, you::uz, and youmonst.
Referenced by breaks(), hero_breaks(), throwit(), and toss_up().
References Blind, breakmsg(), breakobj(), breaktest(), cansee, and FALSE.
Referenced by bhito(), hits_bars(), and scatter().
References ACID_VENOM, BLINDING_VENOM, CREAM_PIE, EGG, EXPENSIVE_CAMERA, GEM_CLASS, GLASS, MELON, obj_resists(), objects, POT_WATER, and POTION_CLASS.
Referenced by breaks(), hero_breaks(), hmon_hitmon(), ship_object(), throwit(), and toss_up().
References costly_spot(), FALSE, in_rooms(), monst::mx, monst::my, sellobj(), shop_keeper(), SHOPBASE, stolen_value(), subfrombill(), u, you::ushops, you::ux, and you::uy.
Referenced by breakobj(), gem_accept(), thitmonst(), and throwit().
int dofire | ( | ) |
References autoquiver(), flag::autoquiver, check_capacity(), monst::data, dothrow(), flags, multi, notake, prinv(), save_cm, throw_obj(), uquiver, and youmonst.
int dothrow | ( | ) |
References check_capacity(), monst::data, getobj(), multi, notake, save_cm, throw_obj(), uslinging, and youmonst.
Referenced by dofire().
STATIC_DCL void FDECL | ( | breakmsg | , |
(struct obj *, BOOLEAN_P) | |||
) |
STATIC_DCL int FDECL | ( | throw_gold | , |
(struct obj *) | |||
) |
STATIC_DCL void FDECL | ( | check_shop_obj | , |
(struct obj *, XCHAR_P, XCHAR_P, BOOLEAN_P) | |||
) |
STATIC_DCL boolean FDECL | ( | mhurtle_step | , |
(genericptr_t, int, int) | |||
) |
STATIC_DCL int FDECL | ( | throw_obj | , |
(struct obj *, int) | |||
) |
STATIC_DCL void FDECL | ( | breakobj | , |
(struct obj *, XCHAR_P, XCHAR_P, BOOLEAN_P, BOOLEAN_P) | |||
) |
References Blind, BUFSZ, change_luck(), check_shop_obj(), FALSE, GEMSTONE, Monnam(), mpickobj(), NEARDATA, objects, objclass::oc_uname, pline(), rloc(), rn2(), sgn(), Strcat, Strcpy, tele_restrict(), TRUE, align::type, u, you::ualign, and you::ushops.
Referenced by thitmonst().
References Blind, breakmsg(), breakobj(), breaktest(), and TRUE.
Referenced by bhito(), hitfloor(), hits_bars(), and kick_object().
void hitfloor | ( | struct obj * | obj ) |
References container_impact_dmg(), doaltarobj(), Doname2(), dropy(), FALSE, hero_breaks(), IS_ALTAR, IS_SOFT, levl, pline(), ship_object(), surface(), TRUE, u, you::ux, and you::uy.
Referenced by drop(), throwit(), and toss_up().
void hurtle | ( | int | dx, |
int | dy, | ||
int | range, | ||
boolean | verbose | ||
) |
References carried, change_luck(), hurtle_step(), multishot::i, In_sokoban, m_shot, multishot::n, nomul(), Punished, multishot::s, sgn(), surface(), TT_INFLOOR, TT_LAVA, TT_WEB, u, uball, you::ustuck, you::utrap, you::utraptype, you::ux, you::uy, you::uz, walk_path(), nhcoord::x, and nhcoord::y.
Referenced by dokick(), throwit(), and use_grapple().
boolean hurtle_step | ( | genericptr_t | arg, |
int | x, | ||
int | y | ||
) |
References a_monnam(), ARROW_TRAP, bad_rock(), bigmonst, BOULDER, closed_door(), monst::data, defsyms, delay_output, dotrap(), symdef::explanation, FALSE, FIRE_TRAP, flush_screen(), HOLE, in_out_region(), In_sokoban, inv_weight(), invent, IRONBARS, IS_ROCK, IS_TREE, isok(), KILLED_BY, levl, losehp(), m_at, MAGIC_PORTAL, may_passwall(), mon, newsym(), obj::ox, obj::oy, Passes_walls, PIT, pline(), rnd(), sobj_at(), SPIKED_PIT, t_at(), trap_to_defsym, TRAPDOOR, TRUE, u, you::ux, you::uy, you::uz, vision_recalc(), wakeup(), weight_cap(), trap::x, xname(), trap::y, and youmonst.
Referenced by hurtle(), and jump().
void mhurtle | ( | struct monst * | mon, |
int | dx, | ||
int | dy, | ||
int | range | ||
) |
References mhurtle_step(), mon, MZ_HUGE, sgn(), u, you::ustuck, walk_path(), nhcoord::x, and nhcoord::y.
Referenced by hmon_hitmon().
STATIC_OVL boolean mhurtle_step | ( | genericptr_t | arg, |
int | x, | ||
int | y | ||
) |
References FALSE, goodpos(), m_in_out_region(), mintrap(), mon, monst::mx, monst::my, newsym(), remove_monster(), set_apparxy(), and TRUE.
Referenced by mhurtle().
STATIC_DCL void NDECL | ( | autoquiver | ) |
References BOULDER, GEM_CLASS, HEAVY_IRON_BALL, hitval(), is_weptool, MZ_MEDIUM, obj::oclass, obj::otyp, rn2(), uball, and WEAPON_CLASS.
Referenced by drag_ball(), ohitmon(), and thitmonst().
STATIC_OVL void sho_obj_return_to_u | ( | struct obj * | obj ) |
References bhitpos, delay_output, DISP_END, DISP_FLASH, you::dx, you::dy, obj_to_glyph, tmp_at(), u, you::ux, you::uy, nhcoord::x, and nhcoord::y.
Referenced by thitmonst(), and throwit().
References A_DEX, A_STR, ACCFOOD, ACID_VENOM, ACURR, addinv(), ammo_and_launcher, BANANA, befriend_with_obj, bhitpos, BLINDING_VENOM, BOOMERANG, BOULDER, check_shop_obj(), CORPSE, CREAM_PIE, cutworm(), monst::data, delobj(), distmin(), dogfood(), EGG, ELVEN_BOW, encumber_msg(), exercise(), FALSE, find_mac(), finish_quest(), FOOD_CLASS, GAUNTLETS_OF_DEXTERITY, GAUNTLETS_OF_FUMBLING, GAUNTLETS_OF_POWER, gem_accept(), GEM_CLASS, greatest_erosion, HEAVY_IRON_BALL, hmon(), is_ammo, is_animal, is_elf, is_orc, is_unicorn, is_weptool, LEATHER_GLOVES, Luck, maybe_polyd, minstapetrify(), miss(), permonst::mlevel, mon_nam(), Monnam(), monnear(), mons, mpickobj(), obj::oartifact, obfree(), objects, oc_skill, omon_adj(), oresist_disintegration, obj::otyp, P_BOOMERANG, P_BOW, P_NONE, passive_obj(), pline(), PM_BABY_CROCODILE, PM_CAVEMAN, PM_CROCODILE, PM_ELF, PM_MONKEY, PM_RANGER, PM_ROGUE, PM_SAMURAI, PM_TOURIST, PM_WINTER_WOLF_CUB, POTION_CLASS, potionhit(), quest_arti_hits_leader, Race_if, rn2(), rnd(), rnl(), Role_if, s_suffix(), sho_obj_return_to_u(), obj::spe, spec_abon(), STRAT_WAITMASK, tamedog(), the(), throwing_weapon(), tmiss(), Tobjnam(), touch_petrifies, TOURIST, TRUE, u, uarmg, uball, you::uhitinc, you::ulevel, Upolyd, you::ushops, you::ustuck, uwep, you::ux, you::uy, wakeup(), WEAPON_CLASS, weapon_hit_bonus(), WEBB_DISINT, nhcoord::x, xname(), nhcoord::y, youmonst, your_race, and YUMI.
Referenced by kick_object(), throwit(), use_grapple(), and use_pole().
STATIC_OVL int throw_gold | ( | struct obj * | obj ) |
References ACURRSTR, add_to_minv(), bhit(), bhitpos, body_part(), flag::botl, ceiling(), closed_door(), monst::data, dealloc_obj(), you::dx, you::dy, you::dz, FALSE, FDECL, flags, flooreffects(), freeinv(), ghitm(), HEAD, Is_airlevel, is_animal, Is_waterlevel, levl, monst::mgold, mon, mon_nam(), MONST_P, newsym(), OBJ_P, place_object(), pline(), obj::quan, sellobj(), ship_object(), stackobj(), surface(), THROWN_WEAPON, u, uarmh, you::ugold, Underwater, you::ushops, you::ustuck, you::ux, you::uy, you::uz, nhcoord::x, nhcoord::y, and ZAP_POS.
Referenced by throw_obj().
STATIC_OVL int throw_obj | ( | struct obj * | obj, |
int | shotlimit | ||
) |
References A_STR, ACURR, addinv(), ammo_and_launcher, an(), ART_MJOLLNIR, body_part(), flag::botl, BOULDER, canletgo(), COIN_CLASS, Confusion, CORPSE, monst::data, dealloc_obj(), you::dx, you::dy, you::dz, ELVEN_ARROW, ELVEN_BOW, FALSE, flags, freeinv(), getdir(), HAND, multishot::i, killer_buf, m_shot, permonst::mname, mons, multishot::n, multishot::o, objects, ORCISH_ARROW, ORCISH_BOW, otmp, obj::otyp, obj::owornmask, P_DAGGER, P_DART, P_EXPERT, P_SHURIKEN, P_SKILL, P_SKILLED, pline(), PM_ELF, PM_ORC, PM_RANGER, PM_ROGUE, PM_SAMURAI, Race_switch, remove_worn_item(), rnd(), Role_switch, multishot::s, singular(), splitobj(), Sprintf, Stone_resistance, STR19, STRANGE_OBJECT, Stunned, The(), throw_gold(), throwit(), throws_rocks, touch_petrifies, TRUE, you::twoweap, u, u_wipe_engr(), uarmg, you::ugold, uquiver, uwep, weapon_type(), welded(), weldmsg(), xname(), YA, youmonst, and YUMI.
Referenced by dofire(), and dothrow().
References AKLYS, is_blade, is_missile, is_spear, is_sword, objects, PIERCE, and WAR_HAMMER.
Referenced by autoquiver(), thitmonst(), and throwit().
References A_CON, A_DEX, ACURRSTR, addinv(), ammo_and_launcher, ARM, ART_MJOLLNIR, artifact_hit(), bhit(), bhitpos, Blind, body_part(), BOOMERANG, boomhit(), BOULDER, breakmsg(), breakobj(), breaktest(), calc_capacity(), cansee, ceiling(), check_shop_obj(), Confusion, container_impact_dmg(), delay_output, DISP_END, DISP_FLASH, drop_ball(), dropy(), you::dx, you::dy, you::dz, encumber_msg(), exercise(), FALSE, FDECL, flooreffects(), FOOT, Fumbling, GEM_CLASS, Hallucination, HEAVY_IRON_BALL, hitfloor(), hot_pursuit(), hurtle(), in_rooms(), index, inside_shop(), Is_airlevel, is_ammo, is_pick, IS_SOFT, Is_waterlevel, KILLED_BY, KILLED_BY_AN, Levitation, levl, losehp(), m_at, makeplural(), you::mh, you::mhmax, mon, Monnam(), MONST_P, mpickobj(), monst::mx, monst::my, newsym(), obj_is_pname(), OBJ_MINVENT, obj_no_longer_held(), OBJ_P, obj_sheds_light(), obj_to_glyph, P_SKILL, P_UNSKILLED, place_object(), pline(), PM_VALKYRIE, rn2(), rnd(), rnf(), Role_if, setuwep(), setworn(), ship_object(), sho_obj_return_to_u(), SHOPBASE, SLT_ENCUMBER, snuff_candle(), Something, stackobj(), Stunned, the(), thitmonst(), throwing_weapon(), THROWN_WEAPON, tmp_at(), Tobjnam(), toss_up(), TRUE, TT_INFLOOR, you::twoweap, u, uball, you::uhp, you::uhpmax, Underwater, Upolyd, you::ushops, you::ustuck, you::utrap, you::utraptype, uwep, you::ux, you::uy, you::uz, vision_full_recalc, weapon_type(), nhcoord::x, xname(), nhcoord::y, and youmonst.
Referenced by dospit(), and throw_obj().
References canseemon, M_AP_MONSTER, monst::m_ap_type, miss(), mshot_xname(), otense(), pline(), rn2(), The(), and wakeup().
Referenced by thitmonst().
References artifact_hit(), AT_WEAP, Blind, Blinded, BLINDING_VENOM, body_part(), breakmsg(), breakobj(), breaktest(), can_blnd(), ceiling(), CORPSE, CREAM_PIE, monst::data, dmgval(), Doname2(), done(), dropy(), EGG, FACE, FALSE, flags, Half_physical_damage, HEAD, hitfloor(), if(), is_metallic, KILLED_BY, KILLED_BY_AN, killer, killer_format, losehp(), make_blinded(), you::mh, mons, objects, pline(), PM_SHADE, PM_STONE_GOLEM, poly_when_stoned(), polymon(), POTION_CLASS, potionhit(), rn1, rnd(), SILVER, Stone_resistance, STONING, touch_petrifies, TRUE, u, uarmh, you::ucreamed, you::udaminc, you::uhp, Upolyd, you::ux, you::uy, flag::verbose, vision_clears, xname(), and youmonst.
Referenced by throwit().
boolean walk_path | ( | coord * | src_cc, |
coord * | dest_cc, | ||
check_proc | , | ||
genericptr_t | arg | ||
) |
References FALSE, TRUE, nhcoord::x, and nhcoord::y.
Referenced by hurtle(), jump(), and mhurtle().
NEARDATA const char bullets[] [static] |
{ ALLOW_COUNT, COIN_CLASS, ALL_CLASSES, GEM_CLASS, 0 }
NEARDATA const char toss_objs[] [static] |
{ ALLOW_COUNT, COIN_CLASS, ALL_CLASSES, WEAPON_CLASS, 0 }