Signup Now
Results 1 to 7 of 7
  1. #1
    Free User Cezarus's Avatar
    Join Date
    Jul 2014
    Location
    Proland
    Posts
    57
    Reputation
    14
    Rep Power
    20

    Sort Loot even in depot!

    Put this in peristent:



    init start

    local SEMI_LOOT_SORTER_TBL = {

    SEMI_YASIR_ITEMS = {
    semi_containerName = "yellow backpack",
    semi_itemsTBL = {
    "demonic skeletal hand",
    "ghoul snack",
    "rotten piece of cloth",
    }
    },

    SEMI_GREEN_USEFUL_RINGS_AND_AMULETS = {
    semi_containerName = "green backpack",
    semi_itemsTBL = {
    "life ring",
    "might ring",
    "ring of healing",
    "dragon necklace",
    "time ring",
    "rrotection amulet",
    }
    },

    SEMI_GREEN_DJIN_ALESAR_ITEMS = {
    semi_containerName = "green backpack",
    semi_itemsTBL = {
    "Ancient Shield",
    "Black Shield",
    "Bonebreaker",
    "Dark Armor",
    "Dark Helmet",
    "Dragon Hammer",
    "Dreaded Cleaver",
    "Earth Knight Axe",
    "Energy Knight Axe",
    "Fiery Knight Axe",
    "Giant Sword",
    "Haunted Blade",
    "Icy Knight Axe",
    "Knight Armor",
    "Knight Axe",
    "Knight Legs",
    "Mystic Turban",
    "Onyx Flail",
    "Poison Dagger",
    "Scimitar",
    "Serpent Sword",
    "Skull Staff",
    "Strange Helmet",
    "Titan Axe",
    "Tower Shield",
    "Vampire Shield",
    "Warrior Helmet"
    }
    },

    SEMI_GREEN_DJIN_YAMAN_ITEMS = {
    semi_containerName = "green backpack",
    semi_itemsTBL = {
    "hailstorm rod",
    "moonlight rod",
    "mysterious fetish",
    "necrotic rod",
    "northwind rod",
    "silver amulet",
    "dwarven ring",
    "energy ring",
    "sakebite rod",
    "springsprout rod",
    "strange talisman",
    "terra rod",
    "underworld rod"
    }
    },

    SEMI_GREEN_DJIN_ITEMS = {
    semi_containerName = "green backpack",
    semi_itemsTBL = {
    "knight legs",
    "knight armor",
    "skull staff",
    "terra rod",
    }
    },

    SEMI_ADDON_ITEMS = {
    semi_containerName = "jewelled backpack",
    semi_itemsTBL = {
    "ankh",
    "demonic essence",
    "heaven blossom", "holy orchid",
    "spider silk", "red piece of cloth",
    }
    }
    }

    init end

    function checkHowMuchSpaceLeftInContainer(containereus)
    semi_check = getcontainer(containereus)
    local free_slots = semi_check.maxcount - semi_check.itemcount
    return free_slots
    end

    function openNextContainerWithTheSameNameFunction(xXx_container_name)
    local czyOtwartyKolejnyBP = false
    for m = 0, 15 do
    local semiContainerek = getcontainer(m)
    if semiContainerek.isopen then
    for r = 1, semiContainerek.itemcount do
    local info = iteminfo(semiContainerek.items[r].id)
    if info.iscontainer then
    listas('[openNextContainerWithTheSameNameFunction]:found container id:'.. semiContainerek.items[r].id ..' cointainer id to open:'.. iteminfo(xXx_container_name).id .. '.')
    if semiContainerek.items[r].id == iteminfo(xXx_container_name).id then
    listas('[openNextContainerWithTheSameNameFunction]:Opening next container...')
    openitem(semiContainerek.items[r].id, m)
    wait(1000, 1500)
    czyOtwartyKolejnyBP = true
    listas("[openNextContainerWithTheSameNameFunction]: Opened next container.")
    break
    end
    end
    end
    end
    end
    listas("[openNextContainerWithTheSameNameFunction]: Finished.")
    end

    function pickUpItemsFromCurrentSQMToBP(nazwa_naszego_bp_lala)
    if checkHowMuchSpaceLeftInContainer(nazwa_naszego_bp_lala) < 1 then
    openNextContainerWithTheSameNameFunction(nazwa_naszego_bp_lala)
    end
    pickupitems()
    end

    function semiSortLoot(pickFromContainerWithName, openNextContainerWithSameName)
    if not(pickFromContainerWithName ~= nil) or not(pickFromContainerWithName ~= "") then
    listas("[semiSortLoot]: PUT NAME OF CONTAINER IN ()")
    return false
    end

    if not(iteminfo(pickFromContainerWithName).iscontainer) then
    listas("[semiSortLoot]: THIS ITEM IS NOT CONTAINER")
    return false
    elseif iteminfo(pickFromContainerWithName).iscontainer then
    listas("[semiSortLoot]: Wszystko git :)")
    end
    for k,v in pairs(SEMI_LOOT_SORTER_TBL) do
    for _, semi_naszItemek in ipairs(v.semi_itemsTBL) do
    semi_naszItemek = semi_naszItemek:lower()
    while itemcount(semi_naszItemek, pickFromContainerWithName) > 0 do
    listas("[semiSortLoot]: Moving '".. semi_naszItemek .."', from '".. pickFromContainerWithName .."' to '".. v.semi_containerName .."'.")
    if checkHowMuchSpaceLeftInContainer(v.semi_containerName) < 1 then
    openNextContainerWithTheSameNameFunction(v.semi_containerName)
    end
    moveitems(semi_naszItemek, v.semi_containerName, pickFromContainerWithName, 100)
    end
    end
    end
    listas("[semiSortLoot]: Finished moving items.")
    if openNextContainerWithSameName then
    listas("[semiSortLoot]: Looking for next container to open...")
    openNextContainerWithTheSameNameFunction(pickFromContainerWithName)
    end
    end






    And now to hotkey:


    auto(10)
    semiSortLoot("brocade backpack", true)




    Instruction:

    You have to put all items into 1 backpack (backpack > backpack > backpack > backpack) with the same colour. (Change color/name of container in hotkey, just put here your container name instead of brocade backpack)
    Now just open backpacks required to sort loot (You can change names in peristent script above)

    For now i only added few items to test it and it works good, later i will add all items + maybe i will add more features.


    Aha, if u have house and items there, so just open brocade backpack and run this hotkey:

    auto (100)
    pickUpItemsFromCurrentSQMToBP("brocade backpack")


    have fun
    Seminari
    [FREE] Port Hope Coryms for ek (90-120 exp/h 16-22 k gold/h)
    http://forums.tibiawindbot.com/attac...2&d=1409228006
    Sort your loot even in depot!
    http://forums.tibiawindbot.com/showt...-even-in-depot!

  2. #2
    Free User Borges's Avatar
    Join Date
    Feb 2014
    Location
    Brazil
    Posts
    1,469
    Reputation
    205
    Rep Power
    25
    Cool Boy... This action reach and open depot?

    I'm working right now... I'll test soon...

    I was working with a action like this but using loot category... if it is possible to add this option to your script I would greatly appreciate it.

    Thanks for share.
    Last edited by Borges; 08-28-2014 at 06:12 PM.
    Helped you? REP+

  3. #3
    Free User Cezarus's Avatar
    Join Date
    Jul 2014
    Location
    Proland
    Posts
    57
    Reputation
    14
    Rep Power
    20
    Quote Originally Posted by borges View Post
    Cool Boy... This action reach and open depot?

    I'm working right now... I'll test soon...

    I was working with a action like this but using loot category... if it is possible to add this option to your script I would greatly appreciate it.

    Thanks for share.
    Ye, it's not a problem but i just wonder why u want to use this way it xD

    Ok ill script it later cause now i have to do something else at house.
    Seminari
    [FREE] Port Hope Coryms for ek (90-120 exp/h 16-22 k gold/h)
    http://forums.tibiawindbot.com/attac...2&d=1409228006
    Sort your loot even in depot!
    http://forums.tibiawindbot.com/showt...-even-in-depot!

  4. #4
    Helper StaR's Avatar
    Join Date
    Dec 2013
    Location
    Manchester
    Posts
    713
    Reputation
    50
    Rep Power
    22
    Quote Originally Posted by borges View Post
    Cool Boy... This action reach and open depot?

    I'm working right now... I'll test soon...

    I was working with a action like this but using loot category... if it is possible to add this option to your script I would greatly appreciate it.

    Thanks for share.
    Is it not just easier to edit the hotkey instead of adding a new loot and selecting a category ?



  5. #5
    Free User Borges's Avatar
    Join Date
    Feb 2014
    Location
    Brazil
    Posts
    1,469
    Reputation
    205
    Rep Power
    25
    Quote Originally Posted by StaR View Post
    Is it not just easier to edit the hotkey instead of adding a new loot and selecting a category ?
    manually on all my scripts? if works like a charm... maybe yes.
    @Cezarus I have tested and have some errors like this:
    line 24				"rrotection amulet",
    line 72 "sakebite rod",


    This is not the problem... I have fixed this and added all my items.

    The script just deposit first section (SEMI_YASIR_ITEMS) and get stuck.
    Last edited by Borges; 08-29-2014 at 01:24 PM.
    Helped you? REP+

  6. #6
    Free User Cezarus's Avatar
    Join Date
    Jul 2014
    Location
    Proland
    Posts
    57
    Reputation
    14
    Rep Power
    20
    Quote Originally Posted by borges View Post
    manually on all my scripts? if works like a charm... maybe yes.
    @Cezarus I have tested and have some errors like this:
    line 24				"rrotection amulet",
    line 72 "sakebite rod",


    This is not the problem... I have fixed this and added all my items.

    The script just deposit first section (SEMI_YASIR_ITEMS) and get stuck.

    change to

    "protection amulet"
    "snakebite rod"

    also, i will update this script with all items but later cause now i don;t have enough time to do that
    Seminari
    [FREE] Port Hope Coryms for ek (90-120 exp/h 16-22 k gold/h)
    http://forums.tibiawindbot.com/attac...2&d=1409228006
    Sort your loot even in depot!
    http://forums.tibiawindbot.com/showt...-even-in-depot!

  7. #7
    Free User Borges's Avatar
    Join Date
    Feb 2014
    Location
    Brazil
    Posts
    1,469
    Reputation
    205
    Rep Power
    25
    Quote Originally Posted by Cezarus View Post
    change to

    "protection amulet"
    "snakebite rod"

    also, i will update this script with all items but later cause now i don;t have enough time to do that
    as I said above, this is not the problem, I'm just telling you what is wrong.

    the error is that it puts only the first section and crashes.
    Helped you? REP+

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •