Trying to set up a rollercoaster with triggers. The mice should change the colour of the coaster as it moves along the path but at the moment only the mouse1 collision works.
If I add another trigger, the last 2 block seems to always work but not the ones above.
Is there a limit to only 2 blocks running in parallel?
The problem there is that each object can have only one collision handler, so when the second
when collides block has executed it overrides the handler that was assigned to the
cat with previous block. But it’s easy to fix!
You just need to flip the arguments of
when collides block. Now each mouse have its own collision handler that sets the color of the
Also, we do have a bug in
run parallel block and it will be fixes in upcoming release.
Fortunately, there is no need in
run parallel block as all statements within
when collides block run as they were within
run separately (so introducing no execution blocking).
Take a look at the script below, it should work as you expected!