forked from VoxeLibre/VoxeLibre
WIP: Survival inventory and mcl_chest formspec overhaul. #1
|
@ -52,15 +52,6 @@ function return_fields(player, name)
|
||||||
end
|
end
|
||||||
|
|
||||||
local function set_inventory(player, armor_change_only)
|
local function set_inventory(player, armor_change_only)
|
||||||
local margin = mcl_formspec.margin
|
|
||||||
local padding = mcl_formspec.padding
|
|
||||||
local bu = mcl_formspec.itemslot_bu
|
|
||||||
local iu = mcl_formspec.itemslot_iu
|
|
||||||
|
|
||||||
local label_color = mcl_formspec.label_color
|
|
||||||
local label_height = mcl_formspec.label_height
|
|
||||||
local label_y_offset = mcl_formspec.label_y_offset
|
|
||||||
|
|
||||||
if minetest.is_creative_enabled(player:get_player_name()) then
|
if minetest.is_creative_enabled(player:get_player_name()) then
|
||||||
if armor_change_only then
|
if armor_change_only then
|
||||||
-- Stay on survival inventory plage if only the armor has been changed
|
-- Stay on survival inventory plage if only the armor has been changed
|
||||||
|
@ -71,6 +62,15 @@ local function set_inventory(player, armor_change_only)
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local margin = mcl_formspec.margin
|
||||||
|
local padding = mcl_formspec.padding
|
||||||
|
local bu = mcl_formspec.itemslot_bu
|
||||||
|
local iu = mcl_formspec.itemslot_iu
|
||||||
|
|
||||||
|
local label_color = mcl_formspec.label_color
|
||||||
|
local label_height = mcl_formspec.label_height
|
||||||
|
local label_y_offset = mcl_formspec.label_y_offset
|
||||||
|
|
||||||
local inv = player:get_inventory()
|
local inv = player:get_inventory()
|
||||||
inv:set_width("craft", 2)
|
inv:set_width("craft", 2)
|
||||||
inv:set_size("craft", 4)
|
inv:set_size("craft", 4)
|
||||||
|
|
Loading…
Reference in New Issue