Did you try using a global number variable? just set the global number variable, let's call it blah, to __ number based on the aforementioned conditions. so if ___ is whatever direction from ___ then set blah = 0 but if ___ is whatever direction from ___ then set blah = 1.
Then furthermore, you would then set it so if blah = 0 spawn ___ but if blah = 1 spawn ___