]> granicus.if.org Git - nethack/commitdiff
change GOLD_CLASS to COIN_CLASS
authornethack.allison <nethack.allison>
Mon, 8 Jul 2002 23:25:53 +0000 (23:25 +0000)
committernethack.allison <nethack.allison>
Mon, 8 Jul 2002 23:25:53 +0000 (23:25 +0000)
31 files changed:
include/objclass.h
src/apply.c
src/botl.c
src/detect.c
src/do.c
src/dogmove.c
src/dokick.c
src/dothrow.c
src/eat.c
src/engrave.c
src/fountain.c
src/hack.c
src/invent.c
src/makemon.c
src/mapglyph.c
src/mkobj.c
src/monmove.c
src/mthrowu.c
src/objects.c
src/objnam.c
src/options.c
src/pager.c
src/pickup.c
src/restore.c
src/shk.c
src/sit.c
src/sp_lev.c
src/steal.c
src/u_init.c
src/vault.c
src/zap.c

index c5cff4331534064d479503164c45d83f82496339..474845034be5c3238ce4e062439f1f49de98454e 100644 (file)
@@ -133,7 +133,7 @@ extern NEARDATA struct objdescr obj_descr[];
 #define SCROLL_CLASS    9
 #define SPBOOK_CLASS   10      /* actually SPELL-book */
 #define WAND_CLASS     11
-#define GOLD_CLASS     12
+#define COIN_CLASS     12
 #define GEM_CLASS      13
 #define ROCK_CLASS     14
 #define BALL_CLASS     15
index edbf6164e156659b8e829d653cf593335400d138..8d9b53bf3966a49c5084ac3e6df22a593494f133 100644 (file)
@@ -1837,7 +1837,7 @@ struct obj *tstone;
     const char *streak_color;
     char stonebuf[QBUFSZ];
     static const char scritch[] = "\"scritch, scritch\"";
-    static char allowall[3] = { GOLD_CLASS, ALL_CLASSES, 0 };
+    static char allowall[3] = { COIN_CLASS, ALL_CLASSES, 0 };
 #ifndef GOLDOBJ
     struct obj goldobj;
 #endif
@@ -1846,7 +1846,7 @@ struct obj *tstone;
     if ((obj = getobj(allowall, stonebuf)) == 0)
        return;
 #ifndef GOLDOBJ
-    if (obj->oclass == GOLD_CLASS) {
+    if (obj->oclass == COIN_CLASS) {
        u.ugold += obj->quan;   /* keep botl up to date */
        goldobj = *obj;
        dealloc_obj(obj);
index 8c7ed2c047ecf22340e0d4921b82335000005c58..1c2d7cd7659202dbf3b4019d11004a23eebe0b4e 100644 (file)
@@ -254,7 +254,7 @@ bot2()
        if(hp < 0) hp = 0;
        (void) describe_level(newbot2);
        Sprintf(nb = eos(newbot2),
-               "%c:%-2ld HP:%d(%d) Pw:%d(%d) AC:%-2d", oc_syms[GOLD_CLASS],
+               "%c:%-2ld HP:%d(%d) Pw:%d(%d) AC:%-2d", oc_syms[COIN_CLASS],
 #ifndef GOLDOBJ
                u.ugold,
 #else
index 60eda7083ea08f6bbb7f01918e591a7594f45b14..799f3eb4d9bd9763e59a5d6089303117247defa8 100644 (file)
@@ -115,7 +115,7 @@ unsigned material;
                        /* didn't find it; perhaps a monster is carrying it */
 #ifndef GOLDOBJ
                        if ((mtmp = m_at(x,y)) != 0) {
-                               if (oclass == GOLD_CLASS && mtmp->mgold)
+                               if (oclass == COIN_CLASS && mtmp->mgold)
                                        return FALSE;
                                else for (otmp = mtmp->minvent; otmp; otmp = otmp->nobj)
                                        if (o_in(otmp, oclass)) return FALSE;
@@ -169,7 +169,7 @@ register struct obj *sobj;
     struct obj *temp;
     boolean stale;
 
-    known = stale = clear_stale_map(GOLD_CLASS,
+    known = stale = clear_stale_map(COIN_CLASS,
                                (unsigned)(sobj->blessed ? GOLD : 0));
 
     /* look for gold carried by monsters (might be in a container) */
@@ -186,7 +186,7 @@ register struct obj *sobj;
            if (sobj->blessed && o_material(obj, GOLD)) {
                known = TRUE;
                goto outgoldmap;
-           } else if (o_in(obj, GOLD_CLASS)) {
+           } else if (o_in(obj, COIN_CLASS)) {
                known = TRUE;
                goto outgoldmap;        /* skip further searching */
            }
@@ -197,7 +197,7 @@ register struct obj *sobj;
        if (sobj->blessed && o_material(obj, GOLD)) {
            known = TRUE;
            if (obj->ox != u.ux || obj->oy != u.uy) goto outgoldmap;
-       } else if (o_in(obj, GOLD_CLASS)) {
+       } else if (o_in(obj, COIN_CLASS)) {
            known = TRUE;
            if (obj->ox != u.ux || obj->oy != u.uy) goto outgoldmap;
        }
@@ -242,7 +242,7 @@ outgoldmap:
                temp->oy = obj->oy;
            }
            map_object(temp,1);
-       } else if ((temp = o_in(obj, GOLD_CLASS))) {
+       } else if ((temp = o_in(obj, COIN_CLASS))) {
            if (temp != obj) {
                temp->ox = obj->ox;
                temp->oy = obj->oy;
@@ -269,7 +269,7 @@ outgoldmap:
                temp->oy = mtmp->my;
                map_object(temp,1);
                break;
-           } else if ((temp = o_in(obj, GOLD_CLASS))) {
+           } else if ((temp = o_in(obj, COIN_CLASS))) {
                temp->ox = mtmp->mx;
                temp->oy = mtmp->my;
                map_object(temp,1);
@@ -448,9 +448,9 @@ int         class;          /* an object class, 0 for all */
        if ((is_cursed && mtmp->m_ap_type == M_AP_OBJECT &&
            (!class || class == objects[mtmp->mappearance].oc_class)) ||
 #ifndef GOLDOBJ
-           (mtmp->mgold && (!class || class == GOLD_CLASS))) {
+           (mtmp->mgold && (!class || class == COIN_CLASS))) {
 #else
-           (findgold(mtmp->minvent) && (!class || class == GOLD_CLASS))) {
+           (findgold(mtmp->minvent) && (!class || class == COIN_CLASS))) {
 #endif
            ct++;
            break;
@@ -530,9 +530,9 @@ int         class;          /* an object class, 0 for all */
            temp.corpsenm = PM_TENGU;           /* if mimicing a corpse */
            map_object(&temp, 1);
 #ifndef GOLDOBJ
-       } else if (mtmp->mgold && (!class || class == GOLD_CLASS)) {
+       } else if (mtmp->mgold && (!class || class == COIN_CLASS)) {
 #else
-       } else if (findgold(mtmp->minvent) && (!class || class == GOLD_CLASS)) {
+       } else if (findgold(mtmp->minvent) && (!class || class == COIN_CLASS)) {
 #endif
            struct obj gold;
 
index 19cc6cb872bc90d3f0c19fd33659883023f6029c..16409aa4606f25d16d0ee88ed37663a2550a3da6 100644 (file)
--- a/src/do.c
+++ b/src/do.c
@@ -42,7 +42,7 @@ STATIC_DCL void NDECL(final_level);
 #ifdef OVLB
 
 static NEARDATA const char drop_types[] =
-       { ALLOW_COUNT, GOLD_CLASS, ALL_CLASSES, 0 };
+       { ALLOW_COUNT, COIN_CLASS, ALL_CLASSES, 0 };
 
 /* 'd' command: drop one inventory item */
 int
@@ -224,7 +224,7 @@ doaltarobj(obj)  /* obj is an object dropped on an altar */
        /* KMH, conduct */
        u.uconduct.gnostic++;
 
-       if ((obj->blessed || obj->cursed) && obj->oclass != GOLD_CLASS) {
+       if ((obj->blessed || obj->cursed) && obj->oclass != COIN_CLASS) {
                There("is %s flash as %s %s the altar.",
                        an(hcolor(obj->blessed ? amber : Black)),
                        doname(obj), otense(obj, "hit"));
@@ -484,10 +484,10 @@ register struct obj *obj;
            if (!can_reach_floor()) {
                if(flags.verbose) You("drop %s.", doname(obj));
 #ifndef GOLDOBJ
-               if (obj->oclass != GOLD_CLASS || obj == invent) freeinv(obj);
+               if (obj->oclass != COIN_CLASS || obj == invent) freeinv(obj);
 #else
                /* Ensure update when we drop gold objects */
-               if (obj->oclass == GOLD_CLASS) flags.botl = 1;
+               if (obj->oclass == COIN_CLASS) flags.botl = 1;
                freeinv(obj);
 #endif
                hitfloor(obj);
@@ -509,10 +509,10 @@ dropx(obj)
 register struct obj *obj;
 {
 #ifndef GOLDOBJ
-       if (obj->oclass != GOLD_CLASS || obj == invent) freeinv(obj);
+       if (obj->oclass != COIN_CLASS || obj == invent) freeinv(obj);
 #else
         /* Ensure update when we drop gold objects */
-        if (obj->oclass == GOLD_CLASS) flags.botl = 1;
+        if (obj->oclass == COIN_CLASS) flags.botl = 1;
         freeinv(obj);
 #endif
        if (!u.uswallow && ship_object(obj, u.ux, u.uy, FALSE)) return;
@@ -671,7 +671,7 @@ int retry;
                if (cnt < otmp->quan && !welded(otmp) &&
                        (!otmp->cursed || otmp->otyp != LOADSTONE)) {
 #ifndef GOLDOBJ
-                   if (otmp->oclass == GOLD_CLASS)
+                   if (otmp->oclass == COIN_CLASS)
                        (void) splitobj(otmp, otmp->quan - cnt);
                    else
 #endif
@@ -685,7 +685,7 @@ int retry;
 
  drop_done:
 #ifndef GOLDOBJ
-    if (u_gold && invent && invent->oclass == GOLD_CLASS) {
+    if (u_gold && invent && invent->oclass == COIN_CLASS) {
        /* didn't drop [all of] it */
        u_gold = invent;
        invent = u_gold->nobj;
index 536092a6e2574874d5f9eb8b4180879fd391728c..616fbe6045a4876ee78a257b6549f99de1b57f36 100644 (file)
@@ -100,7 +100,7 @@ struct obj *obj;
                mtmp->meating = eaten_stat(mtmp->meating, obj);
                nutrit = eaten_stat(nutrit, obj);
            }
-       } else if (obj->oclass == GOLD_CLASS) {
+       } else if (obj->oclass == COIN_CLASS) {
            mtmp->meating = (int)(obj->quan/2000) + 1;
            if (mtmp->meating < 0) mtmp->meating = 1;
            nutrit = (int)(obj->quan/20);
index a81023a58a3df82a9829452947eb206276e9efdb..5b3fabfb3f922ae890dd2e4dd416bc5b0b63e666 100644 (file)
@@ -507,7 +507,7 @@ xchar x, y;
                return(1);
        }
 
-       isgold = (kickobj->oclass == GOLD_CLASS);
+       isgold = (kickobj->oclass == COIN_CLASS);
 
        /* too heavy to move.  range is calculated as potential distance from
         * player, so range == 2 means the object may move up to one square
@@ -1160,7 +1160,7 @@ xchar x, y, dlev;
                    /* set obj->no_charge to 0 */
                    if (Has_contents(obj))
                        picked_container(obj);  /* does the right thing */
-                   if (obj->oclass != GOLD_CLASS)
+                   if (obj->oclass != COIN_CLASS)
                        obj->no_charge = 0;
                }
 
@@ -1281,7 +1281,7 @@ boolean shop_floor_obj;
            /* set otmp->no_charge to 0 */
            if(container)
                picked_container(otmp); /* happens to do the right thing */
-           if(otmp->oclass != GOLD_CLASS)
+           if(otmp->oclass != COIN_CLASS)
                otmp->no_charge = 0;
        }
 
index 34311ae549c5360c20f53f309e591793cf86178f..0f6882e5c971c826a18f49a3af0c0af76fdc2cf2 100644 (file)
@@ -21,10 +21,10 @@ STATIC_DCL boolean FDECL(mhurtle_step, (genericptr_t,int,int));
 
 
 static NEARDATA const char toss_objs[] =
-       { ALLOW_COUNT, GOLD_CLASS, ALL_CLASSES, WEAPON_CLASS, 0 };
+       { ALLOW_COUNT, COIN_CLASS, ALL_CLASSES, WEAPON_CLASS, 0 };
 /* different default choices when wielding a sling (gold must be included) */
 static NEARDATA const char bullets[] =
-       { ALLOW_COUNT, GOLD_CLASS, ALL_CLASSES, GEM_CLASS, 0 };
+       { ALLOW_COUNT, COIN_CLASS, ALL_CLASSES, GEM_CLASS, 0 };
 
 extern boolean notonhead;      /* for long worms */
 
@@ -44,7 +44,7 @@ int shotlimit;
        /* ask "in what direction?" */
 #ifndef GOLDOBJ
        if (!getdir((char *)0)) {
-               if (obj->oclass == GOLD_CLASS) {
+               if (obj->oclass == COIN_CLASS) {
                    u.ugold += obj->quan;
                    flags.botl = 1;
                    dealloc_obj(obj);
@@ -52,7 +52,7 @@ int shotlimit;
                return(0);
        }
 
-       if(obj->oclass == GOLD_CLASS) return(throw_gold(obj));
+       if(obj->oclass == COIN_CLASS) return(throw_gold(obj));
 #else
        if (!getdir((char *)0)) {
            /* obj might need to be merged back into the singular gold object */
@@ -69,7 +69,7 @@ int shotlimit;
           If the money is in quiver, throw one coin at a time,
           possibly using a sling.
         */
-       if(obj->oclass == GOLD_CLASS && obj != uquiver) return(throw_gold(obj));
+       if(obj->oclass == COIN_CLASS && obj != uquiver) return(throw_gold(obj));
 #endif
 
        if(!canletgo(obj,"throw"))
index 611d2aacd465d807e747a92c444040add01891d5..0905e5de5a76cd22f77fd30dd78ffbf8d80f000c 100644 (file)
--- a/src/eat.c
+++ b/src/eat.c
@@ -70,7 +70,7 @@ STATIC_OVL NEARDATA const char comestibles[] = { FOOD_CLASS, 0 };
 
 /* Gold must come first for getobj(). */
 STATIC_OVL NEARDATA const char allobj[] = {
-       GOLD_CLASS, WEAPON_CLASS, ARMOR_CLASS, POTION_CLASS, SCROLL_CLASS,
+       COIN_CLASS, WEAPON_CLASS, ARMOR_CLASS, POTION_CLASS, SCROLL_CLASS,
        WAND_CLASS, RING_CLASS, AMULET_CLASS, FOOD_CLASS, TOOL_CLASS,
        GEM_CLASS, ROCK_CLASS, BALL_CLASS, CHAIN_CLASS, SPBOOK_CLASS, 0 };
 
@@ -253,7 +253,7 @@ choke(food) /* To a full belly all food is bad. (It.) */
                 */
                if(food) {
                        You("choke over your %s.", foodword(food));
-                       if (food->oclass == GOLD_CLASS) {
+                       if (food->oclass == COIN_CLASS) {
                                killer = "a very rich meal";
                        } else {
                                killer = food_xname(food, FALSE);
@@ -1515,7 +1515,7 @@ eatspecial() /* called after eating non-food */
        lesshungry(victual.nmod);
        victual.piece = (struct obj *)0;
        victual.eating = 0;
-       if (otmp->oclass == GOLD_CLASS) {
+       if (otmp->oclass == COIN_CLASS) {
 #ifdef GOLDOBJ
                if (carried(otmp))
                    useupall(otmp);
@@ -1854,7 +1854,7 @@ doeat()           /* generic "eat" command funtion (see cmd.c) */
            victual.canchoke = (u.uhs == SATIATED);
                /* Note: gold weighs 1 pt. for each 1000 pieces (see */
                /* pickup.c) so gold and non-gold is consistent. */
-           if (otmp->oclass == GOLD_CLASS)
+           if (otmp->oclass == COIN_CLASS)
                basenutrit = ((otmp->quan > 200000L) ? 2000
                        : (int)(otmp->quan/100L));
            else if(otmp->oclass == BALL_CLASS || otmp->oclass == CHAIN_CLASS)
@@ -1885,7 +1885,7 @@ doeat()           /* generic "eat" command funtion (see cmd.c) */
                    You("seem unaffected by the poison.");
            } else if (!otmp->cursed)
                pline("This %s is delicious!",
-                     otmp->oclass == GOLD_CLASS ? foodword(otmp) :
+                     otmp->oclass == COIN_CLASS ? foodword(otmp) :
                      singular(otmp, xname));
 
            eatspecial();
@@ -2366,7 +2366,7 @@ floorfood(verb,corpsecheck)       /* get food from floor or pack */
        for (otmp = level.objects[u.ux][u.uy]; otmp; otmp = otmp->nexthere) {
                if(corpsecheck ?
                (otmp->otyp==CORPSE && (corpsecheck == 1 || tinnable(otmp))) :
-                   feeding ? (otmp->oclass != GOLD_CLASS && is_edible(otmp)) :
+                   feeding ? (otmp->oclass != COIN_CLASS && is_edible(otmp)) :
                                                otmp->oclass==FOOD_CLASS) {
                        Sprintf(qbuf, "There %s %s here; %s %s?",
                                otense(otmp, "are"),
index 5be718762f8e6b90917e79c5e2ff1f5f9e4dd3fa..afdb7dce9255fdccd78aab991d9c9bdc90153027 100644 (file)
@@ -546,7 +546,7 @@ doengrave()
            case AMULET_CLASS:
            case CHAIN_CLASS:
            case POTION_CLASS:
-           case GOLD_CLASS:
+           case COIN_CLASS:
                break;
 
            case RING_CLASS:
index 5b1c5325dced8227270fccdcb93d7c3968bb994c..7eafc43f1940449a3926772f774398c81e49357a 100644 (file)
@@ -455,7 +455,7 @@ register struct obj *obj;
                             if (money > 10) {
                                /* Amount to loose.  Might get rounded up as fountains don't pay change... */
                                money = somegold(money) / 10; 
-                               for (otmp = invent; otmp && money > 0; otmp = otmp->nobj) if (otmp->oclass == GOLD_CLASS) {
+                               for (otmp = invent; otmp && money > 0; otmp = otmp->nobj) if (otmp->oclass == COIN_CLASS) {
                                    int denomination = objects[otmp->otyp].oc_cost;
                                    long coin_loss = (money + denomination - 1) / denomination;
                                     coin_loss = min(coin_loss, otmp->quan);
index bffcbdad02aa96bd65447b757ac69250dbe47898..136df14779eb81a3d5951483e480cb8d58676402 100644 (file)
@@ -2088,14 +2088,14 @@ inv_weight()
           of invent for easier manipulation by askchain & co, but it's also
           retained in u.ugold in order to keep the status line accurate; we
           mustn't add its weight in twice under that circumstance */
-       wt = (otmp && otmp->oclass == GOLD_CLASS) ? 0 :
+       wt = (otmp && otmp->oclass == COIN_CLASS) ? 0 :
                (int)((u.ugold + 50L) / 100L);
 #endif
        while (otmp) {
 #ifndef GOLDOBJ
                if (otmp->otyp != BOULDER || !throws_rocks(youmonst.data))
 #else
-               if (otmp->oclass == GOLD_CLASS)
+               if (otmp->oclass == COIN_CLASS)
                        wt += (int)(((long)otmp->quan + 50L) / 100L);
                else if (otmp->otyp != BOULDER || !throws_rocks(youmonst.data))
 #endif
@@ -2176,7 +2176,7 @@ struct obj *otmp;
 {
         while(otmp) {
                /* Must change when silver & copper is implemented: */
-               if (otmp->oclass == GOLD_CLASS) return otmp->quan;
+               if (otmp->oclass == COIN_CLASS) return otmp->quan;
                otmp = otmp->nobj;
        }
        return 0;
index 5fa8fc2b350476609187ceaf4cf047d84b4da97a..9880e46465e03acf8038ebc2b4636576b96525f2 100644 (file)
@@ -55,7 +55,7 @@ register struct obj *otmp;
 
 #ifdef GOLDOBJ
         /* There is only one of these in inventory... */        
-        if (otmp->oclass == GOLD_CLASS) {
+        if (otmp->oclass == COIN_CLASS) {
            otmp->invlet = GOLD_SYM;
            return;
        }
@@ -179,7 +179,7 @@ struct obj **potmp, **pobj;
 #ifdef GOLDOBJ
                 /* temporary special case for gold objects!!!! */
 #endif
-               if (otmp->oclass == GOLD_CLASS) otmp->owt = weight(otmp);
+               if (otmp->oclass == COIN_CLASS) otmp->owt = weight(otmp);
                else otmp->owt += obj->owt;
                if(!otmp->onamelth && obj->onamelth)
                        otmp = *potmp = oname(otmp, ONAME(obj));
@@ -245,7 +245,7 @@ void
 addinv_core1(obj)
 struct obj *obj;
 {
-       if (obj->oclass == GOLD_CLASS) {
+       if (obj->oclass == COIN_CLASS) {
 #ifndef GOLDOBJ
                u.ugold += obj->quan;
 #else
@@ -312,7 +312,7 @@ struct obj *obj;
        addinv_core1(obj);
 #ifndef GOLDOBJ
        /* if handed gold, we're done */
-       if (obj->oclass == GOLD_CLASS)
+       if (obj->oclass == COIN_CLASS)
            return obj;
 #endif
 
@@ -484,7 +484,7 @@ void
 freeinv_core(obj)
 struct obj *obj;
 {
-       if (obj->oclass == GOLD_CLASS) {
+       if (obj->oclass == COIN_CLASS) {
 #ifndef GOLDOBJ
                u.ugold -= obj->quan;
                obj->in_use = FALSE;
@@ -663,7 +663,7 @@ register int x, y;
 {
        register struct obj *obj = level.objects[x][y];
        while(obj) {
-           if (obj->oclass == GOLD_CLASS) return obj;
+           if (obj->oclass == COIN_CLASS) return obj;
            obj = obj->nexthere;
        }
        return((struct obj *)0);
@@ -770,10 +770,10 @@ register const char *let,*word;
 
        if(*let == ALLOW_COUNT) let++, allowcnt = 1;
 #ifndef GOLDOBJ
-       if(*let == GOLD_CLASS) let++,
+       if(*let == COIN_CLASS) let++,
                usegold = TRUE, allowgold = (u.ugold ? TRUE : FALSE);
 #else
-       if(*let == GOLD_CLASS) let++, usegold = TRUE;
+       if(*let == COIN_CLASS) let++, usegold = TRUE;
 #endif
 
        /* Equivalent of an "ugly check" for gold */
@@ -798,7 +798,7 @@ register const char *let,*word;
 
        if(allownone) *bp++ = '-';
 #ifndef GOLDOBJ
-       if(allowgold) *bp++ = def_oc_syms[GOLD_CLASS];
+       if(allowgold) *bp++ = def_oc_syms[COIN_CLASS];
 #endif
        if(bp > buf && bp[-1] == '-') *bp++ = ' ';
        ap = altlets;
@@ -959,7 +959,7 @@ register const char *let,*word;
                if(ilet == '-') {
                        return(allownone ? &zeroobj : (struct obj *) 0);
                }
-               if(ilet == def_oc_syms[GOLD_CLASS]) {
+               if(ilet == def_oc_syms[COIN_CLASS]) {
                        if (!usegold) {
                            You("cannot %s gold.", word);
                            return(struct obj *)0;
@@ -1013,7 +1013,7 @@ register const char *let,*word;
                     * counts for other things since the throw code will
                     * split off a single item anyway */
 #ifdef GOLDOBJ
-                   if (ilet != def_oc_syms[GOLD_CLASS])
+                   if (ilet != def_oc_syms[COIN_CLASS])
 #endif
                        allowcnt = 1;
                    if(cnt == 0 && prezero) return((struct obj *)0);
@@ -1048,7 +1048,7 @@ register const char *let,*word;
        }
        if(!allowall && let && !index(let,otmp->oclass)
 #ifdef GOLDOBJ
-          && !(usegold && otmp->oclass == GOLD_CLASS)
+          && !(usegold && otmp->oclass == COIN_CLASS)
 #endif
           ) {
                pline(silly_thing_to, word);
@@ -1220,7 +1220,7 @@ unsigned *resultflags;
                }
            }
 
-           if (oc_of_sym == GOLD_CLASS && !combo) {
+           if (oc_of_sym == COIN_CLASS && !combo) {
 #ifndef GOLDOBJ
                if (allowgold == 1)
                    (*fn)(mkgoldobj(u.ugold));
@@ -1320,7 +1320,7 @@ register int FDECL((*fn),(OBJ_P)), FDECL((*ckfn),(OBJ_P));
         */
 nextclass:
        ilet = 'a'-1;
-       if (*objchn && (*objchn)->oclass == GOLD_CLASS)
+       if (*objchn && (*objchn)->oclass == COIN_CLASS)
                ilet--;         /* extra iteration */
        for (otmp = *objchn; otmp; otmp = otmp2) {
                if(ilet == 'z') ilet = 'A'; else ilet++;
@@ -1493,7 +1493,7 @@ obj_to_let(obj)   /* should of course only be called for things in invent */
 register struct obj *obj;
 {
 #ifndef GOLDOBJ
-       if (obj->oclass == GOLD_CLASS)
+       if (obj->oclass == COIN_CLASS)
                return GOLD_SYM;
 #endif
        if (!flags.invlet_constant) {
@@ -1555,7 +1555,7 @@ long quan;                /* if non-0, print this quantity, not obj->quan */
                (dot && use_invlet ? obj->invlet : let),
                (txt ? txt : doname(obj)), cost, currency(cost));
 #ifndef GOLDOBJ
-    } else if (obj && obj->oclass == GOLD_CLASS) {
+    } else if (obj && obj->oclass == COIN_CLASS) {
        Sprintf(li, "%ld gold piece%s%s", obj->quan, plur(obj->quan),
                (dot ? "." : ""));
 #endif
@@ -1774,20 +1774,20 @@ count_buc(list, type)
        if (Role_if(PM_PRIEST)) list->bknown = TRUE;
        switch(type) {
            case BUC_BLESSED:
-               if (list->oclass != GOLD_CLASS && list->bknown && list->blessed)
+               if (list->oclass != COIN_CLASS && list->bknown && list->blessed)
                    count++;
                break;
            case BUC_CURSED:
-               if (list->oclass != GOLD_CLASS && list->bknown && list->cursed)
+               if (list->oclass != COIN_CLASS && list->bknown && list->cursed)
                    count++;
                break;
            case BUC_UNCURSED:
-               if (list->oclass != GOLD_CLASS &&
+               if (list->oclass != COIN_CLASS &&
                        list->bknown && !list->blessed && !list->cursed)
                    count++;
                break;
            case BUC_UNKNOWN:
-               if (list->oclass != GOLD_CLASS && !list->bknown)
+               if (list->oclass != COIN_CLASS && !list->bknown)
                    count++;
                break;
            default:
@@ -1995,7 +1995,7 @@ dotypeinv()
        }
        if (traditional) {
            oclass = def_char_to_objclass(c); /* change to object class */
-           if (oclass == GOLD_CLASS) {
+           if (oclass == COIN_CLASS) {
                return doprgold();
            } else if (index(types, c) > index(types, '\033')) {
                You("have no such objects.");
@@ -2232,7 +2232,7 @@ mergable(otmp, obj)       /* returns TRUE if obj  & otmp can be merged */
        if (obj->otyp != otmp->otyp) return FALSE;
        
         /* Coins of the same kind will always merge. */
-        if (obj->oclass == GOLD_CLASS) return TRUE;
+        if (obj->oclass == COIN_CLASS) return TRUE;
 
         if (obj->unpaid != otmp->unpaid ||
 #endif
@@ -2722,7 +2722,7 @@ char *title;
                 * gold in their inventory, so it won't merge.
                 */
                m_gold = zeroobj;
-               m_gold.otyp = GOLD_PIECE;  m_gold.oclass = GOLD_CLASS;
+               m_gold.otyp = GOLD_PIECE;  m_gold.oclass = COIN_CLASS;
                m_gold.quan = mon->mgold;  m_gold.dknown = 1;
                m_gold.where = OBJ_FREE;
                /* we had better not merge and free this object... */
index 38696148d4f0a8bcbde88bf9fb50036784990b56..b1ff40e812b89f651afb4c5ef5050fe8f877b3e9 100644 (file)
@@ -1601,7 +1601,7 @@ struct monst *mtmp;
 
 static NEARDATA char syms[] = {
        MAXOCLASSES, MAXOCLASSES+1, RING_CLASS, WAND_CLASS, WEAPON_CLASS,
-       FOOD_CLASS, GOLD_CLASS, SCROLL_CLASS, POTION_CLASS, ARMOR_CLASS,
+       FOOD_CLASS, COIN_CLASS, SCROLL_CLASS, POTION_CLASS, ARMOR_CLASS,
        AMULET_CLASS, TOOL_CLASS, ROCK_CLASS, GEM_CLASS, SPBOOK_CLASS,
        S_MIMIC_DEF, S_MIMIC_DEF, S_MIMIC_DEF,
 };
@@ -1696,7 +1696,7 @@ assign_sym:
                if (s_sym >= MAXOCLASSES) {
                        ap_type = M_AP_FURNITURE;
                        appear = s_sym == MAXOCLASSES ? S_upstair : S_dnstair;
-               } else if (s_sym == GOLD_CLASS) {
+               } else if (s_sym == COIN_CLASS) {
                        ap_type = M_AP_OBJECT;
                        appear = GOLD_PIECE;
                } else {
index 6ea4d964b9635abf0fad3a63fec589a39d014047..b81a9f3f8f827b98f3c6e45c668683b840af7d64 100644 (file)
@@ -126,7 +126,7 @@ unsigned *ospecial;
 #ifdef ROGUE_COLOR
        if (HAS_ROGUE_IBM_GRAPHICS && iflags.use_color) {
            switch(objects[offset].oc_class) {
-               case GOLD_CLASS: color = CLR_YELLOW; break;
+               case COIN_CLASS: color = CLR_YELLOW; break;
                case FOOD_CLASS: color = CLR_RED; break;
                default: color = CLR_BRIGHT_BLUE; break;
            }
index a0e8c448845c515a4ce9b8b466ba8d314f8a3362..d1a5640606346d921950e699ab97d6768d87cfeb 100644 (file)
@@ -46,7 +46,7 @@ const struct icp boxiprobs[] = {
 {18, POTION_CLASS},
 {18, SCROLL_CLASS},
 {12, SPBOOK_CLASS},
-{ 7, GOLD_CLASS},
+{ 7, COIN_CLASS},
 { 6, WAND_CLASS},
 { 5, RING_CLASS},
 { 1, AMULET_CLASS}
@@ -175,7 +175,7 @@ struct obj *box;
                if (!(otmp = mkobj(iprobs->iclass, TRUE))) continue;
 
                /* handle a couple of special cases */
-               if (otmp->oclass == GOLD_CLASS) {
+               if (otmp->oclass == COIN_CLASS) {
                    /* 2.5 x level's usual amount; weight adjusted below */
                    otmp->quan = (long)(rnd(level_difficulty()+2) * rnd(75));
                    otmp->owt = weight(otmp);
@@ -609,7 +609,7 @@ boolean artif;
                                                    mkobj(SPBOOK_CLASS,FALSE));
                }
                break;
-       case GOLD_CLASS:
+       case COIN_CLASS:
                break;  /* do nothing */
        default:
                impossible("impossible mkobj %d, sym '%c'.", otmp->otyp,
@@ -830,7 +830,7 @@ register struct obj *obj;
                return wt;
        } else if (obj->oclass == FOOD_CLASS && obj->oeaten) {
                return eaten_stat((int)obj->quan * wt, obj);
-       } else if (obj->oclass == GOLD_CLASS)
+       } else if (obj->oclass == COIN_CLASS)
                return (int)((obj->quan + 50L) / 100L);
        else if (obj->otyp == HEAVY_IRON_BALL && obj->owt != 0)
                return((int)(obj->owt));        /* kludge for "very" heavy iron ball */
index ca61e287ecd8b7fab0c6941d5448259ebb56e8a8..f2ac6e2c85399fb1da0f023c7852159e76402c0a 100644 (file)
@@ -822,7 +822,7 @@ not_special:
                         (mtoo->mappearance && !mtoo->iswiz) ||
                         !mtoo->data->mmove)) continue;
 
-                   if(((likegold && otmp->oclass == GOLD_CLASS) ||
+                   if(((likegold && otmp->oclass == COIN_CLASS) ||
                       (likeobjs && index(practical, otmp->oclass) &&
                        (otmp->otyp != CORPSE || (ptr->mlet == S_NYMPH
                           && !is_rider(&mons[otmp->corpsenm])))) ||
@@ -1317,7 +1317,7 @@ struct monst *mtmp;
                int typ = obj->otyp;
 
 #ifdef GOLDOBJ
-                if (typ == GOLD_CLASS && obj->quan > 100L) return FALSE;
+                if (typ == COIN_CLASS && obj->quan > 100L) return FALSE;
 #endif
                if (obj->oclass != GEM_CLASS &&
                    !(typ >= ARROW && typ <= BOOMERANG) &&
index 896a6d899d807d26650063b8db85ec6211d730b2..dec7c2035479c72e1f7d0859a39777497b391bde 100644 (file)
@@ -826,7 +826,7 @@ int whodidit;       /* 1==hero, 0=other, -1==just check whether it'll pass thru */
            /* breakage makes its own noises */
        else if (obj_type == BOULDER || obj_type == HEAVY_IRON_BALL)
            pline("Whang!");
-       else if (otmp->oclass == GOLD_CLASS ||
+       else if (otmp->oclass == COIN_CLASS ||
                objects[obj_type].oc_material == GOLD ||
                objects[obj_type].oc_material == SILVER)
            pline("Clink!");
index 845e5a20462a8436c1140119f42913d6402f1c75..48b78588982c007918b9b181e1e1fd2d29d3457b 100644 (file)
@@ -875,7 +875,7 @@ WAND((char *)0,        "jeweled",   0, 150, 1, 0,         IRON,     HI_MINERAL),
 /* coins ... - so far, gold is all there is */
 #define COIN(name,prob,metal,worth) OBJECT( \
                OBJ(name,(char *)0), BITS(0,1,0,0,0,0,0,0,0,0,0,P_NONE,metal), 0, \
-               GOLD_CLASS, prob, 0, 1, worth, 0, 0, 0, 0, 0, HI_GOLD )
+               COIN_CLASS, prob, 0, 1, worth, 0, 0, 0, 0, 0, HI_GOLD )
        COIN("gold piece",      1000, GOLD,1),
 #undef COIN
 
index 856b25282b360e11f186baf59d1dd76dacead780..e02ae10f5918ccbedaf7c7f867c5fedff9b50552 100644 (file)
@@ -101,7 +101,7 @@ register int otyp;
        if (Role_if(PM_SAMURAI) && Japanese_item_name(otyp))
                actualn = Japanese_item_name(otyp);
        switch(ocl->oc_class) {
-       case GOLD_CLASS:
+       case COIN_CLASS:
                Strcpy(buf, "coin");
                break;
        case POTION_CLASS:
@@ -342,7 +342,7 @@ register struct obj *obj;
                        Sprintf(eos(buf), " of %s meat", mons[obj->corpsenm].mname);
                }
                break;
-           case GOLD_CLASS:
+           case COIN_CLASS:
            case CHAIN_CLASS:
                Strcpy(buf, actualn);
                break;
@@ -572,7 +572,7 @@ register struct obj *obj;
 #endif
 
        if (obj->bknown &&
-           obj->oclass != GOLD_CLASS &&
+           obj->oclass != COIN_CLASS &&
            (obj->otyp != POT_WATER || !objects[POT_WATER].oc_name_known
                || (!obj->cursed && !obj->blessed))) {
            /* allow 'blessed clear potion' if we don't know it's holy water;
index 261d1fd8abfdc652531df6e95efa6c8e4c7f42ec..2c80c3d5d76a6168ce5d31ec0a3a8803957ea40b 100644 (file)
@@ -329,7 +329,7 @@ extern char ttycolors[CLR_MAX];       /* in sys/msdos/video.c */
 #endif
 
 static char def_inv_order[MAXOCLASSES] = {
-       GOLD_CLASS, AMULET_CLASS, WEAPON_CLASS, ARMOR_CLASS, FOOD_CLASS,
+       COIN_CLASS, AMULET_CLASS, WEAPON_CLASS, ARMOR_CLASS, FOOD_CLASS,
        SCROLL_CLASS, SPBOOK_CLASS, POTION_CLASS, RING_CLASS, WAND_CLASS,
        TOOL_CLASS, GEM_CLASS, ROCK_CLASS, BALL_CLASS, CHAIN_CLASS, 0,
 };
@@ -745,7 +745,7 @@ char *op;
     num = 0;
 #ifndef GOLDOBJ
     if (!index(op, GOLD_SYM))
-       buf[num++] = GOLD_CLASS;
+       buf[num++] = COIN_CLASS;
 #else
     /*  !!!! probably unnecessary with gold as normal inventory */
 #endif
index 07233422453589844993bade1143040f72d8807f..1d794754d517aabcd1546d16ff0060dd6d37a974 100644 (file)
@@ -212,7 +212,7 @@ lookat(x, y, buf, monbuf)
        if (!otmp || otmp->otyp != glyph_to_obj(glyph)) {
            if (glyph_to_obj(glyph) != STRANGE_OBJECT) {
                otmp = mksobj(glyph_to_obj(glyph), FALSE, FALSE);
-               if (otmp->oclass == GOLD_CLASS)
+               if (otmp->oclass == COIN_CLASS)
                    otmp->quan = 2L; /* to force pluralization */
                else if (otmp->otyp == SLIME_MOLD)
                    otmp->spe = current_fruit;  /* give the fruit a type */
index 5fdf57ee35832f78b1979954b712af5a57887ec8..3225a5d990566b4e308a6845a17591e8fba03a32 100644 (file)
@@ -106,7 +106,7 @@ boolean FDECL((*filter),(OBJ_P));
 
 #ifndef GOLDOBJ
        if (incl_gold)
-           ilets[iletct++] = def_oc_syms[GOLD_CLASS];
+           ilets[iletct++] = def_oc_syms[COIN_CLASS];
 #endif
        ilets[iletct] = '\0'; /* terminate ilets so that index() will work */
        while (otmp) {
@@ -317,16 +317,16 @@ struct obj *obj;
        (index(valid_menu_classes, obj->oclass) != (char *)0))
        return TRUE;
     else if (((index(valid_menu_classes,'U') != (char *)0) &&
-       (obj->oclass != GOLD_CLASS && obj->bknown && !obj->blessed && !obj->cursed)))
+       (obj->oclass != COIN_CLASS && obj->bknown && !obj->blessed && !obj->cursed)))
        return TRUE;
     else if (((index(valid_menu_classes,'B') != (char *)0) &&
-       (obj->oclass != GOLD_CLASS && obj->bknown && obj->blessed)))
+       (obj->oclass != COIN_CLASS && obj->bknown && obj->blessed)))
        return TRUE;
     else if (((index(valid_menu_classes,'C') != (char *)0) &&
-       (obj->oclass != GOLD_CLASS && obj->bknown && obj->cursed)))
+       (obj->oclass != COIN_CLASS && obj->bknown && obj->cursed)))
        return TRUE;
     else if (((index(valid_menu_classes,'X') != (char *)0) &&
-       (obj->oclass != GOLD_CLASS && !obj->bknown)))
+       (obj->oclass != COIN_CLASS && !obj->bknown)))
        return TRUE;
     else
        return FALSE;
@@ -914,7 +914,7 @@ boolean telekinesis;
 int *wt_before, *wt_after;
 {
     boolean adjust_wt = container && carried(container),
-           is_gold = obj->oclass == GOLD_CLASS;
+           is_gold = obj->oclass == COIN_CLASS;
     int wt, iw, ow, oow;
     long qq, savequan;
 #ifdef GOLDOBJ
@@ -1091,7 +1091,7 @@ boolean telekinesis;
     if (*cnt_p < 1L) {
        result = -1;    /* nothing lifted */
 #ifndef GOLDOBJ
-    } else if (obj->oclass != GOLD_CLASS && inv_cnt() >= 52 &&
+    } else if (obj->oclass != COIN_CLASS && inv_cnt() >= 52 &&
                !merge_choice(invent, obj)) {
 #else
     } else if (inv_cnt() >= 52 && !merge_choice(invent, obj)) {
@@ -1168,7 +1168,7 @@ boolean telekinesis;      /* not picking it up directly by hand */
        } else if (obj->oartifact && !touch_artifact(obj,&youmonst)) {
            return 0;
 #ifndef GOLDOBJ
-       } else if (obj->oclass == GOLD_CLASS) {
+       } else if (obj->oclass == COIN_CLASS) {
            /* Special consideration for gold pieces... */
            long iw = (long)max_capacity() - GOLD_WT(u.ugold);
            long gold_capacity = GOLD_CAPACITY(iw, u.ugold);
@@ -1249,7 +1249,7 @@ boolean telekinesis;      /* not picking it up directly by hand */
 
 #ifdef GOLDOBJ
         /* Whats left of the special case for gold :-) */
-       if (obj->oclass == GOLD_CLASS) flags.botl = 1;
+       if (obj->oclass == COIN_CLASS) flags.botl = 1;
 #endif
        if (obj->quan != count && obj->otyp != LOADSTONE)
            obj = splitobj(obj, count);
@@ -1473,7 +1473,7 @@ lootcont:
        struct obj *goldob;
        /* Find a money object to mess with */
        for (goldob = invent; goldob; goldob = goldob->nobj) {
-           if (goldob->oclass == GOLD_CLASS) break;
+           if (goldob->oclass == COIN_CLASS) break;
        }
        if (goldob){
            long contribution = rnd((int)min(LARGEST_INT, goldob->quan));
@@ -1823,7 +1823,7 @@ out_container(obj)
 register struct obj *obj;
 {
        register struct obj *otmp;
-       boolean is_gold = (obj->oclass == GOLD_CLASS);
+       boolean is_gold = (obj->oclass == COIN_CLASS);
        int res, loadlev;
        long count;
 
@@ -2115,7 +2115,7 @@ ask_again2:
        }
 
 #ifndef GOLDOBJ
-       if (u_gold && invent && invent->oclass == GOLD_CLASS) {
+       if (u_gold && invent && invent->oclass == COIN_CLASS) {
            /* didn't stash [all of] it */
            u_gold = invent;
            invent = u_gold->nobj;
index d7c72c11b488fb1305326da411b787bd37eacd98..8262830774ebac7333e6e2f10d100318c3cf79ca 100644 (file)
@@ -107,7 +107,7 @@ boolean quietly;
        for (otmp = invent; otmp; otmp = otmp2) {
            otmp2 = otmp->nobj;
 #ifndef GOLDOBJ
-           if (otmp->oclass == GOLD_CLASS) {
+           if (otmp->oclass == COIN_CLASS) {
                /* in_use gold is created by some menu operations */
                if (!otmp->in_use) {
                    impossible("inven_inuse: !in_use gold in inventory");
index 65ffe8752926f81ce8bf0d2c0090b7ca955f5bbb..96d115ebce7b52f4dfbad6030f81c344faf5967a 100644 (file)
--- a/src/shk.c
+++ b/src/shk.c
@@ -1896,7 +1896,7 @@ register boolean unpaid_only;
 
        /* the price of contained objects */
        for (otmp = obj->cobj; otmp; otmp = otmp->nobj) {
-           if (otmp->oclass == GOLD_CLASS) continue;
+           if (otmp->oclass == COIN_CLASS) continue;
            /* the "top" container is evaluated by caller */
            if (usell) {
                if (saleable(shkp, otmp) &&
@@ -1926,7 +1926,7 @@ register struct obj *obj;
 
        /* accumulate contained gold */
        for (otmp = obj->cobj; otmp; otmp = otmp->nobj)
-           if (otmp->oclass == GOLD_CLASS)
+           if (otmp->oclass == COIN_CLASS)
                value += otmp->quan;
            else if (Has_contents(otmp))
                value += contained_gold(otmp);
@@ -1944,7 +1944,7 @@ register boolean sale;
 
        /* the "top" container is treated in the calling fn */
        for (otmp = obj->cobj; otmp; otmp = otmp->nobj) {
-           if (otmp->oclass == GOLD_CLASS) continue;
+           if (otmp->oclass == COIN_CLASS) continue;
 
            if (!otmp->unpaid && !(sale && saleable(shkp, otmp)))
                otmp->no_charge = 1;
@@ -1962,7 +1962,7 @@ register struct obj *obj;
 
        /* the "top" container is treated in the calling fn */
        for (otmp = obj->cobj; otmp; otmp = otmp->nobj) {
-           if (otmp->oclass == GOLD_CLASS) continue;
+           if (otmp->oclass == COIN_CLASS) continue;
 
            if (otmp->no_charge)
                otmp->no_charge = 0;
@@ -2097,7 +2097,7 @@ register struct monst *shkp;
        register struct obj *otmp;
 
        for (otmp = obj->cobj; otmp; otmp = otmp->nobj) {
-               if (otmp->oclass == GOLD_CLASS) continue;
+               if (otmp->oclass == COIN_CLASS) continue;
 
                /* the "top" box is added in addtobill() */
                if (!otmp->no_charge)
@@ -2170,7 +2170,7 @@ register boolean ininv, dummy, silent;
                return;
        }
 
-       if(obj->oclass == GOLD_CLASS) {
+       if(obj->oclass == COIN_CLASS) {
                costly_gold(obj->ox, obj->oy, obj->quan);
                return;
        }
@@ -2344,7 +2344,7 @@ register struct monst *shkp;
 
        if (Has_contents(obj))
            for(otmp = obj->cobj; otmp; otmp = otmp->nobj) {
-               if(otmp->oclass == GOLD_CLASS) continue;
+               if(otmp->oclass == COIN_CLASS) continue;
 
                if (Has_contents(otmp))
                    subfrombill(otmp, shkp);
@@ -2376,7 +2376,7 @@ register boolean ininv;
        /* the price of contained objects, if any */
        for(otmp = obj->cobj; otmp; otmp = otmp->nobj) {
 
-           if(otmp->oclass == GOLD_CLASS) continue;
+           if(otmp->oclass == COIN_CLASS) continue;
 
            if (!Has_contents(otmp)) {
                if(ininv) {
@@ -2410,7 +2410,7 @@ register boolean peaceful, silent;
        if (!shkp || !inhishop(shkp))
            return (0L);
 
-       if(obj->oclass == GOLD_CLASS) {
+       if(obj->oclass == COIN_CLASS) {
            gvalue += obj->quan;
        } else if (Has_contents(obj)) {
            register boolean ininv = !!count_unpaid(obj->cobj);
@@ -2443,7 +2443,7 @@ register boolean peaceful, silent;
                    }
                    still = "still ";
                }
-               if(obj->oclass == GOLD_CLASS)
+               if(obj->oclass == COIN_CLASS)
                    You("%sowe %s %ld %s!", still, mon_nam(shkp), value, currency(value));
                else You("%sowe %s %ld %s for %s!", still,
                        mon_nam(shkp),
@@ -2498,7 +2498,7 @@ xchar x, y;
        register struct eshk *eshkp;
        long ltmp = 0L, cltmp = 0L, gltmp = 0L, offer;
        boolean saleitem, cgold = FALSE, container = Has_contents(obj);
-       boolean isgold = (obj->oclass == GOLD_CLASS);
+       boolean isgold = (obj->oclass == COIN_CLASS);
        boolean only_partially_your_contents = FALSE;
 
        if(!(shkp = shop_keeper(*in_rooms(x, y, SHOPBASE))) ||
@@ -3592,7 +3592,7 @@ register xchar x, y;
        return(struct obj *)0;
 
     for (otmp = level.objects[x][y]; otmp; otmp = otmp->nexthere)
-       if (otmp->oclass != GOLD_CLASS)
+       if (otmp->oclass != COIN_CLASS)
            break;
     /* note: otmp might have ->no_charge set, but that's ok */
     return (otmp && costly_spot(x, y) && NOTANGRY(shkp)
@@ -3616,7 +3616,7 @@ register struct obj *first_obj;
     putstr(tmpwin, 0, "Fine goods for sale:");
     putstr(tmpwin, 0, "");
     for (otmp = first_obj; otmp; otmp = otmp->nexthere) {
-       if (otmp->oclass == GOLD_CLASS) continue;
+       if (otmp->oclass == COIN_CLASS) continue;
        cost = (otmp->no_charge || otmp == uball || otmp == uchain) ? 0L :
                get_cost(otmp, (struct monst *)0);
        if (Has_contents(otmp))
index e11bd23d129db93c1c821655f685d0f8fda089a1..2ce19612d853bddf9045e5d977d85337b9a41530 100644 (file)
--- a/src/sit.c
+++ b/src/sit.c
@@ -20,7 +20,7 @@ take_gold()
         struct obj *otmp;
        int lost_money = 0;
        for (otmp = invent; otmp; otmp = otmp->nobj) {
-               if (otmp->oclass == GOLD_CLASS) {
+               if (otmp->oclass == COIN_CLASS) {
                        lost_money = 1;
                        delobj(otmp);
                }
index 6224c0601126ea111231c8ae64b92dacf0d986fe..e86923d5b4408def5b58dfbe7fba9af8346769ff 100644 (file)
@@ -945,7 +945,7 @@ struct mkroom       *croom;
                panic("create_object:  unexpected object class '%c'",c);
 
            /* KMH -- Create piles of gold properly */
-           if (oclass == GOLD_CLASS)
+           if (oclass == COIN_CLASS)
                otmp = mkgold(0L, x, y);
            else
                otmp = mkobj_at(oclass, x, y, !named);
index 9f5fed4a11920cc85bd49b439419d7997fb608c6..7d11a8a3f9d8a0361be602172d986d50be8b668d 100644 (file)
@@ -431,7 +431,7 @@ register struct obj *otmp;
     int freed_otmp;
 
 #ifndef GOLDOBJ
-    if (otmp->oclass == GOLD_CLASS) {
+    if (otmp->oclass == COIN_CLASS) {
        mtmp->mgold += otmp->quan;
        obfree(otmp, (struct obj *)0);
        freed_otmp = 1;
index f3b9cfb3b36bca3bbfac86be02a6db3e25d243c5..da6839a628ee138a0afcbd81467e3e229153bee0 100644 (file)
@@ -215,7 +215,7 @@ static struct trobj Wishing[] = {
 };
 #ifdef GOLDOBJ
 static struct trobj Money[] = {
-       { GOLD_PIECE, 0 , GOLD_CLASS, 1, 0 },
+       { GOLD_PIECE, 0 , COIN_CLASS, 1, 0 },
        { 0, 0, 0, 0, 0 }
 };
 #endif
@@ -980,7 +980,7 @@ register struct trobj *trop;
                }
 
 #ifdef GOLDOBJ
-               if (trop->trclass == GOLD_CLASS) {
+               if (trop->trclass == COIN_CLASS) {
                        /* no "blessed" or "identified" money */
                        obj->quan = u.umoney0;
                } else {
index 0f380aa56d0d59c5a843df63e04247b9e363ed38..63fe7027cb609ebd10f527399903c1f57b94c8cb 100644 (file)
@@ -802,7 +802,7 @@ paygd()
 #else
         for (coins = invent; coins; coins = nextcoins) {
             nextcoins = coins->nobj;
-           if (objects[coins->otyp].oc_class == GOLD_CLASS) {
+           if (objects[coins->otyp].oc_class == COIN_CLASS) {
                freeinv(coins);
                 place_object(coins, gx, gy);
                stackobj(coins);
index deee40c82481e77da1aa6ad2b10fea3a27da2dfd..1d2c62eaf07264e76fc5104213ee9b77de3c80c1 100644 (file)
--- a/src/zap.c
+++ b/src/zap.c
@@ -2707,7 +2707,7 @@ struct obj *obj;                  /* object tossed/used */
                    range--;
            } else {
                if(weapon == KICKED_WEAPON &&
-                     ((obj->oclass == GOLD_CLASS &&
+                     ((obj->oclass == COIN_CLASS &&
                         OBJ_AT(bhitpos.x, bhitpos.y)) ||
                            ship_object(obj, bhitpos.x, bhitpos.y,
                                        costly_spot(bhitpos.x, bhitpos.y)))) {