From a996d4bff3cc5a35ee5cdb6cb5bdef920cf44120 Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Wed, 25 Feb 2009 07:03:38 -0700 Subject: If no network is set, then don't continue Only checks in these two palces for now, as missing network in the others would indicate a design flaw. --- src/npc.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/npc.cpp') diff --git a/src/npc.cpp b/src/npc.cpp index 0d568309..701e280b 100644 --- a/src/npc.cpp +++ b/src/npc.cpp @@ -112,6 +112,7 @@ Being::Type NPC::getType() const void NPC::talk() { + if (!mNetwork) return; MessageOut outMsg(mNetwork); outMsg.writeInt16(CMSG_NPC_TALK); outMsg.writeInt32(mId); @@ -120,6 +121,7 @@ void NPC::talk() void NPC::nextDialog() { + if (!mNetwork) return; MessageOut outMsg(mNetwork); outMsg.writeInt16(CMSG_NPC_NEXT_REQUEST); outMsg.writeInt32(mId); -- cgit v1.2.3-70-g09d2