diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-05-29 14:30:20 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-05-29 14:30:20 +0300 |
commit | 0f9ec2061c4ad6157c3186f1cab9c4d8558980b5 (patch) | |
tree | 6259593b8436178ad8d981a96a8fd71eab9e04cc /src/net/npchandler.h | |
parent | 01773c71a4698c6f01fe70d864f922bda65506cb (diff) | |
download | manaverse-0f9ec2061c4ad6157c3186f1cab9c4d8558980b5.tar.gz manaverse-0f9ec2061c4ad6157c3186f1cab9c4d8558980b5.tar.bz2 manaverse-0f9ec2061c4ad6157c3186f1cab9c4d8558980b5.tar.xz manaverse-0f9ec2061c4ad6157c3186f1cab9c4d8558980b5.zip |
Add strong typed int type BeingId.
Diffstat (limited to 'src/net/npchandler.h')
-rw-r--r-- | src/net/npchandler.h | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/src/net/npchandler.h b/src/net/npchandler.h index 42eaabb00..83c896d1c 100644 --- a/src/net/npchandler.h +++ b/src/net/npchandler.h @@ -27,6 +27,8 @@ #include "enums/being/cookingtype.h" +#include "enums/simpletypes/beingid.h" + #include "localconsts.h" namespace Net @@ -40,31 +42,34 @@ class NpcHandler notfinal virtual ~NpcHandler() { } - virtual int getNpc(Net::MessageIn &msg) = 0; + virtual BeingId getNpc(Net::MessageIn &msg) = 0; - virtual void talk(const int npcId) const = 0; + virtual void talk(const BeingId npcId) const = 0; - virtual void nextDialog(const int npcId) const = 0; + virtual void nextDialog(const BeingId npcId) const = 0; - virtual void closeDialog(const int npcId) = 0; + virtual void closeDialog(const BeingId npcId) = 0; - virtual void listInput(const int npcId, + virtual void listInput(const BeingId npcId, const unsigned char value) const = 0; - virtual void integerInput(const int npcId, const int value) const = 0; + virtual void integerInput(const BeingId npcId, + const int value) const = 0; - virtual void stringInput(const int npcId, + virtual void stringInput(const BeingId npcId, const std::string &value) const = 0; - virtual void buy(const int beingId) const = 0; + virtual void buy(const BeingId beingId) const = 0; - virtual void sell(const int beingId) const = 0; + virtual void sell(const BeingId beingId) const = 0; - virtual void buyItem(const int beingId, const int itemId, + virtual void buyItem(const BeingId beingId, + const int itemId, const unsigned char color, const int amount) const = 0; - virtual void sellItem(const int beingId, const int itemId, + virtual void sellItem(const BeingId beingId, + const int itemId, const int amount) const = 0; virtual void completeProgressBar() const = 0; |