mirror of
https://github.com/minetest-mods/unified_inventory.git
synced 2025-07-01 16:00:31 +02:00
Better door conditions
This commit is contained in:
@ -14,6 +14,7 @@ read_globals = {
|
|||||||
"ItemStack", "datastorage",
|
"ItemStack", "datastorage",
|
||||||
|
|
||||||
"hb",
|
"hb",
|
||||||
|
"doors",
|
||||||
}
|
}
|
||||||
|
|
||||||
files["callbacks.lua"].ignore = { "player", "draw_lite_mode" }
|
files["callbacks.lua"].ignore = { "player", "draw_lite_mode" }
|
||||||
|
@ -77,8 +77,11 @@ if unified_inventory.automatic_categorization then
|
|||||||
unified_inventory.add_category_item('environment', name)
|
unified_inventory.add_category_item('environment', name)
|
||||||
elseif def.light_source and def.light_source > 0 then
|
elseif def.light_source and def.light_source > 0 then
|
||||||
unified_inventory.add_category_item('lighting', name)
|
unified_inventory.add_category_item('lighting', name)
|
||||||
elseif doors and doors.registered_doors and doors.registered_doors[name..'_a'] or
|
elseif group.door or
|
||||||
doors and doors.registered_trapdoors and doors.registered_trapdoors[name] then
|
minetest.global_exists("doors") and (
|
||||||
|
doors.registered_doors and doors.registered_doors[name..'_a'] or
|
||||||
|
doors.registered_trapdoors and doors.registered_trapdoors[name] then
|
||||||
|
)
|
||||||
unified_inventory.add_category_item('building', name)
|
unified_inventory.add_category_item('building', name)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Reference in New Issue
Block a user