diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 22a2b3bd..98b2be70 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1070,8 +1070,9 @@ void MainWindow::on_actionNew_Tileset_triggered() { editor->project->loadTilesetTiles(newSet, *tilesImage); newSet->metatiles = new QList(); for(int i = 0; i < numMetaTiles; ++i) { + int tilesPerMetatile = projectConfig.getTripleLayerMetatilesEnabled() ? 12 : 8; Metatile *mt = new Metatile(); - for(int j = 0; j < 8; ++j){ + for(int j = 0; j < tilesPerMetatile; ++j){ Tile *tile = new Tile(); //Create a checkerboard-style dummy tileset if(((i / 8) % 2) == 0)