mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
Fix belt underlays not rendering
This commit is contained in:
parent
b7efda9bf6
commit
d4cbb5b124
@ -32,7 +32,10 @@ export class BeltUnderlaysSystem extends GameSystemWithFilter {
|
|||||||
for (let i = 0; i < contents.length; ++i) {
|
for (let i = 0; i < contents.length; ++i) {
|
||||||
const entity = contents[i];
|
const entity = contents[i];
|
||||||
const underlayComp = entity.components.BeltUnderlays;
|
const underlayComp = entity.components.BeltUnderlays;
|
||||||
if (underlayComp) {
|
if (!underlayComp) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
const staticComp = entity.components.StaticMapEntity;
|
const staticComp = entity.components.StaticMapEntity;
|
||||||
const underlays = underlayComp.underlays;
|
const underlays = underlayComp.underlays;
|
||||||
for (let i = 0; i < underlays.length; ++i) {
|
for (let i = 0; i < underlays.length; ++i) {
|
||||||
@ -49,7 +52,7 @@ export class BeltUnderlaysSystem extends GameSystemWithFilter {
|
|||||||
|
|
||||||
// Culling, #2
|
// Culling, #2
|
||||||
if (
|
if (
|
||||||
parameters.visibleRect.containsRect4Params(
|
!parameters.visibleRect.containsRect4Params(
|
||||||
destX,
|
destX,
|
||||||
destY,
|
destY,
|
||||||
globalConfig.tileSize,
|
globalConfig.tileSize,
|
||||||
@ -79,4 +82,3 @@ export class BeltUnderlaysSystem extends GameSystemWithFilter {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user