for statement problem
ok so i was tring to add pillows in the form o stairsplus slabs made of wool i tried using a for cycle to irerate a list colors but all the colors i put in make the same slab and even in creative inventory it does not give me the other one
this is my code
this is my code
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
- Code: Select all
for index,color in pairs({'red','white'}) do
local material="wool:"..color
print(index)
print(color)
stairsplus.register_slab("wool", material,
{snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=3},
{"wool_"..color..".png"},
"wool " ..color.." pillow",
material)
print(color)
print(material)
end