[1.20] Paper compatibility fixes
Signed-off-by: Irmo van den Berge <irmo.vandenberge@ziggo.nl>
This commit is contained in:
1 parent
1967397426
commit
aade1bc8b0
2 files changed
+10
No files matched your search
@@ -1967,7 +1967,13 @@ class Entity {
|
||||
}
|
||||
|
||||
public (WorldHandle) World getWorld:level();
|
||||
|
||||
// Public on Paper
|
||||
#if exists net.minecraft.world.entity.Entity public void setLevel(net.minecraft.world.level.World world);
|
||||
public void setWorld:setLevel((WorldHandle) World world);
|
||||
#else
|
||||
protected void setWorld:setLevel((WorldHandle) World world);
|
||||
#endif
|
||||
#else
|
||||
public org.bukkit.World getBukkitWorld() {
|
||||
#if version >= 1.17
|
||||
|
||||
+4
@@ -12,7 +12,11 @@ optional class LightEngineThreaded {
|
||||
#require LightEngineThreaded private final net.minecraft.server.level.PlayerChunkMap chunkMap;
|
||||
net.minecraft.server.level.PlayerChunkMap pcm = instance#chunkMap;
|
||||
net.minecraft.server.level.WorldServer world = pcm.level;
|
||||
#if version >= 1.20
|
||||
world.chunkTaskScheduler.parallelGenExecutor.queueRunnable(runnable);
|
||||
#else
|
||||
world.chunkTaskScheduler.lightExecutor.queueRunnable(runnable);
|
||||
#endif
|
||||
|
||||
#else
|
||||
// Spigot/Legacy Paper
|
||||
|
||||
Reference in new issue
Block a user