So you want to get the angle between you and the enemy?
Rem Project: GetAngleFrom2DCoordinate
Rem Created: 16/07/2003 00:14:38
Rem Author: Lee 'Dr DB' Bamber :)
rem Set coordinates
youx#=320 : youy#=240
rem Main loop
do
rem Set moving target coordinate
targetx#=mousex() : targety#=mousey()
rem Calculate angle from YOUR position to TARGET position
dx#=targetx#-youx#
dy#=targety#-youy#
angle#=atanfull(dx#,dy#)
rem Clear screen
cls
rem Draw coordinates
circle youx#,youy#,5
circle targetx#,targety#,5
rem Show angle by drawing line
line youx#,youy#,newxvalue(youx#,angle#,100),newzvalue(youy#,angle#,100)
center text 320,260,"ANGLE = "+str$(int(wrapvalue(angle#)))
rem End loop
loop
"eureka" - Archimedes