summaryrefslogtreecommitdiff
path: root/src/map/map.c
diff options
context:
space:
mode:
authorgreenboxal2 <greenboxal2@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-11 22:37:41 +0000
committergreenboxal2 <greenboxal2@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-11 22:37:41 +0000
commitc7ca0a3ce5982cc83043cdf3f9cd30f391c77b02 (patch)
treeef95f0ef7444a31ecb775ba108f2764fea8e37d9 /src/map/map.c
parent3ec480937ea4f48e37762d93fadb7909f31eea83 (diff)
downloadhercules-c7ca0a3ce5982cc83043cdf3f9cd30f391c77b02.tar.gz
hercules-c7ca0a3ce5982cc83043cdf3f9cd30f391c77b02.tar.bz2
hercules-c7ca0a3ce5982cc83043cdf3f9cd30f391c77b02.tar.xz
hercules-c7ca0a3ce5982cc83043cdf3f9cd30f391c77b02.zip
Follow up r16403, adjusted map_reloadnpcs to follow new config standards(r16382).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16404 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/map.c')
-rw-r--r--src/map/map.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/src/map/map.c b/src/map/map.c
index 9a5350e2d..37a8eab5d 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -3378,10 +3378,16 @@ void map_reloadnpc_sub(char *cfgName)
fclose(fp);
}
-void map_reloadnpc()
+void map_reloadnpc(bool clear)
{
- npc_addsrcfile("clear"); // this will clear the current script list
- map_reloadnpc_sub(MAP_CONF_NAME);
+ if (clear)
+ npc_addsrcfile("clear"); // this will clear the current script list
+
+#ifdef RENEWAL
+ map_reloadnpc_sub("npc/re/scripts_main.conf");
+#else
+ map_reloadnpc_sub("npc/pre-re/scripts_main.conf");
+#endif
}
int inter_config_read(char *cfgName)
@@ -3888,11 +3894,8 @@ int do_init(int argc, char *argv[])
map_config_read(MAP_CONF_NAME);
/* only temporary until sirius's datapack patch is complete */
-#ifdef RENEWAL
- map_config_read("npc/re/scripts_main.conf");
-#else
- map_config_read("npc/pre-re/scripts_main.conf");
-#endif
+ // loads npcs
+ map_reloadnpc(false);
chrif_checkdefaultlogin();