diff options
Diffstat (limited to 'src/gamehandler.cpp')
-rw-r--r-- | src/gamehandler.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gamehandler.cpp b/src/gamehandler.cpp index 42cb0c70..968325a7 100644 --- a/src/gamehandler.cpp +++ b/src/gamehandler.cpp @@ -178,7 +178,7 @@ void GameHandler::processMessage(NetComputer *comp, MessageIn &message) // remove the item from world map // send feedback - computer.getCharacter()->addInventory(itemId); + computer.getCharacter()->addItem(itemId); result.writeShort(GPMSG_PICKUP_RESPONSE); result.writeByte(ERRMSG_OK); } break; @@ -211,11 +211,11 @@ void GameHandler::processMessage(NetComputer *comp, MessageIn &message) case PGMSG_EQUIP: { - int itemId = message.readLong(); + int itemId = message.readLong(); // Not useful, the inventory knows it char slot = message.readByte(); result.writeShort(GPMSG_EQUIP_RESPONSE); - result.writeByte(computer.getCharacter()->equip(itemId, slot) ? + result.writeByte(computer.getCharacter()->equip(slot) ? ERRMSG_OK : ERRMSG_FAILURE); } break; |