mirror of
https://github.com/Xiao-MoMi/craft-engine.git
synced 2026-01-06 15:52:03 +00:00
修复注入时机
This commit is contained in:
@@ -150,7 +150,6 @@ public class BukkitWorldManager implements WorldManager, Listener {
|
||||
this.worlds.put(uuid, ceWorld);
|
||||
this.resetWorldArray();
|
||||
this.injectChunkGenerator(ceWorld);
|
||||
injectWorldCallback(ceWorld.world.serverWorld());
|
||||
}
|
||||
|
||||
@EventHandler(ignoreCancelled = true, priority = EventPriority.LOWEST)
|
||||
@@ -208,6 +207,7 @@ public class BukkitWorldManager implements WorldManager, Listener {
|
||||
|
||||
private void injectChunkGenerator(CEWorld world) {
|
||||
Object serverLevel = world.world.serverWorld();
|
||||
injectWorldCallback(serverLevel);
|
||||
Object serverChunkCache = FastNMS.INSTANCE.method$ServerLevel$getChunkSource(serverLevel);
|
||||
Object chunkMap = FastNMS.INSTANCE.field$ServerChunkCache$chunkMap(serverChunkCache);
|
||||
FastNMS.INSTANCE.injectedWorldGen(world, chunkMap);
|
||||
|
||||
Reference in New Issue
Block a user