Results 1 to 2 of 2

Thread: First Script!!!

  1. #1
    Join Date
    Jun 2007
    Posts
    24
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    First Script!!!

    i know, i know, its not finished but i got stuck

    here is the script

    SCAR Code:
    {HIHI12340 FIRST SCRIPT     PowerChopper
    AntiRandoms go to Jad}



    program PowerChopper;
    {.includeSLR/SLR.scar}

    procedure AntiRandoms;
    FindTalk;
    FindNormalRandoms;
    if (FindFight = true) then
    begin
    RunAwayDirection('N');
    Wait(10000 + random(3000));
    runback;
    end;
    end;

    procedure Chop;
    begin
    SetupSRL;
    repeat
    if(FindColor(x,y,2373688,587397
    now am i supposed to do this where i left off?


    SCAR Code:
    {HIHI12340 FIRST SCRIPT     PowerChopper
    AntiRandoms go to Jad}



    program PowerChopper;
    {.includeSLR/SLR.scar}

    procedure AntiRandoms;
    FindTalk;
    FindNormalRandoms;
    if (FindFight = true) then
    begin
    RunAwayDirection('N');
    Wait(10000 + random(3000));
    runback;
    end;
    end;

    procedure Chop;
    begin
    SetupSRL;
    repeat
    if(FindColor(x,y,2373688,587397,0,0,true


    if not help me with this so i know for uture scripts

  2. #2
    Join Date
    Apr 2007
    Location
    Perth, Australia
    Posts
    3,926
    Mentioned
    3 Post(s)
    Quoted
    2 Post(s)

    Default

    ummm first of all you should put the procedure in the main loop.

    you dont have to put SetupSRL in your procedure as you only have to do it once when you start the script.

    with your chop procedure you could do you something like this:
    SCAR Code:
    procedure Chop;
      begin
       repeat
        if (FindColorTolerance(x, y, 2373688, MSX1, MSY1, MSX2, MSY2, 10)) then
         begin
          x:=MSCX;
          y:=MSCY;
          FindColorSpiralTolerance(x, y, 2373688, MSX1, MSY1, MSX2, MSY2, 10);
          Mouse(x, y, 1, 1, true);
          Flag;
          Wait(1000+random(500));
         end;
       until not (FindColorTolerance(x, y, 2373688, MSX1, MSY1, MSX2, MSY2, 10));
       end;

    this should hopefully find the tree colour with a tolerance in the main screen, click and wait until the tree falls downs.

    then in your main loop put something like this:
    SCAR Code:
    begin
     SetupSRL;
     repeat
      AntiRandoms;
      Chop;
     until(false);
    end;

    of course you'll need to put a drop procedure and expand on the chopping and .... dada... you have yourself an extremely basic and easily detectable power chopper

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
  •