From 4a7a692c81c3b2fe7ebe089b5051005e841c41c8 Mon Sep 17 00:00:00 2001 From: Lajos Meszaros Date: Sun, 15 Oct 2023 22:19:18 +0200 Subject: [PATCH] fix(EntityModel): make sure to have unique indices when generating ftl --- src/EntityModel.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/EntityModel.ts b/src/EntityModel.ts index 41c6cd14..5cd6149a 100644 --- a/src/EntityModel.ts +++ b/src/EntityModel.ts @@ -144,9 +144,9 @@ export class EntityModel { }) if (i % 3 === 0) { - faceIndexes.push([idx, -1, -1]) + faceIndexes.push([-1, -1, i]) } else { - faceIndexes[faceIndexes.length - 1][i % 3] = idx + faceIndexes[faceIndexes.length - 1][2 - (i % 3)] = i } })