Fix fail when damaged with 6 new armor pieces

This commit is contained in:
Wuzzy 2016-08-05 20:08:11 +02:00
parent 3d36b82a00
commit 556f91b5c6
1 changed files with 1 additions and 1 deletions

View File

@ -31,7 +31,7 @@ function hbarmor.set_armor(player_name, ges_state, items)
lvl = 0
end
hbarmor.armor[player_name] = lvl* (items * (100 / max_items))
hbarmor.armor[player_name] = math.min(lvl* (items * (100 / max_items)), 100)
end