Results 1 to 9 of 9

Thread: .....

  1. #1
    Join Date
    Aug 2008
    Location
    !!LOL!!
    Posts
    247
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default .....

    How can i make a procedure that finds a dtm in Inv (i can do this Part) and nnce found it clicks it according to slot order( this i need help with)

  2. #2
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    What do you mean? Elaborate more. You want it to click the one closest to first slot or what?

    Oh, by the way, don't use titles like this...

  3. #3
    Join Date
    Mar 2009
    Location
    Illinois
    Posts
    292
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    What do you mean?
    Something like
    SCAR Code:
    Procedure ClickInvItem;
    Begin
     if findDtm(your dtm) then
       begin
         Mouse(x, y, 5, 5, true);
       end;
    end;
    ?

  4. #4
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    He said he knows how to find it.
    And you don't need that begin and end as you only do one thing after it.

  5. #5
    Join Date
    Aug 2008
    Location
    !!LOL!!
    Posts
    247
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Da owner yes thats wat i meant

  6. #6
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I believe that when you search for a DTM, it automatically picks the one that is closest to the top of the box picked (in this case, the inventory (MIX1, MIX2, etc.).

  7. #7
    Join Date
    Aug 2008
    Location
    !!LOL!!
    Posts
    247
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    well, it doesnt or else i wouldnt be here

  8. #8
    Join Date
    Jan 2008
    Location
    California, US
    Posts
    2,765
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Okay then I shall test. Will edit in a second.

    Tested. When I had a full inventory of willows and searched for a DTM, it then clicked the first one. Then I dropped that and it clicked the 5th one. I will make a function now.

    SCAR Code:
    function FindDTMInInv(DTM : integer; var x, y : integer; x1, y1, x2, y2 : integer) : boolean;
    var
      i : integer;
      Box : TBox;
    begin
      for i := 1 to 28 do
        if ExistsItem(i) then
        begin
          Box := InvBox(i);
          if FindDTM(DTM, x, y, Box.x1, Box.y1, Box.x2, Box.y2) then
          begin
            result := true;
            exit;
          end;
         end;
     end;
    Last edited by Da 0wner; 05-17-2009 at 01:20 PM.

  9. #9
    Join Date
    Aug 2008
    Location
    !!LOL!!
    Posts
    247
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    its just that simple wow im dum thanks for ur time

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
  •