问题描述:

I have problem, as you can see I want to delete all objects in corona. I'm looking for one function that will remove all of them.

I can't find it, I'm not sure if it's even possible.

I'd like it to work like this:

  1. Display all objects
  2. Wait for event
  3. When you touch, then remove all objects from 1 and go back to it.

Possible or not?

网友答案:

I'm not aware of one function that does that. But what you can do is every time you create an object you put it in a table. Then when you want to remove them all you iterate over the table and call removeSelf on each. After the loop, you reset the table. See my answer to remove all spawned coins.

相关阅读:
Top