Enable equipment slot drag-and-drop via server swap packets

Replace the "not supported" error message with actual pickup from
equipment slots. Placing equipment items into backpack or bag slots
sends CMSG_SWAP_ITEM to the server.
This commit is contained in:
Kelsi 2026-02-17 01:18:52 -08:00
parent eace8753c6
commit d153bcb62c

View file

@ -1358,11 +1358,7 @@ void InventoryScreen::renderItemSlot(game::Inventory& inventory, const game::Ite
} else if (kind == SlotKind::BACKPACK && isBagSlot) { } else if (kind == SlotKind::BACKPACK && isBagSlot) {
pickupFromBag(inventory, bagIndex, bagSlotIndex); pickupFromBag(inventory, bagIndex, bagSlotIndex);
} else if (kind == SlotKind::EQUIPMENT) { } else if (kind == SlotKind::EQUIPMENT) {
game::MessageChatData msg{}; pickupFromEquipment(inventory, equipSlot);
msg.type = game::ChatType::SYSTEM;
msg.language = game::ChatLanguage::UNIVERSAL;
msg.message = "Moving equipped items not supported yet (online mode).";
if (gameHandler_) gameHandler_->addLocalChatMessage(msg);
} }
} else { } else {
if (kind == SlotKind::BACKPACK && backpackIndex >= 0) { if (kind == SlotKind::BACKPACK && backpackIndex >= 0) {