1
0
Fork 0

add basic temp function to get v4 itemslots

This commit is contained in:
AFCMS 2021-04-25 23:35:27 +02:00
parent d3fb221641
commit ac4db102b2
Signed by untrusted user: AFCMS
GPG Key ID: 8720389A25B652E3
1 changed files with 12 additions and 0 deletions

View File

@ -9,3 +9,15 @@ function mcl_formspec.get_itemslot_bg(x, y, w, h)
end end
return out return out
end end
--This function will replace mcl_formspec.get_itemslot_bg then every formspec will be upgrade to version 4
function mcl_formspec.get_itemslot_bg_v4(x, y, w, h)
local out = ""
for i = 0, w - 1, 1 do
for j = 0, h - 1, 1 do
out = out .."image["..x+i+(i*0.25)..","..y+j+(j*0.25)..";1,1;mcl_formspec_itemslot.png]"
end
end
return out
end