diff options
author | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-05-19 15:50:41 +0000 |
---|---|---|
committer | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-05-19 15:50:41 +0000 |
commit | b9804183841afd5381069796096a154edb5b9f53 (patch) | |
tree | 95e6f70d9ecd43e727d0defe1b02a818bc191169 /src/common/mapindex.c | |
parent | 3bd682b3cb3507c8a57fa6930475808981fd0663 (diff) | |
download | hercules-b9804183841afd5381069796096a154edb5b9f53.tar.gz hercules-b9804183841afd5381069796096a154edb5b9f53.tar.bz2 hercules-b9804183841afd5381069796096a154edb5b9f53.tar.xz hercules-b9804183841afd5381069796096a154edb5b9f53.zip |
Reformatting @_@
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10581 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/common/mapindex.c')
-rw-r--r-- | src/common/mapindex.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/common/mapindex.c b/src/common/mapindex.c index 37afcad3d..36bd32cb5 100644 --- a/src/common/mapindex.c +++ b/src/common/mapindex.c @@ -64,7 +64,8 @@ int mapindex_addmap(int index, const char *name) return 1; } -unsigned short mapindex_name2id(const char* name) { +unsigned short mapindex_name2id(const char* name) +{ //TODO: Perhaps use a db to speed this up? [Skotlex] int i; char map_name[MAP_NAME_LENGTH_EXT]; @@ -91,7 +92,8 @@ unsigned short mapindex_name2id(const char* name) { #endif } -const char* mapindex_id2name(unsigned short id) { +const char* mapindex_id2name(unsigned short id) +{ if (id > MAX_MAPINDEX || !indexes[id].exists) { ShowDebug("mapindex_id2name: Requested name for non-existant map index [%d] in cache.\n", id); return indexes[0].name; //Theorically this should never happen, hence we return this string to prevent null pointer crashes. @@ -99,7 +101,8 @@ const char* mapindex_id2name(unsigned short id) { return indexes[id].name; } -void mapindex_init(void) { +void mapindex_init(void) +{ FILE *fp; char line[1024]; int last_index = -1; @@ -130,5 +133,6 @@ void mapindex_init(void) { fclose(fp); } -void mapindex_final(void) { +void mapindex_final(void) +{ } |