mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-14 01:48:04 -04:00
physics: fix movement into unloaded chunks
This commit is contained in:
parent
cd0885a56c
commit
7be7124013
@ -213,7 +213,7 @@ abstract class Entity(
|
||||
val result = VoxelShape()
|
||||
for (blockPosition in blockPositions) {
|
||||
val chunk = connection.world.getChunk(blockPosition.chunkPosition)
|
||||
if (chunk == null && !ignoreUnloadedChunks) {
|
||||
if ((chunk == null || !chunk.isFullyLoaded) && !ignoreUnloadedChunks) {
|
||||
// chunk is not loaded
|
||||
result.add(VoxelShape.FULL + blockPosition)
|
||||
continue
|
||||
@ -284,7 +284,7 @@ abstract class Entity(
|
||||
}
|
||||
}
|
||||
velocity?.let {
|
||||
move(it * deltaTime)
|
||||
move(it * deltaTime, false)
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user