From 73fe28e6ad029106280f9c73e2bb2bd53d991072 Mon Sep 17 00:00:00 2001 From: Eugenio Favalli Date: Fri, 9 Sep 2005 17:37:41 +0000 Subject: Fixes to dropped items network code --- ChangeLog | 4 ++++ src/game.cpp | 12 +++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index b50458c8..353421de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2005-08-30 Eugenio Favalli + + * src/game.cpp: Fixes to dropped items network code + 2005-09-09 Bjørn Lindeijer * src/net/win2linux.h: Removed inclusion of malloc.h header as it diff --git a/src/game.cpp b/src/game.cpp index 45bc4dce..bfabc528 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -969,7 +969,9 @@ void do_parse() if (in_size >= 2) { // Check if the received packet is complete while (in_size >= (len = get_packet_length(id = RFIFOW(0)))) { +#ifdef DEBUG printf("Packet_ID: %x\n", RFIFOW(0)); +#endif // Parse packet based on their id switch (id) @@ -1683,15 +1685,15 @@ void do_parse() case 0x009d: case 0x009e: floorItem = new FloorItem(); - floorItem->id = net_w_value(RFIFOW(6)); - floorItem->x = net_w_value(RFIFOW(9)); - floorItem->y = net_w_value(RFIFOW(11)); - floorItem->int_id = net_l_value(RFIFOL(2)); + floorItem->id = RFIFOW(6); + floorItem->x = RFIFOW(9); + floorItem->y = RFIFOW(11); + floorItem->int_id = RFIFOL(2); add_floor_item(floorItem); break; // Item disappearing case 0x00a1: - remove_floor_item(net_l_value(RFIFOL(2))); + remove_floor_item(RFIFOL(2)); break; // Next/Close button in NPC dialog case 0x00b5: -- cgit v1.2.3-70-g09d2