Well, after some time I've having this problem again.
It actually just close the inventory, but It doesn't delete the item.
Can someone help me out?
I've used this script to make it throw away
function M60Image::onDone(%this, %obj, %slot)
{
%obj.toolAmmo[%obj.currTool] = 0;
%obj.playThread(2, activate);
Parent::OnDone(%this, %obj, %slot);
%obj.unMountImage(%slot);
%count = %obj.getDatablock().maxTools;
for(%i = 0; %i < %count; %i++)
{
if(%obj.tool[%i] == M60Item.getID())
{
%currentSlot = %i;
break;
}
}
%obj.tool[%currSlot] = 0;
%obj.weaponCount--;
messageClient(%obj.client,'MsgItemPickup','',%currSlot,0);
%obj.unmountImage(%slot);
}