classes and collisions

To implement collision detection in Corona I use its Box2d I believe.

Now I wanted to implement things like this in a class but notice OOP and lua ?

I dont want to code everything in 1 file so what do I do?
[import]uid: 138547 topic_id: 24311 reply_id: 324311[/import]

You can have collision detection spread across different files/classes/etc.

So long as you have one object listening for collision it will register it regardless of where it and the other object are coming from.

It’s not unlike the code when everything is in main :slight_smile: [import]uid: 52491 topic_id: 24311 reply_id: 98447[/import]