That's all about picking the right instances.
Some of it will depend oh how you let the user do the selecting.
After the user has selected the instances you could use the system pick instances actions to only perform actions on the selected instances.
There are many ways to go about the selecting. you could use instance variables. Somteimes creating a sprite to show an object is selected can be used in overlapping comparison.
So when you have found a way to identify the selected objects/instances, that can be used for the system to pick them and only perform actions on them.