|
@@ -3648,12 +3648,16 @@ bool npc_unloadfile( const char* path ) {
|
|
|
for( nd = dbi_first(iter); dbi_exists(iter); nd = dbi_next(iter) ) {
|
|
|
if( nd->path && strcasecmp(nd->path,path) == 0 ) {
|
|
|
found = true;
|
|
|
+ npc_unload_duplicates(nd);/* unload any npcs which could duplicate this but be in a different file */
|
|
|
npc_unload(nd, true);
|
|
|
}
|
|
|
}
|
|
|
|
|
|
dbi_destroy(iter);
|
|
|
|
|
|
+ if( found ) /* refresh event cache */
|
|
|
+ npc_read_event_script();
|
|
|
+
|
|
|
return found;
|
|
|
}
|
|
|
void do_clear_npc(void) {
|