summaryrefslogtreecommitdiff
path: root/src/net/protocol.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/protocol.cpp')
-rw-r--r--src/net/protocol.cpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/net/protocol.cpp b/src/net/protocol.cpp
index e57be110..7a98ffb6 100644
--- a/src/net/protocol.cpp
+++ b/src/net/protocol.cpp
@@ -23,13 +23,10 @@
#include "protocol.h"
-#include "messagein.h"
#include "messageout.h"
-#include "network.h"
#include "../being.h"
#include "../game.h"
-#include "../log.h"
#include "../main.h"
#include "../playerinfo.h"
#include "../sound.h"
@@ -85,6 +82,21 @@ void action(char type, int id)
outMsg.writeInt8(type);
}
+void talk(Being *being)
+{
+ MessageOut outMsg;
+ outMsg.writeInt16(CMSG_NPC_TALK);
+ outMsg.writeInt32(being->getId());
+ outMsg.writeInt8(0);
+}
+
+void pickUp(Uint32 floorItemId)
+{
+ MessageOut outMsg;
+ outMsg.writeInt16(0x009f);
+ outMsg.writeInt32(floorItemId);
+}
+
Being* attack(unsigned short x, unsigned short y, unsigned char direction)
{
Being *target = NULL;