I'm trying to make a maze-type game. The idea is that the background is a group of squares, each containing a symbol. A sprite travels among the squares, but it has to only touch certain symbols. If it touches the wrong one, it has to start back at the beginning. I made a sprite that is the grid of the wrong squares. When my traveling sprite "touches" the grid, the level resets. Which works perfectly until I hide the grid. Then the traveling sprite goes right through the grid as if it wasn't there. According to this thread: http://scratch.mit.edu/forums/viewtopic.php?id=28 that shouldn't happen - even when hidden, the grid should be able to touch the moving sprite. What am I doing wrong? The "touching" code is in the grid script, not the moving sprite's script.
Offline
Hide doesn't work like that. Instead of using hide try using ghost 99 or ghost 100.
The thread you linked to points out that hidden objects can detect using the if touching block but that it won't work in the inverse.
Last edited by Smozzick (2013-03-09 10:36:43)
Offline
Thank you. Ghosting does work.
Offline