Make GOLDOBJ unconditional.
This commit is contained in:
@@ -45,18 +45,6 @@ int shotlimit;
|
||||
boolean twoweap, weakmultishot;
|
||||
|
||||
/* ask "in what direction?" */
|
||||
#ifndef GOLDOBJ
|
||||
if (!getdir((char *)0)) {
|
||||
if (obj->oclass == COIN_CLASS) {
|
||||
u.ugold += obj->quan;
|
||||
context.botl = 1;
|
||||
dealloc_obj(obj);
|
||||
}
|
||||
return(0);
|
||||
}
|
||||
|
||||
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 */
|
||||
freeinv(obj);
|
||||
@@ -73,7 +61,6 @@ int shotlimit;
|
||||
possibly using a sling.
|
||||
*/
|
||||
if(obj->oclass == COIN_CLASS && obj != uquiver) return(throw_gold(obj));
|
||||
#endif
|
||||
|
||||
if(!canletgo(obj,"throw"))
|
||||
return(0);
|
||||
@@ -1833,34 +1820,18 @@ throw_gold(obj)
|
||||
struct obj *obj;
|
||||
{
|
||||
int range, odx, ody;
|
||||
#ifndef GOLDOBJ
|
||||
long zorks = obj->quan;
|
||||
#endif
|
||||
register struct monst *mon;
|
||||
|
||||
if(!u.dx && !u.dy && !u.dz) {
|
||||
#ifndef GOLDOBJ
|
||||
u.ugold += obj->quan;
|
||||
context.botl = 1;
|
||||
dealloc_obj(obj);
|
||||
#endif
|
||||
You("cannot throw gold at yourself.");
|
||||
return(0);
|
||||
}
|
||||
#ifdef GOLDOBJ
|
||||
freeinv(obj);
|
||||
#endif
|
||||
if(u.uswallow) {
|
||||
pline(is_animal(u.ustuck->data) ?
|
||||
"%s in the %s's entrails." : "%s into %s.",
|
||||
#ifndef GOLDOBJ
|
||||
"The gold disappears", mon_nam(u.ustuck));
|
||||
u.ustuck->mgold += zorks;
|
||||
dealloc_obj(obj);
|
||||
#else
|
||||
"The money disappears", mon_nam(u.ustuck));
|
||||
add_to_minv(u.ustuck, obj);
|
||||
#endif
|
||||
return(1);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user