Guest User

Untitled

a guest
Feb 12th, 2016
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. function speed_bar(x, y)
  2. local barWidth = 25
  3. local barHeight = 280
  4. local precision = 200
  5. local speed_pct = math.min(math.floor(precision * (player.speed() - skiBarMin)/(skiBarMax - skiBarMin))/precision, 1)
  6.  
  7. drawRect(x, 2.03*y - barWidth, 2*x + barHeight, 2.03*y - barWidth/2, bg_color2)
  8. drawProgressBar(x, 2.03*y - barWidth, 2*x + barHeight, 2.03*y - barWidth/2, speed_color, 1, speed_pct)
  9. drawBox(x, 2.03*y - barWidth, 2*x + barHeight, 2.03*y - barWidth/2, health_energy_color_border)
  10. drawText(player.speed(), speed_color, 17*x, 2.045*y - barWidth, 1, 1, 1)
  11. end
Advertisement
Add Comment
Please, Sign In to add comment