Display amount healed as an integer in [heal_unit]

This commit is contained in:
Celtic Minstrel 2018-04-16 01:27:12 -04:00 committed by GitHub
parent 7821f470c2
commit 0294bd81b2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -38,7 +38,7 @@ function wesnoth.wml_actions.heal_unit(cfg)
if cfg.animate then
local animator = wesnoth.create_animator()
if heal_amount > 0 then
animator:add(u, 'healed', 'hit', {value = heal_amount, text = heal_amount, color = {0, 255, 0}})
animator:add(u, 'healed', 'hit', {value = heal_amount, text = math.tointeger(heal_amount), color = {0, 255, 0}})
end
if #healers > 0 then
animator:add(healers[1], 'healing', 'hit', {value = heal_amount})