remove xp desc.
This commit is contained in:
parent
69f2827805
commit
969e03b2d5
10
init.lua
10
init.lua
@ -70,8 +70,6 @@ function wine:add_item(list)
|
||||
end
|
||||
|
||||
-- helper function
|
||||
local mod_tt_base = minetest.get_modpath("tt_base") -- mod does similar to infotext
|
||||
|
||||
function wine.add_eatable(item, hp)
|
||||
|
||||
local def = minetest.registered_items[item]
|
||||
@ -79,16 +77,10 @@ function wine.add_eatable(item, hp)
|
||||
if def then
|
||||
|
||||
local groups = table.copy(def.groups) or {}
|
||||
local txt = " (" ; if hp > 0 then txt = txt .. "+" end
|
||||
txt = txt .. hp .. " HP)"
|
||||
|
||||
groups.eatable = hp ; groups.flammable = 2
|
||||
|
||||
if mod_tt_base == nil then
|
||||
def.description = def.description .. txt
|
||||
end
|
||||
|
||||
minetest.override_item(item, {description = def.description, groups = groups})
|
||||
minetest.override_item(item, {groups = groups})
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user