From dfb6d25e2fea778a469362789ce1eb04c66be887 Mon Sep 17 00:00:00 2001 From: Mircea Kitsune Date: Fri, 11 Feb 2011 22:42:15 +0200 Subject: [PATCH] No need to use floats when calling W_ReloadCheck, as we have the current globals to use directly. --- qcsrc/server/cl_weaponsystem.qc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qcsrc/server/cl_weaponsystem.qc b/qcsrc/server/cl_weaponsystem.qc index 68873fa1a..db2202e89 100644 --- a/qcsrc/server/cl_weaponsystem.qc +++ b/qcsrc/server/cl_weaponsystem.qc @@ -1633,7 +1633,7 @@ void W_DecreaseAmmo(.float ammo_type, float ammo_use, float ammo_reload) .float reload_complain; .string reload_sound; -float W_ReloadCheck(float ammo_amount, float ammo_shot) +float W_ReloadCheck() { // check if we meet the necessary conditions to reload @@ -1656,7 +1656,7 @@ float W_ReloadCheck(float ammo_amount, float ammo_shot) return FALSE; // no ammo, so nothing to load - if(!ammo_amount && ammo_shot) + if(!self.(self.current_ammo) && self.reload_ammo_min) { if(clienttype(self) == CLIENTTYPE_REAL && self.reload_complain < time) { @@ -1738,7 +1738,7 @@ void W_Reload(float sent_ammo_min, float sent_ammo_amount, float sent_time, stri self.reload_time = sent_time; self.reload_sound = sent_sound; - if(!W_ReloadCheck(self.(self.current_ammo), self.reload_ammo_min)) + if(!W_ReloadCheck()) return; // now we can begin the actual reloading -- 2.39.2