Tetris game by Igor Pro

I programed a tetris game by Igor pro which shows  Igor's outstanding data calculation and live visualization capabilities. 

Who are  interested  can find this game at the following link:

https://www.wavemetrics.com/node/21698.

tetris playfiled

On Windows, after pressing the Start button, the space key restarts the game.

This is the solution:

Function ButtonProc(ctrlName) : ButtonControl
    String ctrlName
    Button $ctrlName, disable=2 // so that the space key doesn't restart the game
    startgame()
End

Function endgame()
    ctrlNamedBackground task1,proc=RunningGame,stop
    ctrlNamedBackground task2,proc=playbg,stop
    wave bg0
    Playsound/A=2 bg0
    Button button0, disable=0 // allow restarting the game
End

A very well done game!