I have encountered some strange results in my attempts at my 1st game.
I am pinning rocks onto walls. Yet when the spaceship is rotated rapidly they are destroyed, but only yellow rocks (they should not be!)
Hard to describe, but you can take a look at the capx and spin around after some rocks stick to the ship. You will be left with only red rocks.
normally to fix this kind of error you would just rearrange the order of the events so that first the ship is angled, and then the rocks are positioned and angled (due to pinbehaviour), and then at the end of the event sheet check for collision.
However due to these actions being performed by a behaviour, you can't seem to change this order.
One thing you can do though is to add an instance variable for example "Destroyable" to the rocks, and set it's default to 1
When the rock sticks to the opposite coloured wall, set destroyable to 0
and then in the events where the rock collides with the same coloured wall add another condition to check if destroyable= 1
Develop games in your browser. Powerful, performant & highly capable.
Another option is to pin the rocks to the ship instead of to the walls.
Thanks Keepee, your solution solved the problem!