Skip to content

Commit ee56b52

Browse files
committed
Fix: if the player blows up their bag of holding, make known the bag, and the object placed inside of it that made the bag blow up.
1 parent 2f7ec79 commit ee56b52

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

doc/evilhack-changelog.md

+2
Original file line numberDiff line numberDiff line change
@@ -3358,4 +3358,6 @@ The following changes to date are:
33583358
destoryed or fell off when polymorphing
33593359
- Fix: incorrect feedback when attempting to steal from a monster and
33603360
the objects being stolen have the oilskin object property
3361+
- Fix: if the player blows up their bag of holding, make known the bag,
3362+
and the object placed inside of it that made the bag blow up
33613363

src/pickup.c

+6-1
Original file line numberDiff line numberDiff line change
@@ -2404,6 +2404,7 @@ boolean on_floor;
24042404
VIS_EFFECTS | MAY_HIT | MAY_DESTROY | MAY_FRACTURE, otmp);
24052405
}
24062406
}
2407+
makeknown(BAG_OF_HOLDING); /* bag just blew up? must be a bag of holding */
24072408
}
24082409

24092410
STATIC_OVL long
@@ -2542,7 +2543,8 @@ register struct obj *obj;
25422543
/* did not actually insert obj yet */
25432544
if (was_unpaid)
25442545
addtobill(obj, FALSE, FALSE, TRUE);
2545-
if (obj->otyp == WAN_CANCELLATION)
2546+
if (obj->otyp == WAN_CANCELLATION
2547+
|| obj->otyp == BAG_OF_TRICKS)
25462548
makeknown(obj->otyp);
25472549
if (obj->otyp == BAG_OF_HOLDING) /* one bag of holding into another */
25482550
do_boh_explosion(obj, (obj->where == OBJ_FLOOR));
@@ -3716,6 +3718,9 @@ struct obj *box; /* or bag */
37163718
pline(
37173719
"As %s %s inside, you are blasted by a magical explosion!",
37183720
ansimpleoname(otmp), otense(otmp, "tumble"));
3721+
if (otmp->otyp == WAN_CANCELLATION
3722+
|| otmp->otyp == BAG_OF_TRICKS)
3723+
makeknown(otmp->otyp);
37193724
do_boh_explosion(targetbox, held);
37203725
nobj = 0; /* stop tipping; want loop to exit 'normally' */
37213726

0 commit comments

Comments
 (0)