Skip to content
This repository was archived by the owner on Sep 12, 2022. It is now read-only.

Commit 0991357

Browse files
authored
Fixed chunks not updating correctly (#11, #12)
1 parent 4d89b61 commit 0991357

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

src/muqsit/worldstyler/utils/Utils.php

-10
Original file line numberDiff line numberDiff line change
@@ -100,21 +100,11 @@ public static function humanFilesize(string $file, int $decimals = 2) : string
100100

101101
public static function updateChunks(Level $level, int $minChunkX, int $maxChunkX, int $minChunkZ, int $maxChunkZ) : void
102102
{
103-
for ($chunkX = $minChunkX; $chunkX <= $maxChunkX; ++$chunkX) {
104-
for ($chunkZ = $minChunkZ; $chunkZ <= $maxChunkZ; ++$chunkZ) {
105-
$level->clearChunkCache($chunkX, $chunkZ);
106-
foreach ($level->getChunkLoaders($chunkX, $chunkZ) as $loader) {
107-
$loader->onChunkChanged($level->getChunk($chunkX, $chunkZ));
108-
}
109-
}
110-
}
111-
/*
112103
for ($chunkX = $minChunkX; $chunkX <= $maxChunkX; ++$chunkX) {
113104
for ($chunkZ = $minChunkZ; $chunkZ <= $maxChunkZ; ++$chunkZ) {
114105
$level->setChunk($chunkX, $chunkZ, $level->getChunk($chunkX, $chunkZ), false);
115106
}
116107
}
117-
*/
118108
}
119109

120110
public static function getBlockFromString(string $block) : ?Block

0 commit comments

Comments
 (0)