Results 1 to 2 of 2

Thread: EatFood

  1. #1
    Join Date
    Feb 2009
    Posts
    2,155
    Mentioned
    4 Post(s)
    Quoted
    42 Post(s)

    Default EatFood

    Ive seen a few requests for a Eating procedure so i decided to make on quick if its already done then srry



    SCAR Code:
    {*******************************************************************************
    procedure EatFood(i: Integer);
    By: J_pizzle
    Description: Eats food at given position (1-28)
    *******************************************************************************}

    function EatItem(i: Integer): Boolean;
    begin
      Result := False;
      if ExistsItem(i) then
      begin
        MouseItem(i, False);
        if (WaitOptionEx('Eat', 'action', Clickleft, 250)) then
        begin
          Result := True;
          Wait(RandomRange(50, 200));
        end;
      end;
    end;

  2. #2
    Join Date
    Oct 2006
    Location
    ithurtsithurtsithurtsithurts
    Posts
    2,930
    Mentioned
    7 Post(s)
    Quoted
    135 Post(s)

    Default

    Seems pretty good, although I would add an option for right or left clicking, so it would look something like this:
    SCAR Code:
    function EatItem(ItemPos: Integer, Left: Boolean): Boolean;
    begin
      Result := False;
      if ExistsItem(ItemPos) then
      begin
        MouseItem(ItemPos, Left);
        Result := Left;
        if (Result) then Exit;
        if (WaitOptionEx('Eat', 'action', Clickleft, 250)) then
        begin
          Result := True;
          Wait(RandomRange(50, 200));
        end;
      end;
    end;

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
  •