From 37432edac65a6b85c7a3414a421f2afd3e67a14e Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Tue, 31 Mar 2009 15:11:26 -0600 Subject: Add first draft of net handlers eAthena NPC handler has been implemented and is being used for NPC interraction. --- src/gui/npc_text.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'src/gui/npc_text.cpp') diff --git a/src/gui/npc_text.cpp b/src/gui/npc_text.cpp index 31f48486..b33b9970 100644 --- a/src/gui/npc_text.cpp +++ b/src/gui/npc_text.cpp @@ -28,11 +28,10 @@ #include "../npc.h" -#include "../net/messageout.h" #ifdef TMWSERV_SUPPORT #include "../net/tmwserv/gameserver/player.h" #else -#include "../net/ea/protocol.h" +#include "../net/ea/npchandler.h" #endif #include "../utils/gettext.h" @@ -126,19 +125,19 @@ void NpcTextDialog::action(const gcn::ActionEvent &event) void NpcTextDialog::nextDialog(int npcID) { + // Net::getNpcHandler()->nextDialog(npcID); #ifdef TMWSERV_SUPPORT Net::GameServer::Player::talkToNPC(npcID, false); #else - MessageOut outMsg(CMSG_NPC_NEXT_REQUEST); - outMsg.writeInt32(npcID); + npcHandler->nextDialog(npcID); #endif } void NpcTextDialog::closeDialog(int npcID) { + // Net::getNpcHandler()->closeDialog(npcID); #ifdef EATHENA_SUPPORT - MessageOut outMsg(CMSG_NPC_CLOSE); - outMsg.writeInt32(npcID); + npcHandler->closeDialog(npcID); #endif } -- cgit v1.2.3-60-g2f50