more weapon shattering

The Kop Kaptain's rubber hose shatters from the force of your blow!
Rubber hoses are an individual exception that would need to be dealt
with explicitly, since the PLASTIC they're made of is floppy rather
than rigid as for other PLASTIC items.
This commit is contained in:
nethack.allison
2002-03-06 01:58:07 +00:00
parent 701b55783d
commit 233385401a
2 changed files with 6 additions and 1 deletions

View File

@@ -222,6 +222,11 @@ struct obj {
(obj)->otyp == FLINT || \
(obj)->otyp == TOUCHSTONE)
/* misc */
#define is_flimsy(otmp) (objects[(otmp)->otyp].oc_material <= LEATHER || \
(otmp)->otyp == RUBBER_HOSE)
/* helpers, simple enough to be macros */
#define is_plural(o) ((o)->quan > 1 || \
(o)->oartifact == ART_EYES_OF_THE_OVERWORLD)

View File

@@ -575,7 +575,7 @@ int thrown;
((wtype = uwep_skill_type()) != P_NONE &&
P_SKILL(wtype) >= P_SKILLED) &&
((monwep = MON_WEP(mon)) != 0 &&
objects[monwep->otyp].oc_material >= WOOD &&
!is_flimsy(monwep) &&
!obj_resists(monwep,
50 + 15 * greatest_erosion(obj), 100))) {
/*