From: copperwater Date: Wed, 18 Aug 2021 03:32:18 +0000 (-0400) Subject: Fix: gold dragon scale mail remained lit in bones X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=89835554d8be7aa5c5740163a0435f4fc8e186e8;p=nethack Fix: gold dragon scale mail remained lit in bones This is caused by the bones-pile-making routine using artifact_light() as a test for whether it needs to call end_burn. Gold dragon scale mail uses artifact_light(), but only returns true when its owornmask is set. But owornmask was getting zeroed right before artifact_light() is called. Fix is to move it right after instead. Tested that Sunsword is not affected by this (created bones while wearing gold dragon scales and wielding Sunsword in a dark area; when returning to them, no light was emitted from the gravesite) because it always returns true in artifact_light() irrespective of owornmask. --- diff --git a/src/bones.c b/src/bones.c index 08bb5f0f9..22755289f 100644 --- a/src/bones.c +++ b/src/bones.c @@ -235,10 +235,10 @@ drop_upon_death(struct monst *mtmp, /* monster if hero turned into one (other th if (!mtmp || is_undead(mtmp->data)) obj_no_longer_held(otmp); - otmp->owornmask = 0L; /* lamps don't go out when dropped */ if ((cont || artifact_light(otmp)) && obj_is_burning(otmp)) end_burn(otmp, TRUE); /* smother in statue */ + otmp->owornmask = 0L; if (otmp->otyp == SLIME_MOLD) goodfruit(otmp->spe);