X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=actions.c;h=5d1c6a391b6d7426bec7401812ce321e0b9e81aa;hb=43032763cdb923c2b8328933acfe6efeaced3bbd;hp=c539554def21da2147568e2423cb5782aa131470;hpb=8cdbf034a2601025c04d8080455abbc1c0aad3c0;p=open-adventure.git diff --git a/actions.c b/actions.c index c539554..5d1c6a3 100644 --- a/actions.c +++ b/actions.c @@ -118,7 +118,10 @@ static int bigwords(long foo) return 2012; } else { game.foobar=k; - if (k != 4) return(2009); + if (k != 4) { + RSPEAK(54); + return 2012; + } game.foobar=0; if (game.place[EGGS]==PLAC[EGGS] || (TOTING(EGGS) && game.loc==PLAC[EGGS])) { RSPEAK(SPK); @@ -177,8 +180,8 @@ static int vbreak(token_t obj) game.fixed[VASE]= -1; } else { if (obj == MIRROR && game.closed) { - SPK=197; - return(18999); + RSPEAK(197); + return(190000); } } RSPEAK(SPK); @@ -263,11 +266,12 @@ static int carry(long obj) CARRY(obj,game.loc); if (obj == BOTTLE && LIQUID() != 0) game.place[LIQUID()] = -1; - if (!GSTONE(obj) || game.prop[obj] == 0) - return(2009); - game.prop[obj]=0; - game.prop[CAVITY]=1; - return(2009); + if (GSTONE(obj) && game.prop[obj] != 0) { + game.prop[obj]=0; + game.prop[CAVITY]=1; + } + RSPEAK(54); + return(2012); } static int chain(token_t verb) @@ -922,8 +926,8 @@ static int wake(token_t obj) /* Wake. Only use is to disturb the dwarves. */ { if (obj != DWARF || !game.closed) {RSPEAK(SPK); return 2012;} - SPK=199; - return(18999); + RSPEAK(199); + return(19000); } static int wave(token_t obj) @@ -945,7 +949,10 @@ static int wave(token_t obj) RSPEAK(SPK); return 2012; } else { - if (game.closed) return(18999); + if (game.closed) { + RSPEAK(SPK); /* FIXME: How is SPK set here? */ + return(19000); + } if (game.closng || !AT(FISSUR)) {RSPEAK(SPK); return 2012;} if (HERE(BIRD))RSPEAK(SPK); game.prop[FISSUR]=1-game.prop[FISSUR]; @@ -1028,7 +1035,7 @@ int action(FILE *input, enum speechpart part, long verb, long obj) case 1: /* DROP */ return(8000); case 2: /* SAY */ return(8000); case 3: /* UNLOC */ return lock(verb, INTRANSITIVE); - case 4: /* NOTHI */ return(2009); + case 4: /* NOTHI */ {RSPEAK(54); return(20012);} case 5: /* LOCK */ return lock(verb, INTRANSITIVE); case 6: /* LIGHT */ return light(INTRANSITIVE); case 7: /* EXTIN */ return extinguish(INTRANSITIVE); @@ -1069,7 +1076,7 @@ int action(FILE *input, enum speechpart part, long verb, long obj) case 1: /* DROP */ return discard(obj, false); case 2: /* SAY */ return say(); case 3: /* UNLOC */ return lock(verb, obj); - case 4: /* NOTHI */ return(2009); + case 4: /* NOTHI */ {RSPEAK(54); return(20012);} case 5: /* LOCK */ return lock(verb, obj); case 6: /* LIGHT */ return light(obj); case 7: /* EXTI */ return extinguish(obj);