diff options
author | Taylor Locke <kisuka@kisuka.com> | 2015-09-05 16:21:53 -0700 |
---|---|---|
committer | Taylor Locke <kisuka@kisuka.com> | 2015-09-05 16:21:53 -0700 |
commit | 6bb416f305c8d814561d611365ad8a1e91120b30 (patch) | |
tree | 7cd656d12ddde4efaaa5edc670525451720422cd /src | |
parent | 8229ecb0f71629f840f57d714f0fbf293dade9d5 (diff) | |
download | hercules-6bb416f305c8d814561d611365ad8a1e91120b30.tar.gz hercules-6bb416f305c8d814561d611365ad8a1e91120b30.tar.bz2 hercules-6bb416f305c8d814561d611365ad8a1e91120b30.tar.xz hercules-6bb416f305c8d814561d611365ad8a1e91120b30.zip |
Added RE/Pre-RE start_point ability.
Diffstat (limited to 'src')
-rw-r--r-- | src/char/char.c | 51 |
1 files changed, 38 insertions, 13 deletions
diff --git a/src/char/char.c b/src/char/char.c index 819cd2ef8..c54fedb8c 100644 --- a/src/char/char.c +++ b/src/char/char.c @@ -140,7 +140,11 @@ struct fame_list chemist_fame_list[MAX_FAME_LIST]; struct fame_list taekwon_fame_list[MAX_FAME_LIST]; // Initial position (it's possible to set it in conf file) -struct point start_point = { 0, 53, 111 }; +#ifdef RENEWAL + struct point start_point = { 0, 97, 90 }; +#else + struct point start_point = { 0, 53, 111 }; +#endif unsigned short skillid2idx[MAX_SKILL_ID]; @@ -5639,17 +5643,33 @@ int char_config_read(const char* cfgName) autosave_interval = DEFAULT_AUTOSAVE_INTERVAL; } else if (strcmpi(w1, "save_log") == 0) { save_log = config_switch(w2); - } else if (strcmpi(w1, "start_point") == 0) { - char map[MAP_NAME_LENGTH_EXT]; - int x, y; - if (sscanf(w2, "%15[^,],%d,%d", map, &x, &y) < 3) - continue; - start_point.map = mapindex->name2id(map); - if (!start_point.map) - ShowError("Specified start_point %s not found in map-index cache.\n", map); - start_point.x = x; - start_point.y = y; - } else if (strcmpi(w1, "start_items") == 0) { + } + #ifdef RENEWAL + else if (strcmpi(w1, "start_point") == 0) { + char map[MAP_NAME_LENGTH_EXT]; + int x, y; + if (sscanf(w2, "%15[^,],%d,%d", map, &x, &y) < 3) + continue; + start_point.map = mapindex->name2id(map); + if (!start_point.map) + ShowError("Specified start_point %s not found in map-index cache.\n", map); + start_point.x = x; + start_point.y = y; + } + #else + else if (strcmpi(w1, "start_point_pre") == 0) { + char map[MAP_NAME_LENGTH_EXT]; + int x, y; + if (sscanf(w2, "%15[^,],%d,%d", map, &x, &y) < 3) + continue; + start_point.map = mapindex->name2id(map); + if (!start_point.map) + ShowError("Specified start_point_pre %s not found in map-index cache.\n", map); + start_point.x = x; + start_point.y = y; + } + #endif + else if (strcmpi(w1, "start_items") == 0) { int i; char *split; @@ -5876,7 +5896,12 @@ int do_init(int argc, char **argv) { //Read map indexes mapindex->init(); - start_point.map = mapindex->name2id("new_zone01"); + + #ifdef RENEWAL + start_point.map = mapindex->name2id("iz_int"); + #else + start_point.map = mapindex->name2id("new_1-1"); + #endif cmdline->exec(argc, argv, CMDLINE_OPT_NORMAL); chr->config_read(chr->CHAR_CONF_NAME); |