Add classes
This commit is contained in:
parent
bc9967907e
commit
34d891c6c5
18 changed files with 257 additions and 6 deletions
|
@ -33,8 +33,8 @@ function hp_bar:on_step(dtime)
|
|||
return
|
||||
end
|
||||
|
||||
local hp = wielder:get_hp()
|
||||
local breath = wielder:get_breath()
|
||||
local hp = math.floor(20 * wielder:get_hp() / wielder:get_properties().hp_max)
|
||||
local breath = math.floor(20 * wielder:get_breath() / wielder:get_properties().breath_max)
|
||||
self.object:set_properties({
|
||||
textures = {
|
||||
"health_" .. tostring(hp) .. ".png^breath_" .. tostring(breath) .. ".png",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue