If you're still willing to pare this down, revert your source code and try this one:
[Item.cpp.patch]
Code:
Index: common/Item.cpp
===================================================================
--- common/Item.cpp (revision 2284)
+++ common/Item.cpp (working copy)
@@ -1216,6 +1216,14 @@
else {
// Slot must be within a bag
ItemInst* baginst = GetItem(Inventory::CalcSlotId(slot_id)); // Get parent bag
+
+ if (baginst) {
+ LogFile->write(EQEMuLog::Error, "Inventory::_PutItem: Parent Bag: id = %i, class = %i, type = %i, parent slot = %i", baginst->GetID(), baginst->GetItem()->ItemClass, baginst->GetItem()->ItemType, Inventory::CalcSlotId(slot_id));
+ }
+ else {
+ LogFile->write(EQEMuLog::Error, "Inventory::_PutItem: Parent Bag instance is NULL at parent slot %i", Inventory::CalcSlotId(slot_id));
+ }
+
if (baginst && baginst->IsType(ItemClassContainer)) {
baginst->_PutItem(Inventory::CalcBagIdx(slot_id), inst);
result = slot_id;
This will tell us what's going on with the bag instance that might cause that con check to fail.