summaryrefslogtreecommitdiff
path: root/src/net/playerhandler.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/playerhandler.h')
-rw-r--r--src/net/playerhandler.h25
1 files changed, 21 insertions, 4 deletions
diff --git a/src/net/playerhandler.h b/src/net/playerhandler.h
index 399afb5e..f9396caf 100644
--- a/src/net/playerhandler.h
+++ b/src/net/playerhandler.h
@@ -24,13 +24,14 @@
#include "being.h"
#include "flooritem.h"
-#include "localplayer.h"
namespace Net {
class PlayerHandler
{
public:
+ virtual ~PlayerHandler() {}
+
virtual void attack(int id) = 0;
virtual void emote(int emoteId) = 0;
@@ -61,9 +62,25 @@ class PlayerHandler
virtual int getJobLocation() = 0;
- virtual Vector getDefaultWalkSpeed() = 0;
-
- virtual ~PlayerHandler() {}
+ /**
+ * Get the original default movement speed.
+ * Example:
+ * In ticks per tiles for eAthena
+ * In tiles per second for Manaserv
+ */
+ virtual Vector getDefaultMoveSpeed() const = 0;
+
+ /**
+ * Convert the original speed in pixel per tick for internal use.
+ */
+ virtual Vector getPixelsPerTickMoveSpeed(const Vector &speed,
+ Map *map = 0) = 0;
+
+ /**
+ * Tells whether the client has to use pixel paths.
+ * Return false when tiles-center positions only are to be used.
+ */
+ virtual bool usePixelPrecision() = 0;
};
} // namespace Net