summaryrefslogtreecommitdiff
path: root/src/game/bg_misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/bg_misc.c')
-rw-r--r--src/game/bg_misc.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c
index 02db5993..59c76e3a 100644
--- a/src/game/bg_misc.c
+++ b/src/game/bg_misc.c
@@ -5445,6 +5445,25 @@ qboolean BG_PlayerCanChangeWeapon( playerState_t *ps )
}
/*
+=================
+BG_PlayerPoisonCloudTime
+=================
+*/
+int BG_PlayerPoisonCloudTime( playerState_t *ps )
+{
+ int time = LEVEL1_PCLOUD_TIME;
+
+ if( BG_InventoryContainsUpgrade( UP_BATTLESUIT, ps->stats ) )
+ time -= BSUIT_PCLOUD_PROTECTION;
+ if( BG_InventoryContainsUpgrade( UP_HELMET, ps->stats ) )
+ time -= HELMET_PCLOUD_PROTECTION;
+ if( BG_InventoryContainsUpgrade( UP_LIGHTARMOUR, ps->stats ) )
+ time -= LIGHTARMOUR_PCLOUD_PROTECTION;
+
+ return time;
+}
+
+/*
===============
atof_neg