diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-07-13 19:52:12 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-07-13 19:52:12 -0600 |
commit | 666211542df4fd4fb0f9a1c936b54f6405ef09ba (patch) | |
tree | 478ea55ae467406f2f90f8941a2c5bc2a74a48db /src/net/tmwserv | |
parent | 6c764b3c95d0c078c5ccebac607517353e64dc55 (diff) | |
download | mana-client-666211542df4fd4fb0f9a1c936b54f6405ef09ba.tar.gz mana-client-666211542df4fd4fb0f9a1c936b54f6405ef09ba.tar.bz2 mana-client-666211542df4fd4fb0f9a1c936b54f6405ef09ba.tar.xz mana-client-666211542df4fd4fb0f9a1c936b54f6405ef09ba.zip |
Some item pickup cleaning
Still need to find where to attach LocalPlayer::pickedUp for TMWServ.
Diffstat (limited to 'src/net/tmwserv')
-rw-r--r-- | src/net/tmwserv/gameserver/player.cpp | 8 | ||||
-rw-r--r-- | src/net/tmwserv/gameserver/player.h | 1 | ||||
-rw-r--r-- | src/net/tmwserv/playerhandler.cpp | 5 |
3 files changed, 4 insertions, 10 deletions
diff --git a/src/net/tmwserv/gameserver/player.cpp b/src/net/tmwserv/gameserver/player.cpp index 93853681..733b7cdc 100644 --- a/src/net/tmwserv/gameserver/player.cpp +++ b/src/net/tmwserv/gameserver/player.cpp @@ -41,14 +41,6 @@ void Net::GameServer::Player::walk(int x, int y) Net::GameServer::connection->send(msg); } -void Net::GameServer::Player::pickUp(int x, int y) -{ - MessageOut msg(PGMSG_PICKUP); - msg.writeInt16(x); - msg.writeInt16(y); - Net::GameServer::connection->send(msg); -} - void Net::GameServer::Player::moveItem(int oldSlot, int newSlot, int amount) { MessageOut msg(PGMSG_MOVE_ITEM); diff --git a/src/net/tmwserv/gameserver/player.h b/src/net/tmwserv/gameserver/player.h index 24b25dc7..76d7844b 100644 --- a/src/net/tmwserv/gameserver/player.h +++ b/src/net/tmwserv/gameserver/player.h @@ -41,7 +41,6 @@ namespace Net namespace Player { void walk(int x, int y); - void pickUp(int x, int y); void moveItem(int oldSlot, int newSlot, int amount); void useSpecial(int special); void requestTrade(int id); diff --git a/src/net/tmwserv/playerhandler.cpp b/src/net/tmwserv/playerhandler.cpp index 825da8a4..6cf81496 100644 --- a/src/net/tmwserv/playerhandler.cpp +++ b/src/net/tmwserv/playerhandler.cpp @@ -335,7 +335,10 @@ void PlayerHandler::decreaseStat(LocalPlayer::Attribute attr) void PlayerHandler::pickUp(FloorItem *floorItem) { int id = floorItem->getId(); - Net::GameServer::Player::pickUp(id >> 16, id & 0xFFFF); + MessageOut msg(PGMSG_PICKUP); + msg.writeInt16(id >> 16); + msg.writeInt16(id & 0xFFFF); + Net::GameServer::connection->send(msg); } void PlayerHandler::setDirection(char direction) |