Fix comma_value result treated as an int (#1087)

This commit is contained in:
Oscar 2020-05-09 16:32:19 +02:00 committed by GitHub
parent 190131a1b8
commit 28c2f46f13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -300,7 +300,7 @@ function onLevelChange(localPlayer, value, percent)
local hoursLeft = (nextLevelExp - localPlayer:getExperience()) / expPerHour
local minutesLeft = math.floor((hoursLeft - math.floor(hoursLeft))*60)
hoursLeft = math.floor(hoursLeft)
text = text .. '\n' .. tr('%d of experience per hour', comma_value(expPerHour))
text = text .. '\n' .. tr('%s of experience per hour', comma_value(expPerHour))
text = text .. '\n' .. tr('Next level in %d hours and %d minutes', hoursLeft, minutesLeft)
end
end