Advertisement
Guest User

Untitled

a guest
Dec 18th, 2014
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.73 KB | None | 0 0
  1. local colHealth = Color(0, 0, 0, 240)
  2. local function ContentsPaint(self)
  3.    
  4. --[[    local lp = LocalPlayer()
  5.     if lp:IsValid() then
  6.         local health = math.max(lp:Health(), 0)
  7.         local healthperc = math.Clamp(health / lp:GetMaxHealthEx(), 0, 1)
  8.  
  9.         colHealth.r = (1 - healthperc) * 180
  10.         colHealth.g = healthperc * 180
  11.  
  12.         draw.SimpleTextBlurry(health, "ZSHUDFont", 8, self:GetTall() - 8, colHealth, TEXT_ALIGN_LEFT, TEXT_ALIGN_TOP)
  13.         surface.SetDrawColor(Color(255,255,255,255))
  14.         surface.SetMaterial(AmmoRing)
  15.         --surface.DrawTexturedRect(w * -0.2, h * -0.25, w * 0.4, w * 0.4)
  16.         local hparts = NiceUV(ScrW() * 0.5, ScrH() * 0.5, 100, 100, math.Clamp(lp:Health(), 0, lp:GetMaxHealthEx()) / lp:GetMaxHealthEx() * 360, true )
  17.     end ]]
  18. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement