]> granicus.if.org Git - nethack/commitdiff
bones while swallowed
authorcohrs <cohrs>
Fri, 11 Oct 2002 21:30:40 +0000 (21:30 +0000)
committercohrs <cohrs>
Fri, 11 Oct 2002 21:30:40 +0000 (21:30 +0000)
Michael pointed out that bones will never occur while swallowed because
makemon of the ghost will always fail.  I suggested that the outcome made
sense, since your body may be digested, torn apart, whatever.  But, there
was no explicit check for this to make it obvious this was occuring.

src/bones.c

index e10b9ae11e9770d727cb250164cbc9fb23d311ed..b01eb643db6151333c6702a15160d69622a5edc1 100644 (file)
@@ -165,6 +165,9 @@ can_make_bones()
            return FALSE;
        if (no_bones_level(&u.uz))
            return FALSE;               /* no bones for specific levels */
+       if (u.uswallow) {
+           return FALSE;               /* no bones when swallowed */
+       }
        if (!Is_branchlev(&u.uz)) {
            /* no bones on non-branches with portals */
            for(ttmp = ftrap; ttmp; ttmp = ttmp->ntrap)