I want to make a rule where if one color of object is touching the same color of object and you click one of them they will both be removed. Any ideas?
make 2 seperate integer attributes for each colour you want. lets use blue as an example.
BlueContact KillBlue
Have both of those set to 0
Inside the blue actor have . . Rule when actor overlaps/collides with actor Blue . change attribute game.BlueContact to 1 . . . Now have a seperate rule . When actor receives touch is pressed and game.BlueContact = 1 . change attribute game.Killblue to 1
and last rule When attribute game.KillBlue = 1 . Destroy behaviour
When you say destroy behavior do you mean destroy the actor? Because I wan't to be able to click on one of them but if 2 of them are touching it will delete both the actors with one click.
check that the trigger for the Contact attribute is setup properly. are you using boolean or integers? i can have a look at the project if you want me to.
Comments
BlueContact
KillBlue
Have both of those set to 0
Inside the blue actor have
.
.
Rule when actor overlaps/collides with actor Blue
.
change attribute game.BlueContact to 1
.
.
.
Now have a seperate rule
.
When actor receives touch is pressed and game.BlueContact = 1
.
change attribute game.Killblue to 1
and last rule When attribute game.KillBlue = 1
.
Destroy behaviour
just do that for all your coloured objects