Skip to content

Commit

Permalink
fix: Fixing missing await in animation generation spawning 2 tilesets
Browse files Browse the repository at this point in the history
  • Loading branch information
moufmouf committed Dec 13, 2023
1 parent 38a98e2 commit ae57ab4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Optimizer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ export class Optimizer {

private async optimizeNewTile(tileId: number): Promise<number> {
if (this.logLevel === LogLevel.VERBOSE) {
console.log(`${tileId} tile is optimizing...`);
//console.log(`${tileId} tile is optimizing...`);
}

let minBitId;
Expand Down Expand Up @@ -321,7 +321,7 @@ export class Optimizer {
if (tileData.animation) {
newTileData.animation = [];
for (const frame of tileData.animation) {
this.optimizeNewTile(oldFirstgid + frame.tileid);
await this.optimizeNewTile(oldFirstgid + frame.tileid);

newTileData.animation.push({
duration: frame.duration,
Expand Down

0 comments on commit ae57ab4

Please sign in to comment.