solution to wanting to have a level end once all "enemies" have been destroyed

I’m sure there are many ways to go about being able to do this, but this is the solution I found. Id love to hear your solutions as well. Screen Shot 2019-03-28 at 1.27.57 PM

What’s going on here is that there is an object outside the play area that has an extremely large proximity setting which constantly looks for “enemies.” when none are detected, it will stop sending a signal to the XOR logic gate which will open that gate and end the level