View Full Version : Drop.Equipement(x, y, z)
acrozo01
05-01-2016, 01:53 AM
Hello,
This my suggestion.
Drop.Head(x, y, z)
Drop.Armor(x, y, z)
Drop.Legs(x, y, z)
Drop.Feet(x, y, z)
Drop.Amulet(x, y, z)
Drop.Weapon(x, y, z)
Drop.Ring(x, y, z)
Drop.Backpack(x, y, z)
Drop.Shield(x, y, z)
Drop.Ammo(x, y, z)
They will drop the item from equipement specified.
krille09
05-01-2016, 03:23 AM
local slots = {"head", "armor", "weapon", "shield", "legs", "feet"}
local eq = {"item 1", "item 2", "item 3"}
Module.New("drop eq", function()
local bp = Container.GetFirst()
local pos = Self.Position()
for i = 1, #slots do
Self.Dequip(slots[i], bp)
end
Self.DropItems(pos.x, pos.y, pos.z, eq)
end)
SLOT_HEAD = 0
SLOT_AMULET = 1
SLOT_BACKPACK = 2
SLOT_ARMOR = 3
SLOT_SHIELD = 4
SLOT_WEAPON = 5
SLOT_LEGS = 6
SLOT_FEET = 7
SLOT_RING = 8
SLOT_AMMO = 9
EQUIPMENT_SLOTS = {"head", "amulet", "backpack", "armor", "shield", "weapon", "legs", "feet", "ring", "ammo"}
Self.Dequip(slot, container)
Self.DropItems(x, y, z, ...)
acrozo01
05-01-2016, 01:38 PM
Thanks.
EDIT : I can't drop my Backpack.
local slots = {"head", "amulet", "backpack", "armor", "shield", "weapon", "legs", "feet", "ring", "ammo"}
local eq = {"Backpack"}
Module.New("drop eq", function()
local bp = Container.GetFirst()
local pos = Self.Position()
for i = 1, #slots do
Self.Dequip(slots[i], bp)
end
Self.DropItems(pos.x, pos.y, pos.z, eq)
end)
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.