#NPC don't spawn on plugin startup!
30 messages · Page 1 of 1 (latest)
Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.
It work if i add a delay in the event.
Has your issue been resolved, or your question been answered?
If so, please use the </resolved:1028673926114594866> command to close your thread.
Or </invalid:1028673926898909185> if it's not possible to resolve.
If not yet resolved, please reply below to tell us what you still need.
(Note that if there is no reply for a few days, this thread will eventually close itself.)
@shut harness
This is in the "onEnable" method
And it is not working, it is directly inspired from your code
In the console > SPAWNED 1
Any ideas ?
In addition, it work with default npc command, but when i use my custom storage, npc's only spawn if I add delay to the event! What am I doing wrong ? I can't find any docs, and I read your code, still can't figure out why i'm getting this problem.
You have all you need, can be easily reproduce, just put this code in onEnable method.
There is no more code
@shut harness the implementation of createStorageNPC?
BUMP
BUMP
@shut harness patients please
Alright
works perfectly fine (code runs after citizensenableevent)
Has your issue been resolved, or your question been answered?
If so, please use the </resolved:1028673926114594866> command to close your thread.
Or </invalid:1028673926898909185> if it's not possible to resolve.
If not yet resolved, please reply below to tell us what you still need.
(Note that if there is no reply for a few days, this thread will eventually close itself.)
@shut harness
YamlStorage yamlStorage = new YamlStorage(new File(CitizensAPI.getDataFolder(), "test.yml"));
yamlStorage.load();
NPCDataStore npcds = SimpleNPCDataStore.create(yamlStorage);
NPCRegistry npcReg = CitizensAPI.createCitizensBackedNPCRegistry(npcds);
npcds.loadInto(npcReg);
Has your issue been resolved, or your question been answered?
If so, please use the </resolved:1028673926114594866> command to close your thread.
Or </invalid:1028673926898909185> if it's not possible to resolve.
If not yet resolved, please reply below to tell us what you still need.
(Note that if there is no reply for a few days, this thread will eventually close itself.)
@shut harness