Vlad's throne rebalance
This removes the container-cursing effect (which is too specific and too easy to work around) and replaces it with an effect that greases everything (largely but not entirely positive).
This commit is contained in:
@@ -2583,6 +2583,8 @@ grease_ok(struct obj *obj)
|
||||
if (!obj)
|
||||
return GETOBJ_SUGGEST;
|
||||
|
||||
/* note: if changing the list of ungreasable objects, also change
|
||||
special_throne_effect in sit.c */
|
||||
if (obj->oclass == COIN_CLASS)
|
||||
return GETOBJ_EXCLUDE;
|
||||
|
||||
|
||||
31
src/sit.c
31
src/sit.c
@@ -7,7 +7,6 @@
|
||||
#include "artifact.h"
|
||||
|
||||
staticfn void throne_sit_effect(void);
|
||||
staticfn void rndcurse_inner(boolean);
|
||||
staticfn int lay_an_egg(void);
|
||||
|
||||
/* take away the hero's money */
|
||||
@@ -265,9 +264,20 @@ special_throne_effect(int effect) {
|
||||
}
|
||||
break;
|
||||
case 6:
|
||||
/* containers become cursed */
|
||||
rndcurse_inner(TRUE);
|
||||
{
|
||||
/* grease hands and inventory
|
||||
|
||||
Same rules for which items can be affected as grease_ok in apply.c */
|
||||
struct obj *otmp;
|
||||
|
||||
pline("A greasy liquid sprays all over you!");
|
||||
for (otmp = gi.invent; otmp; otmp = otmp->nobj)
|
||||
if (otmp->oclass != COIN_CLASS)
|
||||
otmp->greased = 1;
|
||||
make_glib(rn1(101, 100));
|
||||
update_inventory();
|
||||
break;
|
||||
}
|
||||
case 7:
|
||||
/* lose an intrinsic */
|
||||
attrcurse();
|
||||
@@ -313,7 +323,8 @@ special_throne_effect(int effect) {
|
||||
break;
|
||||
}
|
||||
case 11:
|
||||
/* polymorph effect (not blocked by magic resistance) */
|
||||
/* polymorph effect (not blocked by magic resistance, but other things
|
||||
that protect from polymorphs work) */
|
||||
pline("This throne was not meant for those such as you!");
|
||||
You_feel("a change coming over you.");
|
||||
polyself(POLY_NOFLAGS);
|
||||
@@ -552,12 +563,6 @@ dosit(void)
|
||||
/* curse a few inventory items at random! */
|
||||
void
|
||||
rndcurse(void)
|
||||
{
|
||||
rndcurse_inner(FALSE);
|
||||
}
|
||||
|
||||
staticfn void
|
||||
rndcurse_inner(boolean prefer_containers)
|
||||
{
|
||||
int nobj = 0;
|
||||
int cnt, onum;
|
||||
@@ -579,13 +584,9 @@ rndcurse_inner(boolean prefer_containers)
|
||||
/* gold isn't subject to being cursed or blessed */
|
||||
if (otmp->oclass == COIN_CLASS)
|
||||
continue;
|
||||
if (prefer_containers && !otmp->cobj)
|
||||
continue;
|
||||
nobj++;
|
||||
}
|
||||
cnt = rnd(6 / ((!!Antimagic) + (!!Half_spell_damage) + 1));
|
||||
if (prefer_containers)
|
||||
cnt = nobj * 2;
|
||||
if (nobj) {
|
||||
for (; cnt > 0; cnt--) {
|
||||
onum = rnd(nobj);
|
||||
@@ -593,8 +594,6 @@ rndcurse_inner(boolean prefer_containers)
|
||||
/* as above */
|
||||
if (otmp->oclass == COIN_CLASS)
|
||||
continue;
|
||||
if (prefer_containers && !otmp->cobj)
|
||||
continue;
|
||||
if (--onum == 0)
|
||||
break; /* found the target */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user