summaryrefslogtreecommitdiff
path: root/src/net/buysellhandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/buysellhandler.cpp')
-rw-r--r--src/net/buysellhandler.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/net/buysellhandler.cpp b/src/net/buysellhandler.cpp
index a2442d70..714bc0ea 100644
--- a/src/net/buysellhandler.cpp
+++ b/src/net/buysellhandler.cpp
@@ -65,7 +65,7 @@ void BuySellHandler::handleMessage(MessageIn *msg)
sellDialog->setVisible(false);
sellDialog->reset();
buySellDialog->setVisible(true);
- current_npc = dynamic_cast<NPC*>(beingManager->findBeing(msg->readInt32()));
+ current_npc = msg->readInt32();
break;
case SMSG_NPC_BUY:
@@ -107,7 +107,7 @@ void BuySellHandler::handleMessage(MessageIn *msg)
}
else {
chatWindow->chatLog(_("Nothing to sell"), BY_SERVER);
- if (current_npc) current_npc->handleDeath();
+ current_npc = 0;
}
break;