Registering collisions between non-physical objects

Hi.
This has been really stumping me. How do I Register collisions between two display objects? My goal is that every time they contact, I get a score and they decay. Both have simple transitions and no physics are involved. I’ve looked in every possible place but have found no answers.
Any help would be much appreciated!

[import]uid: 66329 topic_id: 19108 reply_id: 319108[/import]

Long answer short - You can’t!
Why not just have them as physics objects?

You can use collision filters to control which objects can collide?
http://developer.anscamobile.com/forum/2010/10/25/collision-filters-helper-chart [import]uid: 64174 topic_id: 19108 reply_id: 73657[/import]

Or If you really do not want to have physics bodies, have an “enterFrame” listener and check the contentBounds properties of both objects every frame… If they overlap then you can perform your collision operations…

http://developer.anscamobile.com/reference/index/objectcontentbounds [import]uid: 64174 topic_id: 19108 reply_id: 73658[/import]

Thank you for reply.
The more I look in to it, the I think physic are the way to go.
The only problem is that I don’t know where to start. Any suggestions? [import]uid: 66329 topic_id: 19108 reply_id: 73660[/import]

Take a look at Corona For Newbies Part 4 (on Techority) and have a read up about Sensors. (There’s a simple post about those on Techority as well.)

That should get you started :slight_smile:

Peach

PS - I deleted the dupe thread, I know it wasn’t intentional :slight_smile: [import]uid: 52491 topic_id: 19108 reply_id: 73669[/import]

This is a frequently asked question here in the forums. So I decided a blog post was in order. Please see:

http://omnigeek.robmiracle.com/2011/12/14/collision-detection-without-physics/
Enjoy!
[import]uid: 19626 topic_id: 19108 reply_id: 73845[/import]