I tried placing this code into my main function in OrcStronghold.c :
if(!mouse_panel && mouse_left && inv_is_floating)
{
var item_id = inv_get_floating_icon_item_id ();
pan_remove(global_floating_item_ptr->floating_item_panel);
switch(item_id)
{
case SWORD: ent_create ("sword.mdl", nullvector,
NULL); break;
case MACE: ent_create ("mace.mdl", nullvector, NULL);
break;
}
}
However, still nothing is happening when I click a floating item outside the inventory bag, when I am trying to drop it from my inventory. The floating item (like an image of a sword, in the inventory bag, that you are trying to drop) does not disappear.
It seems that I only need to figure out how to remove a floating image of an equipment item, if I want to drop that equipment item from the bag.