Results 1 to 3 of 3

Thread: What am i doing wrong?

  1. #1
    Join Date
    Jul 2007
    Location
    Pluto... Maybe?
    Posts
    198
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default What am i doing wrong?

    Im trying to make it so if it doesnt find coins in the bank it logs out and ends the script, heres what iv done:

    SCAR Code:
    Procedure FindTheCoins;
    Var
    Coins, x, y : Integer;
    begin
      Coins := DTMFromString('78DA631463606090644001D3AA8419F881342' +
           '310FF0702463520438E010D302291405A1048081250C309241409' +
           'A85125C21C6920A1865F0D0059820676');
           If FindDTM(Coins, x, y, MBX1, MBY1, MBX2, MBY2) Then
          Mouse(x, y, 0, 0, False);
         ChooseOption('draw-X');
        Wait(500 + Random(600));
       TypeSend('6750');
         If not FindDTM(Coins, x, y, MBX1, MBY1, MBX2, MBY2) Then
         begin
           Writeln('No Coins Found!')
          Logout;
         TerminateScript;
        Exit;
       FreeDTM(Coins);
      end;
    end;

    If it cant find the coins it still types 6750 and then terminates the script but it doesnt log out leaving it on the bank screen?

  2. #2
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    SCAR Code:
    Procedure FindTheCoins;
    Var
    Coins, x, y : Integer;
    begin
      Coins := DTMFromString('78DA631463606090644001D3AA8419F881342' +
           '310FF0702463520438E010D302291405A1048081250C309241409' +
           'A85125C21C6920A1865F0D0059820676');
           If FindDTM(Coins, x, y, MBX1, MBY1, MBX2, MBY2) Then
           begin
             Mouse(x, y, 0, 0, False);
             ChooseOption('draw-X');
             Wait(500 + Random(600));
             TypeSend('6750');
           end;
           If not FindDTM(Coins, x, y, MBX1, MBY1, MBX2, MBY2) Then
           begin
             Writeln('No Coins Found!')
             Logout;
             FreeDTM(Coins);
             TerminateScript;
           end;
    end;
    Last edited by ian.; 08-27-2009 at 09:50 AM.

  3. #3
    Join Date
    Jul 2007
    Location
    Pluto... Maybe?
    Posts
    198
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    lol thanks silly thing is i tried putting a begin in the script but forgot to put end; haha thanks

Thread Information

Users Browsing this Thread

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

Posting Permissions

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