XenoBot Forums - Powered by vBulletin

User Tag List

Results 1 to 4 of 4

Thread: Loot Opend Bodies

  1. #1

    Join Date
    Aug 2017
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Loot Opend Bodies

    Hey.. I hope you all guys doing fine.

    I searched a lot for a script that can loot an item when I open the monster dead body ...

    I mean "I want a script when I open the Dead Monster Body, It automatically move the item from the dead body to the opened backpack or to the main backpack".


    I hope someone help me I really need it ..


    I'm using Xenobot 10.00 as I'm playing Highexp.eu..

    Thanks in advance.
    REGARDS

  2. #2

    Join Date
    Aug 2017
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    BUMP
    NO ONE?

  3. #3

    Join Date
    Feb 2017
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Bump!
    want this too

  4. #4

    Join Date
    Sep 2017
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ATTENTION: This is very primitive and not smart at all but it gets you what you want:

    To make it work:

    You gotta have 2 containers opened, 1st Container = Your Main Backpack, 2nd container = Your Monster Dead Body as shown in the picture:

    8PI6SUB.png

    Afterwards just activate the script, and it will check the item and put it automatically on your backpack...

    Cons:

    - You gotta manually open the monster dead body.
    - No item index checking or "item-on-slot" checking on either of the containers (You have to check manually where the item is located (slot) in the dead monster container)
    - Only loots x1 body at at time (if you want to loot more bodies I can make a paid script for you, jksss xDD)

    Code:
    local container_name = Container:Name()
    local dead_monster_name = "Dead Dragon" --[[ CHANGE THIS TO YOUR DEAD MONSTER NAME --]]
    local next_container
    local opened_container_gold
    local item_id = Item.GetID("gold coin") --[[ CHANGE THIS TO YOUR ITEM NAME TO LOOT --]]
    
    while(true)
    do
    	next_container = Container.GetNextOpen(0)
    	if (container_name == "Backpack" and next_container:Name() == dead_monster_name)
    	then
    		opened_container_gold = next_container:CountItemsOfID(item_id)
    		print("Looting " .. opened_container_gold .. " Gold!")
    		next_container:MoveItemToContainer(0, 0, 0) --[[ CHANGE THIS TO WHETHER THE ITEM IS USUALLY LOCATED WHEN YOU OPEN THE DEAD MONSTER --]]
    	end
    	wait(1000, 1500)
    end
    You need more information on the MoveItemToContainer API you can use this for instructions on how to use it:

    http://xenobot.wikia.com/wiki/Contai...temToContainer
    Last edited by 0xNOP; 09-06-2017 at 07:10 PM.

Posting Permissions

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