Results 1 to 24 of 24

Thread: Not Clicking :(

  1. #1
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Not Clicking :(

    SCAR Code:
    function FindRock(color: TIntegerArray; fx, fy: integer): boolean;
    var
      k: integer;
    begin
      if not LoggedIn or FindDead then Exit;
      begin
        for k := 0 to High(color) do
        if FindColorSpiralTolerance(fx, fy, color[k], MSX1, MSY1, MSX2, MSY2, 15) then
        begin
          MMouse(fx, fy, 5, 5);
          if IsUpText('ine') then
          Result := True;
        end;
      end;
    end;

    procedure MineThem(Kind: string);
    var
      mx, my: integer;
    begin
      case Lowercase(Kind) of
        'coal' : begin
                   if FindRock([3097925, 2372661, 1911595], mx, my) then
                   begin
                     SkilldGas;
                     case random(3) of
                       0, 1: Mouse(mx, my, 5, 5, true);
                       2: begin
                            Mouse(mx, my, 5, 5, false);
                            ChooseOption('ine');
                          end;
                     end;
                     FFlag(0);
                     repeat
                       Wait(500 + Random(500));
                       AntiBan;
                     until (FindBlackChatMessage('anage')) or (FindBlackChatMessage('vailable'));
                   end;
                 end;
        'mith' : begin
                   if FindRock([5913917, 8739675, 7951186], mx, my) then
                   begin
                     SkilldGas;
                     case random(3) of
                       0, 1: Mouse(mx, my, 5, 5, true);
                       2: begin
                            Mouse(mx, my, 5, 5, false);
                            ChooseOption('ine');
                          end;
                     end;
                     FFlag(0);
                     repeat
                       Wait(500 + Random(500));
                       AntiBan;
                     until (FindBlackChatMessage('anage')) or (FindBlackChatMessage('vailable'));
                   end;
                 end;
        'both' : begin
                   if (FindRock([3097925, 2372661, 1911595], mx, my)) or (FindRock([5913917, 8739675, 7951186], mx, my)) then
                   begin
                     SkilldGas;
                     case random(3) of
                       0, 1: Mouse(mx, my, 5, 5, true);
                       2: begin
                            Mouse(mx, my, 5, 5, false);
                            ChooseOption('ine');
                          end;
                     end;
                     FFlag(0);
                     repeat
                       Wait(500 + Random(500));
                       AntiBan;
                     until (FindBlackChatMessage('anage')) or (FindBlackChatMessage('vailable'));
                   end;
                 end;
      end;
    end;

    It never clicks the rock, just hovers the mouse over it.

  2. #2
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Try Mx, My as global vars and replace fx,fy with Mx,my in the find rock procedure

  3. #3
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    but then I would get duplicate Identifier error, wouldn't I?

  4. #4
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    No I dont think so, Even if you do you can remove the co-ords from the procedure beginning it makes no difference.

  5. #5
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    U forgot, Var

    function FindRock(color: TIntegerArray; Var fx, fy: integer): boolean;

  6. #6
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    um....no, you don't have to put var in that part of the function.

  7. #7
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    If you use it like

    If FindRock(somex,somey) Then Mouse(SomeX, SomeY, 5, 5, true);

    then you have to do
    Var fx, fy:integer;

  8. #8
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I soccer you, what are you talking about??

  9. #9
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I don't know how to explain Var resends the coords to the input vars. (Mx,My)

    Edit:
    Compile it
    SCAR Code:
    Program I_Soccer_You;
    Var
      IProofU:Integer;

    procedure Proof(X:Integer);
    begin
      X:=10;
    end;

    Begin
      IProofU:=0;
      Proof(IProofU);
      Writeln(IntToStr(IProofU));
    End.

    Now add a var
    SCAR Code:
    Program I_Soccer_You;
    Var
      IProofU:Integer;

    procedure Proof(Var X:Integer);
    begin
      X:=10;
    end;

    Begin
      IProofU:=0;
      Proof(IProofU);
      Writeln(IntToStr(IProofU));
    End.

    Changed to your vars(this is only the x)
    SCAR Code:
    Program I_Soccer_You;
    Var
      mx:Integer;

    procedure Proof(fx:Integer);
    begin
      fx:=10;
    end;

    Begin
      mx:=0;
      Proof(mx);
      Writeln(IntToStr(mx));
    End.
    add a var
    SCAR Code:
    Program I_Soccer_You;
    Var
      mx:Integer;

    procedure Proof(var fx:Integer);
    begin
      fx:=10;
    end;

    Begin
      mx:=0;
      Proof(mx);
      Writeln(IntToStr(mx));
    End.

  10. #10
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Ok, but why would you do that.. You don't need to put Var there..

  11. #11
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by itSchRis91791 View Post
    Ok, but why would you do that.. You don't need to put Var there..
    That's obvious... like he let us see his function he shows that he wants to use it.

    else he just could do...

    SCAR Code:
    findrock(1 pararmeter, 2 parameter)

    But he uses,
    SCAR Code:
    findrock(1 pararmeter, 2 parameter, CoordX, CoordY)
    So you could use any var you want

    if FindRock(X,Y) Then Mouse(X,y);
    if FindRock(SX,SY) Then Mouse(SX,Sy);
    if FindRock(MX,MY) Then Mouse(MX,My);


    But that won't work if you don't add var

  12. #12
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Wrong.. You still don't need the var there. Here's a function that i made.

    SCAR Code:
    {------------------------------------------------------------------------------]
    [ function DistFromSymbol(cx, cy: Integer; SymbolName : String): Integer;      ]
    [ by: Itschris917                                                              ]
    [ Description: Determines distance from player to specified symbol. Returns -1 ]
    [              if symbol is not found.                                         ]
    {------------------------------------------------------------------------------}

    function DistFromSymbol(cx, cy : Integer; SymbolName : String):Integer;
    begin
      if not LoggedIn then Exit;
      if FindSymbol(cx, cy, SymbolName) then
        Result := Distance(MMCX, MMCY, cx, cy) else Result := -1;
    end;

    And here's me using it later on in my script:
    SCAR Code:
    DistFromSymbol(rx, ry, 'Cookery')

    Works fine for me, and always returns proper distance.

  13. #13
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    And when you try to mouse(Rx,Ry,5,5,true) it works?
    It is obvious that it works, but if you want to mouse it it should not work

  14. #14
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    yes it does

  15. #15
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Okay ill test

    Edit:

    moves to 0,0 and that is because Rx will be 0 because Cx doesn't puts anything back in the Rx which you filled in same for RY

    edit:
    SCAR Code:
    Program LMAO;
    {.Include SRL/SRL.Scar}
    Var
      X, Y:Integer;
    {------------------------------------------------------------------------------]
    [ function DistFromSymbol(cx, cy: Integer; SymbolName : String): Integer;      ]
    [ by: Itschris917                                                              ]
    [ Description: Determines distance from player to specified symbol. Returns -1 ]
    [              if symbol is not found.                                         ]
    {------------------------------------------------------------------------------}

    function DistFromSymbol(cx, cy : Integer; SymbolName : String):Integer;
    begin
      if not LoggedIn then Exit;
      SymbolAccuracy:=0.5;
      if FindSymbol(cx, cy, SymbolName) then
        Result := Distance(MMCX, MMCY, cx, cy) else Result := -1;
    end;

    Begin
      SetUpSRL;
      If (DistFromSymbol(x, y, 'Bank') > 0) Then Mouse(x,y,5,5,true);
    End.

    If (DistFromSymbol(x, y, 'Bank') > 0) Then Mouse(x,y,5,5,true);

    this will only mouse if it finds the distance bla bla bla, and it mouse's to X,Y it finds but moves to 0,0 because X does contain 0 and Y Contains 0

    Edit:
    You won't believe me because I am < junior member?
    I have respect for that, but I have a good srl scar teacher and also... I did much other languages.

  16. #16
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Lol, i just tested it too, and i remember it working??

  17. #17
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by itSchRis91791 View Post
    Lol, i just tested it too, and i remember it working??
    It's okay it was a very interesting battle good job

  18. #18
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Lol, it was an interesting battle. You win.

  19. #19
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by itSchRis91791 View Post
    Lol, it was an interesting battle. You win.
    Yay, party! have a cookie at my place

  20. #20
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Quote Originally Posted by I Soccer You View Post
    Yay, party! have a cookie at my place
    So when you gonna marry ?

  21. #21
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Nice Nauman, i just realized that i did sound a hella lot like my dad...

  22. #22
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by itSchRis91791 View Post
    Nice Nauman, i just realized that i did sound a hella lot like my dad...
    What ever

    /me trying to be mature

  23. #23
    Join Date
    Jun 2008
    Posts
    5
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you guys are totally smart i wish i new how to do that

  24. #24
    Join Date
    Jun 2008
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by kull View Post
    you guys are totally smart i wish i new how to do that
    This is totally spam...

    Stop doing that.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Help with clicking?
    By Kyle Undefined in forum OSR Help
    Replies: 20
    Last Post: 11-12-2008, 07:17 AM
  2. clicking on an npc
    By patman16 in forum OSR Help
    Replies: 3
    Last Post: 07-29-2008, 03:19 PM
  3. Dmt clicking help
    By MetalancA in forum OSR Help
    Replies: 7
    Last Post: 06-11-2008, 04:06 AM
  4. Clicking
    By axel23 in forum OSR Help
    Replies: 3
    Last Post: 04-17-2007, 06:58 PM
  5. clicking on a NPC
    By legendaryhero90 in forum OSR Help
    Replies: 9
    Last Post: 02-25-2007, 10:53 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •