Hi, I have about 50 or more gui-images to make visible / invisible but im getting all errors - @'guiSetVisible' expected element at argument 1, got string "button_1_img"
I need to use a loop to concat and change button numbers 1-50. How to actually make this work?
-- button elements
button_1_img = guiCreateStaticImage ( 500, 500, 32, 32, "img/buttons/button_select.png", false, main_window )
button_2_img = guiCreateStaticImage ( 550, 500, 32, 32, "img/buttons/button_select.png", false, main_window )
button_3_img = guiCreateStaticImage ( 600, 500, 32, 32, "img/buttons/button_select.png", false, main_window )
button_4_img = guiCreateStaticImage ( 650, 500, 32, 32, "img/buttons/button_select.png", false, main_window )
button_5_img = guiCreateStaticImage ( 700, 500, 32, 32, "img/buttons/button_select.png", false, main_window )
-- + 45
for index=1,50 do
guiSetVisible ( "button_"..index.."_img", true )
end