Use mcl_formspec.get_itemslot_bg_v4 instead of mcl_formspec.get_itemslot_bg
This commit is contained in:
@@ -73,14 +73,14 @@ function industrialtest.ToolWorkshop.getFormspec(self,pos)
|
||||
local meta=minetest.get_meta(pos)
|
||||
local powerPercent=meta:get_int("industrialtest.powerAmount")/meta:get_int("industrialtest.powerCapacity")*100
|
||||
local formspec={
|
||||
"list[context;powerStorage;3.7,3.7;1,1;0]",
|
||||
industrialtest.internal.getItemSlotBg(3.7,3.7,1,1),
|
||||
"list[context;powerStorage;3.7,3.7;1,1;0]",
|
||||
(powerPercent>0 and "image[3.7,2.5;1,1;industrialtest_gui_electricity_bg.png^[lowpart:"..powerPercent..":industrialtest_gui_electricity_fg.png]"
|
||||
or "image[3.7,2.5;1,1;industrialtest_gui_electricity_bg.png]"),
|
||||
"list[context;src;5.9,3.2;1,1;0]",
|
||||
industrialtest.internal.getItemSlotBg(5.9,3.2,1,1),
|
||||
"list[context;upgrades;9,0.9;1,4]",
|
||||
"list[context;src;5.9,3.2;1,1;0]",
|
||||
industrialtest.internal.getItemSlotBg(9,0.9,1,4),
|
||||
"list[context;upgrades;9,0.9;1,4]",
|
||||
"listring[context;src]"
|
||||
}
|
||||
return parentFormspec..table.concat(formspec,"")
|
||||
|
||||
Reference in New Issue
Block a user