Adblock breaks this site

Scar scripting question

Discussion in 'Scar/Simba Help' started by i-joost, Aug 19, 2009.

  1. i-joost

    i-joost Newcomer

    Joined:
    Sep 17, 2007
    Posts:
    5
    Referrals:
    0
    Sythe Gold:
    0
    Scar scripting question

    Hi I registered several years ago but then quitted rs but now ive started it again and im working on a script wich function i rather not mention but i have a question.

    I have my mouse moved to a spot with a random like this:

    MoveMouseSmoothEx(137+random(63),57+random(63),20,40,45,25,20);

    And then I want scar to let the mouse click on the spot where the mouse move had ended.

    is this possible?
    ive searched in the beginners tutorial but didnt found it.
     
  2. radiclerobby

    radiclerobby Apprentice
    Banned

    Joined:
    Mar 9, 2008
    Posts:
    720
    Referrals:
    0
    Sythe Gold:
    0
    Scar scripting question

    getmousepos(x,y);
    clickmouse(x,y,true); lol
     
  3. EduardSale

    EduardSale Newcomer

    Joined:
    Sep 3, 2009
    Posts:
    15
    Referrals:
    0
    Sythe Gold:
    0
    Scar scripting question

    Code:
    GetMousePos(X,Y)
    Gets the coordinates of the X and the Y of the screen of the client window.
    So what could u do?, when u moved the mouse to that coordinate, use the function to give X and Y that coordinates. Then use a function that clicks the mouse with the given coordinates.

    Example:
    Code:
    program testcoordiantes;
    var
    x,y: Integer;
    procedure getcoordinates;
    begin
    MoveMouseSmoothEx(12,12,12,12,12,12,12);
    wait(100);
    Getmousepos(x,y);
    Writeln('Your X : '+inttostr(x)+'');
    writeln('your Y : '+inttostr(y)+'');
    Writeln(' this is made by Eduardsale, check out my thread at : http://www.sythe.org/showthread.php?t=683205');
    end;
    
    begin
    getcoordinates;
    end.
    
    No problem, ~ Eduard
     
< How to add scripts onto Scar | bitmap images rsc classic? any1 know? >


 
 
Adblock breaks this site