Results 1 to 21 of 21

Thread: Dropping help

  1. #1
    Join Date
    Jan 2007
    Posts
    834
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Dropping help

    This is really pissing me off. I'm so proud of myself that I got my chopping procedure perfect.

    Can anybody post a quick procedure on how to drop something? I got the DTM of each ore/log available in my script(They are working).
    Last edited by Mr. Doctor; 10-11-2012 at 08:41 PM.

  2. #2
    Join Date
    May 2007
    Location
    Ohio
    Posts
    2,296
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I'll help if your on jnrpms irc

  3. #3
    Join Date
    Jan 2007
    Posts
    834
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Timer View Post
    I'll help if your on jnrpms irc
    Yea I'm on it now. And why am I still banned from the #srl IRC? It's been more than a day.

  4. #4
    Join Date
    Oct 2007
    Location
    #srl
    Posts
    6,102
    Mentioned
    39 Post(s)
    Quoted
    62 Post(s)

    Default

    SCAR Code:
    function Dropthem: Boolean;
    var
      i: Integer;
    begin
      {Load DTMs here}
      for i := 1 to 28 do //loop through all of the inventory slots.
      begin
        if ExistsItem(i) then // if theres an item in the slot then..
        begin
          if FindDTM({fill this in}) then // if we find the DTM in the slot then..
          begin
            MouseBox(InvBox(i).x1, InvBox(i).y1, InvBox(i).x1, InvBox(i).y2, 2); //2 is right click I believe. {right click it}
            ChooseOption({whatever option you want to choose}); //drop it
          end;
        end;
      end;
      Result := InvEmpty; // Result returns true when your inventory is empty.
    end;
    I just wrote that quick from memory, but that concept works.

    Thanks Timer, fixed.
    Last edited by NCDS; 01-22-2010 at 11:31 PM.

  5. #5
    Join Date
    May 2007
    Location
    Ohio
    Posts
    2,296
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by NCDS View Post
    SCAR Code:
    function Dropthem: Boolean;
    var
      i: Integer;
    begin
      {Load DTMs here}
      for i := 0 to 27 do
      begin
        if ExistsItem(i) then
        begin
          if FindDTM({fill this in}) then
          begin
            MouseBox(InvBox(i).x1, InvBox(i).y1, InvBox(i).x1, InvBox(i).y2, 2); //2 is right click I believe.
            ChooseOption({whatever option you want to choose});
          end;
        end;
      end;
      Result := InvEmpty;
    end;
    I just wrote that quick from memory, but that concept works.
    1 to 28.

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

    Default

    here


    SCAR Code:
    Procedure drop;
    begin
      {dtm}
      repeat
        if finddtm(x, y, dtm, miz1, miy1, mix2, miy2) then
        begin
          mouse(x, y, 4, 4, false);
          chooseoption('rop');
          wait(100 + random(54));
        end;
      until(not (finddtm(x, y, dtm, mix1, miy1, mix2, miy2))
    end;

  7. #7
    Join Date
    Feb 2009
    Location
    Hungary (GMT + 1)
    Posts
    1,774
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Or if you can, use srl's dropping functions.
    And don't forget about InvMouse(or whatever it's called).
    I would use InvMouse(i, 2); in NCDS's function.
    Just take a look at the include, and you will got some idea I am sure.

  8. #8
    Join Date
    Oct 2008
    Location
    C:\Simba\Includes\
    Posts
    7,566
    Mentioned
    19 Post(s)
    Quoted
    180 Post(s)

    Default

    NCDS, couldn't you just use DropItem(I)?

    SCAR Code:
    procedure DropTheLogs;
    var
      I  : Integer;
    begin
      if(not(LoggedIn)) or (not(InvFull))then
        Exit;
      begin
        WriteLn('Dropping Logs');
        for I := 1 to 28 do
        begin
          if(ExistsItem(I))then
          begin
            MMouseItem(I);
            Wait(400 + Random(400));
            if(not(IsUpText('atchet')))then
              DropItem(I);
          end;
        end;
      end;
    end;
    ?

    ~Camo
    Away for awhile, life is keeping me busy. | Want to get my attention in a thread? @Kyle Undefined; me.
    { MSI Phoenix || SRL Stats Sigs || Paste || Scripts || Quotes || Graphics }

    When posting a bug, please post debug! Help us, help you!

    I would love to change the world, but they won't give me the source code. || To be the best, you've got to beat the rest. || Logic never changes, just the syntax.
    If you PM me with a stupid question or one listed in FAQ, or about a script that is not mine, I will NOT respond.


    SRL is a Library of routines made by the SRL community written for the Program Simba. We produce Scripts for the game Runescape.


  9. #9
    Join Date
    Jan 2007
    Posts
    834
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Camo Developer View Post
    NCDS, couldn't you just use DropItem(I)?

    SCAR Code:
    procedure DropTheLogs;
    var
      I  : Integer;
    begin
      if(not(LoggedIn)) or (not(InvFull))then
        Exit;
      begin
        WriteLn('Dropping Logs');
        for I := 1 to 28 do
        begin
          if(ExistsItem(I))then
          begin
            MMouseItem(I);
            Wait(400 + Random(400));
            if(not(IsUpText('atchet')))then
              DropItem(I);
          end;
        end;
      end;
    end;
    ?

    ~Camo
    What if there's a random event and it drops the special item or something? Wouldn't it drop that too?

  10. #10
    Join Date
    Oct 2007
    Location
    #srl
    Posts
    6,102
    Mentioned
    39 Post(s)
    Quoted
    62 Post(s)

    Default

    Quote Originally Posted by Camo Developer View Post
    NCDS, couldn't you just use DropItem(I)?

    SCAR Code:
    procedure DropTheLogs;
    var
      I  : Integer;
    begin
      if(not(LoggedIn)) or (not(InvFull))then
        Exit;
      begin
        WriteLn('Dropping Logs');
        for I := 1 to 28 do
        begin
          if(ExistsItem(I))then
          begin
            MMouseItem(I);
            Wait(400 + Random(400));
            if(not(IsUpText('atchet')))then
              DropItem(I);
          end;
        end;
      end;
    end;
    ?

    ~Camo
    Yes, there are many alternatives. I more so wrote that quick to just give him an idea of a basic dropping method.

  11. #11
    Join Date
    Jan 2007
    Posts
    834
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by NCDS View Post
    Yes, there are many alternatives. I more so wrote that quick to just give him an idea of a basic dropping method.
    Your procedure drops my hatchet. Although it drops everything correctly.

  12. #12
    Join Date
    Oct 2008
    Location
    C:\Simba\Includes\
    Posts
    7,566
    Mentioned
    19 Post(s)
    Quoted
    180 Post(s)

    Default

    JunkJ, you would obviously want to edit that to fit your needs. That example just doesn't use a DTM. And I'm guessing you're writing a power chopper so random event items would just clog your inventory if you kept them...

    ~Camo
    Away for awhile, life is keeping me busy. | Want to get my attention in a thread? @Kyle Undefined; me.
    { MSI Phoenix || SRL Stats Sigs || Paste || Scripts || Quotes || Graphics }

    When posting a bug, please post debug! Help us, help you!

    I would love to change the world, but they won't give me the source code. || To be the best, you've got to beat the rest. || Logic never changes, just the syntax.
    If you PM me with a stupid question or one listed in FAQ, or about a script that is not mine, I will NOT respond.


    SRL is a Library of routines made by the SRL community written for the Program Simba. We produce Scripts for the game Runescape.


  13. #13
    Join Date
    Feb 2009
    Location
    Hungary (GMT + 1)
    Posts
    1,774
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    What I would do is get the hatchets position in the inventory then use a DropAllExcept function. You don't even need a dtm for that just a good color with a good tolerance.(for the axe) And that would be like 2 or max 3 line.
    search for color in inventory;
    convert the coordinate to inventory slot;(CoordsToItem)
    Dropallexcept the inventory spot we got the hatchet in;

  14. #14
    Join Date
    Jan 2007
    Posts
    834
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Camo Developer View Post
    JunkJ, you would obviously want to edit that to fit your needs. That example just doesn't use a DTM. And I'm guessing you're writing a power chopper so random event items would just clog your inventory if you kept them...

    ~Camo
    I guess so... I'll just drop everything except the hatchet.

  15. #15
    Join Date
    Feb 2009
    Posts
    1,447
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    This would drop everything except a hatchet / pickaxe:

    SCAR Code:
    if FindDTM(x, y, Hatchet, MIX1, MIY1, MIX2, MIY2) or FindDTM(x, y, Pickaxe, MIX1, MIY1, MIX2, MIY2) then
    DropAllExcept([CoordsToItem(x, y)]);

  16. #16
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    Ugh really guys, is it that hard?!

    SCAR Code:
    For I:=0 to 27 Do
      Begin
        SlotBox:=I;
        If FindDTm(OreMid, x, y, SlotBox.X1, SlotBox.Y1,  SlotBox.X2,  SlotBox.Y2) Then
     Begin
          MouseItem(I, False);
          ChooseOption('rop');
      End;

    Something like that, is all you need.

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

    Default

    use mine it works just make a dtm of the logs itll work i promise you that

  18. #18
    Join Date
    Dec 2009
    Location
    Newcastle, Australia
    Posts
    888
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    assuming you want to drop everything in your inventory and you are using SRL...try this


    Dropall;


    Seriously check out inventory.scar...its right there....

  19. #19
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    Quote Originally Posted by Bad Boy JH View Post
    assuming you want to drop everything in your inventory and you are using SRL...try this


    Dropall;


    Seriously check out inventory.scar...its right there....


    Assuming you didn't want to read everything in this thread, and you are silly.... try this


    Quote Originally Posted by Junkj View Post
    Your procedure drops my hatchet. Although it drops everything correctly.

    Seriously check out the entire thread....its right here...!

  20. #20
    Join Date
    Feb 2009
    Posts
    1,447
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Bad Boy JH View Post
    assuming you want to drop everything in your inventory and you are using SRL...try this


    Dropall;


    Seriously check out inventory.scar...its right there....
    If you drop every item in you're inventory, you may also drop a pickaxe / hatchet...

    This would be the best option for your dropping needs:

    SCAR Code:
    if FindDTM(x, y, Hatchet, MIX1, MIY1, MIX2, MIY2) or FindDTM(x, y, Pickaxe, MIX1, MIY1, MIX2, MIY2) then
    DropAllExcept([CoordsToItem(x, y)]);

  21. #21
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    Trilez, I like only dropping ores/logs, rather than only excluding a pickaxe or hatchet.
    They could have things besides a pickaxe or hatchet that they won't want dropped. Better to just drop what should be dropped, instead of guess what shouldn't .

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
  •