/*ご参考(SendInputからmouse_eventへのヒント)*/
#uselib "user32.dll"
#func global ClientToScreen "ClientToScreen" sptr,sptr
#func global mouse_event "mouse_event" sptr,sptr,sptr,sptr,sptr
#func global SendInput "SendInput" sptr,sptr,sptr
          pp  =  20,50                      ;振幅(X,Y)
          aa  =  30                         ;角度
  repeat 640/pp
          nn  =  cnt*pp,int(sin(deg2rad(cnt*aa))*pp(1))+240
     ;    nn  =  int(cos(deg2rad(cnt*aa))*pp)+320,int(sin(deg2rad(cnt*aa))*pp(1))+240
      pos nn,nn(1)
      mes "●"
      ClientToScreen hwnd,varptr(nn)
          ii  = 0,nn*(65535/ginfo_dispx),nn(1)*(65535/ginfo_dispy),0,$8001,0,0
      SendInput 1,varptr(ii),28
     ;mouse nn,nn(1)
      await 100
  loop