Skip to content
Snippets Groups Projects
Unverified Commit 51c9e6a3 authored by Julian Dreuth's avatar Julian Dreuth Committed by Leon Lux
Browse files

Fix/change doors

parent 848e9d9a
No related branches found
No related tags found
1 merge request!55Abgabe des Projektes
......@@ -128,8 +128,9 @@ class CenterGrid : public QWidget
*/
std::vector<int> m_tileIDList = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 32, 33, 34, 35, 36,
37, 38, 39, 40, 41, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73,
96, 97, 98, 99, 100, 101, 128, 129, 130, 131, 132, 133, 160, 161, 162,
163, 164, 165, 192, 193, 194, 195, 201, 224, 225, 226, 227, 232, 233};
96, 97, 98, 99, 100, 101, 102, 103, 104, 128, 129, 130, 131, 132, 133,
134, 135, 136, 160, 161, 162, 163, 164, 165, 166, 167, 168, 192, 193, 194,
195, 198, 199, 201, 224, 225, 226, 227, 232, 233};
/**
* @brief List of all spriteIDs that are mobs
......
......@@ -118,8 +118,19 @@ MainWindow::MainWindow(DialogSelection selected, const std::filesystem::path &pa
int x = gameObject.position.x;
int y = gameObject.position.y;
int tileID = gameObject.id;
m_centerGrid->setCurrentSprite(m_leftWidget->getPixmapByIndex(tileID), tileID);
m_centerGrid->onTileClicked(x, y);
switch (tileID)
{
case 0:
m_centerGrid->setCurrentSprite(m_leftWidget->getPixmapByIndex(22), 22);
break;
case 1:
m_centerGrid->setCurrentSprite(m_leftWidget->getPixmapByIndex(86), 86);
break;
case 2:
m_centerGrid->setCurrentSprite(m_leftWidget->getPixmapByIndex(86), 146);
break;
}
m_centerGrid->onTileClicked(x,y);
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment