diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-11-09 00:16:58 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-11-15 11:47:30 +0300 |
commit | 50cb8eeff4386e5546da35c40de93c891af47d0d (patch) | |
tree | 49f32efa5b5be350112f5ef1413f4db41d7d9d06 /src/char/geoip.c | |
parent | e4f78d0a13233181cec890b24c77748e32b2fd03 (diff) | |
download | hercules-50cb8eeff4386e5546da35c40de93c891af47d0d.tar.gz hercules-50cb8eeff4386e5546da35c40de93c891af47d0d.tar.bz2 hercules-50cb8eeff4386e5546da35c40de93c891af47d0d.tar.xz hercules-50cb8eeff4386e5546da35c40de93c891af47d0d.zip |
Create geoip interface.
Diffstat (limited to 'src/char/geoip.c')
-rw-r--r-- | src/char/geoip.c | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/char/geoip.c b/src/char/geoip.c new file mode 100644 index 000000000..9a78c1ebd --- /dev/null +++ b/src/char/geoip.c @@ -0,0 +1,32 @@ +// Copyright (c) Hercules Dev Team, licensed under GNU GPL. +// See the LICENSE file +// Portions Copyright (c) Athena Dev Teams + +#define HERCULES_CORE + +#include "geoip.h" + +#include <stdlib.h> + +#include "../common/cbasetypes.h" +#include "../common/mmo.h" +#include "../common/random.h" +#include "../common/showmsg.h" +#include "../common/socket.h" +#include "../common/strlib.h" + +struct s_geoip geoip_data; + +const char* geoip_getcountry(uint32 ipnum); +void geoip_final(bool shutdown); +void geoip_init(void); + +void geoip_defaults(void) { + geoip = &geoip_s; + + geoip->data = &geoip_data; + + geoip->getcountry = geoip_getcountry; + geoip->final = geoip_final; + geoip->init = geoip_init; +} |