So if you write @dropequip 512 it will drop all your Mid Headgear in inventory? Or only drop it when equipped in Mid Head?
To drop spesific equip in inventory:
Open .../map/atcommand.c
Search:
/*==========================================
* @dropall by [MouseJstr]
* Drop all your possession on the ground
*------------------------------------------*/
ACMD_FUNC(dropall)
{
int i;
nullpo_retr(-1, sd);
for (i = 0; i < MAX_INVENTORY; i++) {
if (sd->status.inventory[i].amount) {
if(sd->status.inventory[i].equip != 0)
pc_unequipitem(sd, i, 3);
pc_dropitem(sd, i, sd->status.inventory[i].amount);
}
}
return 0;
}
Add below:
/*==========================================
* @dropequip [FE]
* Drop spesific equipment to the ground
*------------------------------------------*/
ACMD_FUNC(dropequip)
{
int i;
unsigned short pos;
nullpo_retr(-1, sd);
if (!message || !*message) {
clif_displaymessage(fd, "Please enter equip location: @dropequip <equip_location>");
clif_displaymessage(fd, " 1: Head Low 2: Hand Right 4: Garment 8: Acc Left");
clif_displaymessage(fd, " 16: Armor 32: Hand Left 64: Shoes 128: Acc Right");
clif_displaymessage(fd, "256: Head Top 512: Head Mid");
return -1;
}
pos = atoi(message);
for (i = 0; i < MAX_INVENTORY; i++) {
if (sd->status.inventory[i].amount && sd->inventory_data[i]->equip&pos) {
if(sd->status.inventory[i].equip != 0)
pc_unequipitem(sd, i, 3); //unequip item if equipped
pc_dropitem(sd, i, sd->status.inventory[i].amount);
}
}
return 0;
}
Search:
{ "dropall", 40,40, atcommand_dropall },
Add below:
{ "dropequip", 40,40, atcommand_dropequip },
Recompile..
Open .../conf/atcommand_athena.conf
Search:
// Drop all your items
dropall: 40,60
Add below:
// Drop spesific equipment
dropequip: 40,60
I hope it right