From 55224811750e763d26f08d3b839b24152c40c748 Mon Sep 17 00:00:00 2001 From: Rob Pearce Date: Wed, 12 Nov 2008 06:23:28 +0000 Subject: [PATCH] Adjusted appearance of forced speed powerup --- rc.c | 7 +++++-- shared.c | 1 - 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/rc.c b/rc.c index 877ae72..598ab0d 100644 --- a/rc.c +++ b/rc.c @@ -6184,8 +6184,11 @@ void dogravity(sprite_t *s) { if (boss) { // no fruits on boss levels s2->willbecome = -1; } else { - // if player isn't fast, give a speed. - if (!haspowerupany(P_SPEED)) { + int forcespeed = B_FALSE; + if (player && !player->dead && !haspowerup(player, P_SPEED)) forcespeed = B_TRUE; + if (player2 && !player2->dead && !haspowerup(player2, P_SPEED)) forcespeed = B_TRUE; + // if anyone is alive and not fast isn't fast, give a speed. + if (forcespeed) { s2->willbecome = P_SPEED; } else if (!gotcard & (gotsomething >= 4)) { // card for killing 5 at once s2->willbecome = getrandomcard(); diff --git a/shared.c b/shared.c index 9045d34..7b96ecb 100644 --- a/shared.c +++ b/shared.c @@ -2954,7 +2954,6 @@ int randompowerup(void) { int num; num = rand() % 34; -return P_PHONE; switch (num) { case 0: default: