|
@@ -16,14 +16,16 @@ function HudLeft:draw()
|
|
if p then
|
|
if p then
|
|
local clip = tostring(p.slots[p.weapon].currentClip)
|
|
local clip = tostring(p.slots[p.weapon].currentClip)
|
|
local ammo = tostring(p.slots[p.weapon].currentAmmo)
|
|
local ammo = tostring(p.slots[p.weapon].currentAmmo)
|
|
-
|
|
|
|
- g.setFont('BebasNeue', h(.065))
|
|
|
|
- local font = g:getFont()
|
|
|
|
- g.setColor(255, 255, 255)
|
|
|
|
- g.printCenter(clip .. ' /', w(.055), -h(.004), true, false)
|
|
|
|
-
|
|
|
|
- g.setFont('BebasNeue', h(.045))
|
|
|
|
- g.setColor(255, 255, 255, 153)
|
|
|
|
- g.printCenter(ammo, w(.0575) + (font:getWidth(clip .. ' /') / 2) + (g.getFont():getWidth(ammo) / 2), h(.015), true, false)
|
|
|
|
|
|
+
|
|
|
|
+ if clip ~= 'nil' and ammo ~= 'nil' then
|
|
|
|
+ g.setFont('BebasNeue', h(.065))
|
|
|
|
+ local font = g:getFont()
|
|
|
|
+ g.setColor(255, 255, 255)
|
|
|
|
+ g.printCenter(clip .. ' /', w(.055), -h(.004), true, false)
|
|
|
|
+
|
|
|
|
+ g.setFont('BebasNeue', h(.045))
|
|
|
|
+ g.setColor(255, 255, 255, 153)
|
|
|
|
+ g.printCenter(ammo, w(.0575) + (font:getWidth(clip .. ' /') / 2) + (g.getFont():getWidth(ammo) / 2), h(.015), true, false)
|
|
|
|
+ end
|
|
end
|
|
end
|
|
end
|
|
end
|