From: MirceaKitsune Date: Thu, 17 Nov 2011 17:43:36 +0000 (+0200) Subject: Code functionality for ammo digits. Grabber display is now fully functional, but... X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=a0b7e67446ec1cacab022c16314b25891d77d1b4;p=voretournament%2Fvoretournament.git Code functionality for ammo digits. Grabber display is now fully functional, but note it will show wrong values if your ammo drops under 3 digits (a bug that will need to be fixed). --- diff --git a/data/qcsrc/server/cl_weaponsystem.qc b/data/qcsrc/server/cl_weaponsystem.qc index 015fb264..2d55ff26 100644 --- a/data/qcsrc/server/cl_weaponsystem.qc +++ b/data/qcsrc/server/cl_weaponsystem.qc @@ -1630,6 +1630,12 @@ void W_DisplayDigitThink() self.skin = stof(txt); } } + else // ammo display + { + txt = ftos(self.owner.(self.owner.current_ammo)); + txt = substring(txt, self.cnt - 1, 1); + self.skin = stof(txt); + } self.nextthink = time; }