| 632 | } |
| 633 | |
| 634 | int Room::getCostRepair() |
| 635 | { |
| 636 | if(!canBeRepaired()) |
| 637 | return 0; |
| 638 | |
| 639 | int nbTiles = 0; |
| 640 | for(Tile* tile : mCoveredTilesDestroyed) |
| 641 | { |
| 642 | // We check if the tiles can be repaired |
| 643 | if(!tile->isBuildableUpon(getSeat())) |
| 644 | continue; |
| 645 | |
| 646 | ++nbTiles; |
| 647 | } |
| 648 | return nbTiles * RoomManager::costPerTile(getType()); |
| 649 | } |
| 650 | |
| 651 | void Room::repairRoom() |
| 652 | { |
no test coverage detected