The line-of-sight behavior is probably the best way to go.
https://www.scirra.com/manual/163/line-of-sight
If you only have 1 enemy type, or if you are okay with all enemies having the same activation distance, you can put the LOS behavior on the player sprite, and look for enemies in view. This is much more efficient, as LOS can use a lot of resources if it's stuck on too many objects.
As for spawning bullets, place that as a subevent under the 'can player see enemy' event. You need two conditions:
For each enemy
Every X seconds (x being how often you want the bullets to be fired)
----Spawn bullet
----Set bullet angle toward player