调整炮弹区块加载逻辑
This commit is contained in:
parent
2f663490fc
commit
d179badd92
1 changed files with 2 additions and 2 deletions
|
@ -44,7 +44,7 @@ public class ChunkLoadTool {
|
||||||
|
|
||||||
chunksToUnload.forEach(chunk -> {
|
chunksToUnload.forEach(chunk -> {
|
||||||
var chunkPos = new ChunkPos(chunk);
|
var chunkPos = new ChunkPos(chunk);
|
||||||
controller.forceChunk(level, entity, chunkPos.x, chunkPos.z, false, false);
|
Mod.queueServerWork(10, () -> controller.forceChunk(level, entity, chunkPos.x, chunkPos.z, false, false));
|
||||||
});
|
});
|
||||||
|
|
||||||
loadedChunks.clear();
|
loadedChunks.clear();
|
||||||
|
@ -57,7 +57,7 @@ public class ChunkLoadTool {
|
||||||
public static void unloadAllChunks(ServerLevel level, Entity entity, Set<Long> loadedChunks) {
|
public static void unloadAllChunks(ServerLevel level, Entity entity, Set<Long> loadedChunks) {
|
||||||
loadedChunks.forEach(chunk -> {
|
loadedChunks.forEach(chunk -> {
|
||||||
var chunkPos = new ChunkPos(chunk);
|
var chunkPos = new ChunkPos(chunk);
|
||||||
controller.forceChunk(level, entity, chunkPos.x, chunkPos.z, false, false);
|
Mod.queueServerWork(10, () -> controller.forceChunk(level, entity, chunkPos.x, chunkPos.z, false, false));
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue