Terrace Farms: Bonus resource restriction (#2522)
This commit is contained in:
parent
818adbd1a3
commit
5e5a175f06
2 changed files with 5 additions and 3 deletions
|
@ -184,13 +184,13 @@
|
|||
{
|
||||
"name": "Terrace farm",
|
||||
"uniqueTo": "Inca",
|
||||
"terrainsCanBeBuiltOn": ["Hill"],
|
||||
"food": 1,
|
||||
"turnsToBuild": 7,
|
||||
"uniques": ["+1 food for each adjacent Mountain"],
|
||||
"uniques": ["+1 food for each adjacent Mountain", "Cannot be built on bonus resource"],
|
||||
"techRequired": "Construction",
|
||||
"improvingTech": "Fertilizer",
|
||||
"improvingTechStats": {"food":1},
|
||||
"terrainsCanBeBuiltOn": ["Hill"]
|
||||
"improvingTechStats": {"food":1}
|
||||
},
|
||||
|
||||
{ "name": "Ancient ruins" },
|
||||
|
|
|
@ -271,6 +271,8 @@ open class TileInfo {
|
|||
improvement.name == this.improvement -> false
|
||||
improvement.uniqueTo != null && improvement.uniqueTo != civInfo.civName -> false
|
||||
improvement.techRequired?.let { civInfo.tech.isResearched(it) } == false -> false
|
||||
"Cannot be built on bonus resource" in improvement.uniques && resource != null
|
||||
&& getTileResource().resourceType == ResourceType.Bonus -> false
|
||||
improvement.terrainsCanBeBuiltOn.contains(topTerrain.name) -> true
|
||||
improvement.name == "Road" && roadStatus == RoadStatus.None -> true
|
||||
improvement.name == "Railroad" && this.roadStatus != RoadStatus.Railroad -> true
|
||||
|
|
Loading…
Reference in a new issue