summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/npc_text.cpp7
-rw-r--r--src/gui/npc_text.h2
2 files changed, 9 insertions, 0 deletions
diff --git a/src/gui/npc_text.cpp b/src/gui/npc_text.cpp
index 954f22d8..61f3e510 100644
--- a/src/gui/npc_text.cpp
+++ b/src/gui/npc_text.cpp
@@ -126,6 +126,13 @@ void NpcTextDialog::nextDialog(int npcID)
outMsg.writeInt32(npcID);
}
+void NpcTextDialog::closeDialog(int npcID)
+{
+ MessageOut outMsg(mNetwork);
+ outMsg.writeInt16(CMSG_NPC_CLOSE);
+ outMsg.writeInt32(npcID);
+}
+
void NpcTextDialog::widgetResized(const gcn::Event &event)
{
Window::widgetResized(event);
diff --git a/src/gui/npc_text.h b/src/gui/npc_text.h
index 019c22a5..f030115b 100644
--- a/src/gui/npc_text.h
+++ b/src/gui/npc_text.h
@@ -79,6 +79,8 @@ class NpcTextDialog : public Window, public gcn::ActionListener
void nextDialog(int npcID = current_npc);
+ void closeDialog(int npcID = current_npc);
+
/**
* Called when resizing the window.
*