Make enhanced ammo last longer.
Since traps can no longer provide an infinite supply, and people were complaining that they always ran out of ammo before, make it less likely to break enchanted and blessed ammo, and more likely to break eroded ones.
This commit is contained in:
@@ -31,6 +31,7 @@ allow all tame monsters that eat to consider food thrown to them
|
|||||||
the screen display wasn't always up to date after map topology changes
|
the screen display wasn't always up to date after map topology changes
|
||||||
jumping over a sokobon pit would result in the player next to, not in, the pit
|
jumping over a sokobon pit would result in the player next to, not in, the pit
|
||||||
don't let arrow, rock or dart traps provide an infinite number of objects
|
don't let arrow, rock or dart traps provide an infinite number of objects
|
||||||
|
make enhanced ammo harder to break to make lesser number last longer
|
||||||
dropping from height or throwing a normal container may damage contents
|
dropping from height or throwing a normal container may damage contents
|
||||||
some Magicbane messages treated "erinys" as plural
|
some Magicbane messages treated "erinys" as plural
|
||||||
initialize artifacts before processing $WIZKIT
|
initialize artifacts before processing $WIZKIT
|
||||||
|
|||||||
+20
-5
@@ -1309,11 +1309,26 @@ register struct obj *obj;
|
|||||||
sometimes disappear when thrown */
|
sometimes disappear when thrown */
|
||||||
if (objects[otyp].oc_skill < P_NONE &&
|
if (objects[otyp].oc_skill < P_NONE &&
|
||||||
objects[otyp].oc_skill > -P_BOOMERANG &&
|
objects[otyp].oc_skill > -P_BOOMERANG &&
|
||||||
!objects[otyp].oc_magic && rn2(3)) {
|
!objects[otyp].oc_magic) {
|
||||||
if (*u.ushops)
|
/* we were breaking 2/3 of everything unconditionally.
|
||||||
check_shop_obj(obj, bhitpos.x,bhitpos.y, TRUE);
|
* we still don't want anything to survive unconditionally,
|
||||||
obfree(obj, (struct obj *)0);
|
* but we need ammo to stay around longer on average.
|
||||||
return 1;
|
*/
|
||||||
|
int broken, chance;
|
||||||
|
chance = 3 + greatest_erosion(obj) - obj->spe;
|
||||||
|
if (chance > 1)
|
||||||
|
broken = rn2(chance);
|
||||||
|
else
|
||||||
|
broken = !rn2(4);
|
||||||
|
if (obj->blessed && !rnl(4))
|
||||||
|
broken = 0;
|
||||||
|
|
||||||
|
if (broken) {
|
||||||
|
if (*u.ushops)
|
||||||
|
check_shop_obj(obj, bhitpos.x,bhitpos.y, TRUE);
|
||||||
|
obfree(obj, (struct obj *)0);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
passive_obj(mon, obj, (struct attack *)0);
|
passive_obj(mon, obj, (struct attack *)0);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user