summaryrefslogtreecommitdiff
path: root/src/net/ea/npchandler.h
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2009-04-02 14:54:43 +0200
committerBjørn Lindeijer <bjorn@lindeijer.nl>2009-04-02 15:02:59 +0200
commitd20b79683997990a1b46ac8d4117f9195aa278f2 (patch)
tree8566fe6cd224003100be35743645c948536f26e8 /src/net/ea/npchandler.h
parent128f908908b77b242b749b27879ba2a9f70a94f6 (diff)
downloadmana-client-d20b79683997990a1b46ac8d4117f9195aa278f2.tar.gz
mana-client-d20b79683997990a1b46ac8d4117f9195aa278f2.tar.bz2
mana-client-d20b79683997990a1b46ac8d4117f9195aa278f2.tar.xz
mana-client-d20b79683997990a1b46ac8d4117f9195aa278f2.zip
Some cleanup and renaming
* Removed superfluous 'virtual' keyword in *Handler implementations * Renamed NPCHandler to NpcHandler * Renamed InvyHandler to InventoryHandler * Made all *Handler interface methods pure virtual * Used forward declarations in net.h * Renamed {start,end}Shoping to {start,end}Shopping
Diffstat (limited to 'src/net/ea/npchandler.h')
-rw-r--r--src/net/ea/npchandler.h36
1 files changed, 22 insertions, 14 deletions
diff --git a/src/net/ea/npchandler.h b/src/net/ea/npchandler.h
index a8212ce0..9ca83f11 100644
--- a/src/net/ea/npchandler.h
+++ b/src/net/ea/npchandler.h
@@ -24,35 +24,43 @@
#include "net/messagehandler.h"
#include "net/net.h"
+#include "net/npchandler.h"
-class NPCHandler : public MessageHandler, public Net::NpcHandler
+class NpcHandler : public MessageHandler, public Net::NpcHandler
{
public:
- NPCHandler();
+ NpcHandler();
- virtual void handleMessage(MessageIn &msg);
+ void handleMessage(MessageIn &msg);
- virtual void talk(int npcId);
+ void talk(int npcId);
- virtual void nextDialog(int npcId);
+ void nextDialog(int npcId);
- virtual void closeDialog(int npcId);
+ void closeDialog(int npcId);
- virtual void listInput(int npcId, int value);
+ void listInput(int npcId, int value);
- virtual void integerInput(int npcId, int value);
+ void integerInput(int npcId, int value);
- virtual void stringInput(int npcId, const std::string &value);
+ void stringInput(int npcId, const std::string &value);
- virtual void buy(int beingId);
+ void sendLetter(int npcId, const std::string &recipient,
+ const std::string &text);
- virtual void sell(int beingId);
+ void startShopping(int beingId);
- virtual void buyItem(int beingId, int itemId, int amount);
+ void buy(int beingId);
- virtual void sellItem(int beingId, int itemId, int amount);
+ void sell(int beingId);
+
+ void buyItem(int beingId, int itemId, int amount);
+
+ void sellItem(int beingId, int itemId, int amount);
+
+ void endShopping(int beingId);
};
-extern NPCHandler *npcHandler;
+extern NpcHandler *npcHandler;
#endif // NET_EA_NPCHANDLER_H