this might be what you need:
blitzmax angles are -180 to 180 (360 degrees)
EDIT:
blitzmax angles are -180 to 180 (360 degrees)
EDIT:
Strict Graphics 800,600 Local midx:Int = GraphicsWidth()/2 Local midy:Int = GraphicsHeight()/2 Local mx:Int Local my:Int Repeat mx = MouseX() my = MouseY() DrawLine (midx,midy,mx,my) Local myangle = ANGLE(mx,my,midx,midy) DrawText "B",mx+16,my DrawText "angle="+myangle,mx+20,my+20 SetRotation myangle DrawText "A",midx,midy SetRotation 0 Flip ; Cls Until KeyDown(KEY_ESCAPE) Function ANGLE:Float(x1,y1,x2,y2) Local angle = ATan2(x2-x1,y1-y2)+180 ' Thanks Skidracer ' Inverse Tangent Return angle End Function