summaryrefslogtreecommitdiff
path: root/src/map/clif.cpp
diff options
context:
space:
mode:
authorBen Longbons <b.r.longbons@gmail.com>2014-10-25 15:24:26 -0700
committerBen Longbons <b.r.longbons@gmail.com>2014-10-26 14:21:48 -0700
commit86395f53634b3ef1ce76a7f1e5edfdb61f8ffd80 (patch)
tree2710c62fe71d5e0d2e228fba9c951a040c4dcddf /src/map/clif.cpp
parent6800761863dd45b6055768febc6ace6a20120dc7 (diff)
downloadtmwa-86395f53634b3ef1ce76a7f1e5edfdb61f8ffd80.tar.gz
tmwa-86395f53634b3ef1ce76a7f1e5edfdb61f8ffd80.tar.bz2
tmwa-86395f53634b3ef1ce76a7f1e5edfdb61f8ffd80.tar.xz
tmwa-86395f53634b3ef1ce76a7f1e5edfdb61f8ffd80.zip
Fix header ranking
Diffstat (limited to 'src/map/clif.cpp')
-rw-r--r--src/map/clif.cpp45
1 files changed, 7 insertions, 38 deletions
diff --git a/src/map/clif.cpp b/src/map/clif.cpp
index a5b7278..430d928 100644
--- a/src/map/clif.cpp
+++ b/src/map/clif.cpp
@@ -36,22 +36,25 @@
#include "../strings/xstring.hpp"
#include "../io/cxxstdio.hpp"
-#include "../io/cxxstdio_enums.hpp"
+#include "../io/extract.hpp"
#include "../io/write.hpp"
#include "../net/ip.hpp"
-#include "../net/packets.hpp"
#include "../net/socket.hpp"
#include "../net/timer.hpp"
+#include "../net/timestamp-utils.hpp"
#include "../proto2/any-user.hpp"
#include "../proto2/char-map.hpp"
#include "../proto2/map-user.hpp"
-#include "../mmo/md5more.hpp"
-#include "../mmo/utils.hpp"
+#include "../mmo/cxxstdio_enums.hpp"
#include "../mmo/version.hpp"
+#include "../high/md5more.hpp"
+
+#include "../wire/packets.hpp"
+
#include "atcommand.hpp"
#include "battle.hpp"
#include "chrif.hpp"
@@ -5675,38 +5678,4 @@ void do_init_clif(void)
{
make_listen_port(map_port, SessionParsers{.func_parse= clif_parse, .func_delete= clif_delete});
}
-
-bool extract(XString str, DIR *d)
-{
- unsigned di;
- if (extract(str, &di) && di < 8)
- {
- *d = static_cast<DIR>(di);
- return true;
- }
- const struct
- {
- LString str;
- DIR d;
- } dirs[] =
- {
- {"S"_s, DIR::S},
- {"SW"_s, DIR::SW},
- {"W"_s, DIR::W},
- {"NW"_s, DIR::NW},
- {"N"_s, DIR::N},
- {"NE"_s, DIR::NE},
- {"E"_s, DIR::E},
- {"SE"_s, DIR::SE},
- };
- for (auto& pair : dirs)
- {
- if (str == pair.str)
- {
- *d = pair.d;
- return true;
- }
- }
- return false;
-}
} // namespace tmwa