| 8 | } |
| 9 | |
| 10 | void CLayerFront::SetTile(int x, int y, CTile Tile) |
| 11 | { |
| 12 | if(Tile.m_Index == TILE_THROUGH_CUT) |
| 13 | { |
| 14 | Map()->m_pGameLayer->CLayerTiles::SetTile(x, y, CTile{TILE_NOHOOK}); // NOLINT(bugprone-parent-virtual-call) |
| 15 | } |
| 16 | else if(Tile.m_Index == TILE_AIR && CLayerTiles::GetTile(x, y).m_Index == TILE_THROUGH_CUT) |
| 17 | { |
| 18 | Map()->m_pGameLayer->CLayerTiles::SetTile(x, y, CTile{TILE_AIR}); // NOLINT(bugprone-parent-virtual-call) |
| 19 | } |
| 20 | if(Editor()->IsAllowPlaceUnusedTiles() || IsValidFrontTile(Tile.m_Index)) |
| 21 | { |
| 22 | CLayerTiles::SetTile(x, y, Tile); |
| 23 | } |
| 24 | else |
| 25 | { |
| 26 | CLayerTiles::SetTile(x, y, CTile{TILE_AIR}); |
| 27 | ShowPreventUnusedTilesWarning(); |
| 28 | } |
| 29 | } |
| 30 | |
| 31 | void CLayerFront::Resize(int NewW, int NewH) |
| 32 | { |
nothing calls this directly
no test coverage detected