Results 1 to 5 of 5

Thread: Help with eating!

  1. #1
    Join Date
    Feb 2012
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    10 Post(s)

    Default Help with eating!

    Right now I'm using TrollFighter, written by wthomas. He has some anti-leech, but I don't think it's anti-leech. Is there a method for eating in the P07 Includes?

    Here is the code he uses for eating:

    Code:
    Procedure eatFood;
    Var i:integer;
    Begin
      Repeat
      Inc(foodslot);
      Writeln('trying to eat foods troll style');
      Wait(300);
      Until P07_UseInvItem(foodslot,'Eat') Or (foodslot>28);
      //NB this procedure ^^ is an easily modified version of P07_UseInvItem()
    end;
    P07_UseInvItem doesn't exist, so how can I incorporate existing methods to eat food?

    I have found:
    If P07_ItemExists(1) Then DoSomething();

    I need to figure out how to click that inventory space.
    Last edited by Im fkn rare; 03-02-2013 at 02:25 AM.

  2. #2
    Join Date
    Oct 2012
    Posts
    758
    Mentioned
    6 Post(s)
    Quoted
    282 Post(s)

    Default

    If you don't know how to click on an object in your inventory I recommend some beginner's tutorials e.g.
    http://www.youtube.com/watch?v=dZGOIqFocpE
    or have a read in the forums.
    Find the object..move mouse to it..click it. It's that simple. DTM or bitmap will be easy/fast to make for this.

  3. #3
    Join Date
    Oct 2008
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    Procedure eatFood;
    Var i:integer;
    Begin
    If P07_FindObjCustom(x, y, ['Eat', 'Trout'], [7172489], 5) Then
    ClickMouse2(mouse_left);
    end;

    this would find the color of cooked trout and click on it.

    hope this helps

  4. #4
    Join Date
    Feb 2012
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    10 Post(s)

    Default

    Quote Originally Posted by Runehack123 View Post
    If you don't know how to click on an object in your inventory I recommend some beginner's tutorials e.g.
    http://www.youtube.com/watch?v=dZGOIqFocpE
    or have a read in the forums.
    Find the object..move mouse to it..click it. It's that simple. DTM or bitmap will be easy/fast to make for this.
    Quote Originally Posted by blitzandkill View Post
    Procedure eatFood;
    Var i:integer;
    Begin
    If P07_FindObjCustom(x, y, ['Eat', 'Trout'], [7172489], 5) Then
    ClickMouse2(mouse_left);
    end;

    this would find the color of cooked trout and click on it.

    hope this helps
    Thank you both, I'm working on getting into writing scripts!

  5. #5
    Join Date
    Feb 2012
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    10 Post(s)

    Default

    I'm receiving this error now when I run any script:

    [Error] C:\Simba\Includes\Srl\SRL-007/SRL/core/chat.simba(804:69): Unknown identifier 'CharsNPC07' at line 803

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
  •