It worked fine. I attached the current version experiment so you can take a look at it.
I added another sound to signalize to the subject that they avoided the shock successfully and limited the number of avoidance "trials" (blocks 2 and 3). These are working great as well.
However, I tried to present blocks 2 and 3 not only after 6 seconds, which is working, but also if two successful shuttles are achieved, which is not. This later rule I tried to count the number of successful shuttles in a correspondent parameter and limit the presentations of this parameter in a rule included in the block. Why is it not working?
Another problem is that, sometimes, the first time the virtual subject touches one of the grid if being computed as a successful shuttle, sometimes it is not. I couldn't figure it out why...