]> de.git.xonotic.org Git - voretournament/voretournament.git/commitdiff
Hopefully fix a bug causing ammo to get to negative values sometimes
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Mon, 11 Jul 2011 12:54:33 +0000 (15:54 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Mon, 11 Jul 2011 12:54:33 +0000 (15:54 +0300)
data/qcsrc/server/cl_weaponsystem.qc

index f6ae23fa4cfd090944635dd16a9f30de80ec48db..15e50eb47d8894db021ae54f88c8f80de73b9042 100644 (file)
@@ -1614,7 +1614,7 @@ void W_ReloadedAndReady()
                self.clip_load = self.reload_ammo_amount;\r
        else\r
        {\r
-               while(self.clip_load < self.reload_ammo_amount && self.(self.current_ammo)) // make sure we don't add more ammo than we have\r
+               while(self.clip_load < self.reload_ammo_amount && self.(self.current_ammo) >= 1) // make sure we don't add more ammo than we have\r
                {\r
                        self.clip_load += 1;\r
                        self.(self.current_ammo) -= 1;\r