Forward Scrolling Space Shooter AI?

I need to know how to make an AI for my game this is something I am new to.
things that the AI needs to do:

  • Shoot A Player
  • Not collide with other enemies/player
  • Act differently based on health
  • move towards player is able to

I have already created the enemies and stuff I just need to know how to make them “smart” and actually attack and stuff.

Thanks for the help!!!

I just need to be pointed in the right direction