Use a sub-sub or a function.
A function starts picking from scratch. (so, including ever instance again)
A sub-sub will not change the parent picklist.
Sprite > Compare frame <--- pick all with a certain frame = Parent Picklist
System > compare 2 values .. Sprite.Count = Sprite.PickedCount
______Just an empty sub event
________sub under that empty event ... System > Pick All (Sprite) <------ this is the Sub Picklist / Parent is unchanged when returning to parent level
______________action : do your stuff
Thing is now, be careful with this 'PickedCount'. If you wanna do something when none of them have this frame .... Then the 'Sprite.Count = Sprite.PickedCount' will not ever run. Not as sub, not as second in a parent.
So just to be complete ...
Sprite > Compare frame
System > compare 2 values .. Sprite.Count = Sprite.PickedCount
______Just an empty sub event
________sub under that empty event ... System > Pick All (Sprite)
______________action : do your stuff
Else
_____Actions to take care of the exception where the first event will not run.
Additional. Testing for an animation frame has a dangerous side.
Say, the animation speed = 20 and it runs at 60 FPS. Then each frame will be there for 3 ticks. (when the animations sync up)
As a result this condition (above) will be true for 3 ticks in a row.
Usually you solve this with a 'System > Trigger once while true'.
Sprite > Compare frame
System > compare 2 values .. Sprite.Count = Sprite.PickedCount
System > Trigger once while true
'Trigger once while true' runs its event once when the paired up condition(s) are true. Then it sits there, and waits. Until the conditions are not true, then it flags its event as executable again.
But that will not be flawless in the above conditions because of the above explained exception.
When there i no Sprite with that frame, the condition will not run, the 'Trigger once while true' will also not run.
As a result it miss out the change in true/untrue for the next tick.
There is also the possibility of an additional 'thing'. Say, the animations do not run in sync. Then 'this tick' a certain sprite changed frame, while another one is still in the same frame.
Comes down to this. When Sprite.Count is equal to Sprite.PickedCount this tick it can only run its actions when Sprite.Count was not equal to Sprite.PickedCount in the previous tick.
Using a Global Variable.
Sprite > Compare frame
_____Sub / System > compare 2 values .. Sprite.Count = Sprite.PickedCount
___________Sub / GlobalVariable = zero ?
_________________sub / System > Pick All (Sprite)
_______________________action : do your stuff
___________Sub / Empty event
_________________action : set GlobalVariable to 1
_____Else
__________action : set GlobalVariable to 0
Else
_____ if it is needed to capture the exeption