force wield_scale to number value

This commit is contained in:
Freedom 2023-10-20 16:30:30 +02:00
parent 3d7155c1b9
commit 7e2abc5b01
1 changed files with 1 additions and 1 deletions

View File

@ -675,7 +675,7 @@ minetest.register_entity(":__builtin:item", {
glow = def.light_source
end
local s = 0.2 + 0.1 * (count / max_count)
local wield_scale = (def and def.wield_scale and def.wield_scale.x) or 1
local wield_scale = tonumber((def and def.wield_scale and def.wield_scale.x)) or 1
local c = s
s = s / wield_scale
local prop = {