Results 1 to 5 of 5

Thread: [LRC] Banking problem

  1. #1
    Join Date
    Apr 2012
    Posts
    14
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default [LRC] Banking problem

    I don't know TOO much about scripting but im attempting to learn.

    i've found the script i need to bank @ living rock caverns.. except i don't know how to use Color, Tolerance, and ColorToleranceSpeed and what not.. :\ lol.

    Code:
    function OpenDepositBox : Boolean;
    var
      X, Y, T:integer;
    begin
      result := false;
      If(not(LoggedIn)) then exit;
      begin
        if FindObjTPA(x, y, 739167, 10, -1, 30, 30, 200, ['deposit']) then
        begin
          GetMousePos(X, Y);
          Mouse(x, y, 0, 0, mouse_left);
          Result := True;
          T :=0;
          repeat
            Inc(T);
            Wait(500+random(500));
          until (DepositScreen) or (T>=30);
        end else
        Writeln('Could not find the deposit box');
      end;
    end;
    Much help would be appreciated. <3

  2. #2
    Join Date
    Dec 2011
    Posts
    733
    Mentioned
    2 Post(s)
    Quoted
    7 Post(s)

    Default

    FindObjTPA you general want to stay away from. Same with all the other findobj functions. I find them very innacurate because they dont wait long enough on each pont, so if it finds a match, it will actually click on the next point, screwing up your script. This is from running it on a laggy computer though lol.

    Replace below with ClickMouse2(mouse_Left); It saves you a line, and is clearer to someone who reads.
    Simba Code:
    GetMousePos(X, Y);
    Mouse(x, y, 0, 0, mouse_left);
    Use a for to do loop here ;].
    Simba Code:
    repeat
      Inc(T);
      Wait(500+random(500));
    until (DepositScreen) or (T>=30);
    Example of a for loop:

    for T := 0 to 30 do
    if not DepositScreen then
    wait(RandomRange(150,300));
    else
    break;


    On to color tolerance.

    The 4 modes (4th is very uncommonly used) are

    distance by box,
    distance by sphere
    hue saturation lightness (extremely accurate, but slightly slower)
    and this last i forget the acronym, but it represents how humans see.

    A veeery good tut on color tolerance:
    http://villavu.com/forum/showthread.php?t=74908

    A tutorial on TPA finding:
    http://villavu.com/forum/showthread.php?t=21786

    The AIO pointer tutorial, that will point you to the answer to many of lifes questions:
    http://villavu.com/forum/showthread.php?t=76632

    Keep trying dude, learning to script reeeally pays off =]]
    My scripts: LunarPlanker
    ---
    My Utilities: Cross Platform, Open Source, SPS Path Generator

    Join the Unoficial SRL Skype Group by clicking here, or visiting this thread.

  3. #3
    Join Date
    Apr 2012
    Posts
    14
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    thanks alot dude this helped alot, im gonna check out thoes tuts asap

  4. #4
    Join Date
    Dec 2011
    Posts
    733
    Mentioned
    2 Post(s)
    Quoted
    7 Post(s)

    Default

    Please do. Youll learn alot =]

    I did ;]
    My scripts: LunarPlanker
    ---
    My Utilities: Cross Platform, Open Source, SPS Path Generator

    Join the Unoficial SRL Skype Group by clicking here, or visiting this thread.

  5. #5
    Join Date
    Apr 2007
    Location
    Los Angeles
    Posts
    622
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    Tutorial island would really help you out with any questions. If you don't understand something or are stuck after reading the tut, post in the help>Scripting help section and we'll be more than happy to help you out =D

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
  •