mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-20 23:52:40 +08:00
fix tiledmap show wrong (#10059)
This commit is contained in:
@@ -383,7 +383,6 @@ function traverseGrids (leftDown: { col: number, row: number }, rightTop: { col:
|
||||
cols = checkColRange && leftDown.col < rowData.minCol ? rowData.minCol : leftDown.col;
|
||||
}
|
||||
|
||||
const renderData = _renderData!.renderData;
|
||||
// traverse col
|
||||
for (; (cols - col) * colMoveDir >= 0; col += colMoveDir) {
|
||||
colData = rowData && rowData[col];
|
||||
@@ -424,6 +423,7 @@ function traverseGrids (leftDown: { col: number, row: number }, rightTop: { col:
|
||||
// begin to fill vertex buffer
|
||||
tiledNode = tiledTiles[colData.index];
|
||||
|
||||
const renderData = _renderData!.renderData;
|
||||
renderData.reserve(4, 0);
|
||||
_vfOffset = renderData.vertexCount * 9;
|
||||
vertexBuf = renderData.vData;
|
||||
|
||||
Reference in New Issue
Block a user