mirror of
https://github.com/FancyInnovations/FancyPlugins.git
synced 2025-12-06 07:43:36 +00:00
fancynpcs: The correct NpcsLoadedEvent call (#67)
This commit is contained in:
committed by
GitHub
parent
0395b942a1
commit
ea91095bcf
@@ -227,7 +227,7 @@ public class NpcManagerImpl implements NpcManager {
|
||||
YamlConfiguration npcConfig = YamlConfiguration.loadConfiguration(npcConfigFile);
|
||||
|
||||
if (!npcConfig.isConfigurationSection("npcs")) {
|
||||
isLoaded = true;
|
||||
this.setLoaded();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -438,7 +438,10 @@ public class NpcManagerImpl implements NpcManager {
|
||||
npc.create();
|
||||
registerNpc(npc);
|
||||
}
|
||||
this.setLoaded();
|
||||
}
|
||||
|
||||
private void setLoaded(){
|
||||
isLoaded = true;
|
||||
new NpcsLoadedEvent().callEvent();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user