How to make two blocks work at once

Guys, how do i make two blocks function at once? I am trying to make game function where a wall toggles on and off every few seconds.

Is there an easier way to do this or is there something I dont know about, please tell me

3 Likes

Switch blue to a 3rd temporary tile, switch red to blue, and then switch the 3rd temporary tile to red.

1 Like

Try using a forever block with pause blocks. then it should work.

example(warning, this is meant for block code concept, this will not work as actual text code):

loop

{

(optional if

if myVar=0 then)

set wall [off] at all locations

replace all tiles with

pause until [100]

set wall [on] at all locations

replace all tiles with

}

make a boolean variable so that every time the code updates, it toggles the variable. if the variable is true, set blue walls and destroy red walls, otherwise set red walls and destroy blue walls