Skip to content

Commit 6dd5652

Browse files
committed
Port a quick fix from @immortius to multiplayer branch in preparation of making a one-time stable build before retiring it soon.
1 parent 102b5df commit 6dd5652

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/org/terasology/rendering/world/WorldRenderer.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,8 @@ public boolean updateChunksInProximity(boolean force) {
242242
// remove
243243
List<Rect2i> removeRects = Rect2i.difference(oldView, newView);
244244
for (Rect2i r : removeRects) {
245-
for (int x = r.minX(); x < r.maxX(); ++x) {
246-
for (int y = r.minY(); y < r.maxY(); ++y) {
245+
for (int x = r.minX(); x <= r.maxX(); ++x) {
246+
for (int y = r.minY(); y <= r.maxY(); ++y) {
247247
Chunk c = chunkProvider.getChunk(x, 0, y);
248248
if (c != null) {
249249
chunksInProximity.remove(c);
@@ -256,8 +256,8 @@ public boolean updateChunksInProximity(boolean force) {
256256
// add
257257
List<Rect2i> addRects = Rect2i.difference(newView, oldView);
258258
for (Rect2i r : addRects) {
259-
for (int x = r.minX(); x < r.maxX(); ++x) {
260-
for (int y = r.minY(); y < r.maxY(); ++y) {
259+
for (int x = r.minX(); x <= r.maxX(); ++x) {
260+
for (int y = r.minY(); y <= r.maxY(); ++y) {
261261
Chunk c = chunkProvider.getChunk(x, 0, y);
262262
if (c != null && c.getChunkState() == Chunk.State.COMPLETE && worldProvider.getLocalView(c.getPos()) != null) {
263263
chunksInProximity.add(c);

0 commit comments

Comments
 (0)