How to delete external layout objects

Hello Everyone:

I want to know if there is a action/command that can remove all objects from a specific external layout.

Let’s say you have two external layouts called “enemy formation 1” and “enemy formation 2”. At the beginning of the scene you load external layout “enemy formation 1”, but at some point in the game you want to remove all those enemies and load external layout “enemy formation 2”.

Is there is a action/command that can remove all objects from a specific external layout in the above example?

There is not. Once you create objects from an external layout, they’re now part of the current scene and no longer have any relation to the external layout.

If you want to be able to address those objects directly, generally what I’ve recommended is to add them to a Global Object Group in the external layout. Then you can call them via that group name with events after creating them, including a “Delete GlobalObjectGroupName” event to delete all of them.

1 Like

Thanks a million for the help and the recommended solution. I’ll try to implement the recommendation you have.
Thank you again.

1 Like