triple-layer: fix creating tilesets

This commit is contained in:
SBird 2020-06-30 16:05:56 +02:00 committed by huderlem
parent b7d1db61a8
commit 18b9e5fbee

View file

@ -1070,8 +1070,9 @@ void MainWindow::on_actionNew_Tileset_triggered() {
editor->project->loadTilesetTiles(newSet, *tilesImage);
newSet->metatiles = new QList<Metatile*>();
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)