mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-09 15:29:32 +07:00
Terrace Farms: Bonus resource restriction (#2522)
This commit is contained in:
@ -184,13 +184,13 @@
|
|||||||
{
|
{
|
||||||
"name": "Terrace farm",
|
"name": "Terrace farm",
|
||||||
"uniqueTo": "Inca",
|
"uniqueTo": "Inca",
|
||||||
|
"terrainsCanBeBuiltOn": ["Hill"],
|
||||||
"food": 1,
|
"food": 1,
|
||||||
"turnsToBuild": 7,
|
"turnsToBuild": 7,
|
||||||
"uniques": ["+1 food for each adjacent Mountain"],
|
"uniques": ["+1 food for each adjacent Mountain", "Cannot be built on bonus resource"],
|
||||||
"techRequired": "Construction",
|
"techRequired": "Construction",
|
||||||
"improvingTech": "Fertilizer",
|
"improvingTech": "Fertilizer",
|
||||||
"improvingTechStats": {"food":1},
|
"improvingTechStats": {"food":1}
|
||||||
"terrainsCanBeBuiltOn": ["Hill"]
|
|
||||||
},
|
},
|
||||||
|
|
||||||
{ "name": "Ancient ruins" },
|
{ "name": "Ancient ruins" },
|
||||||
|
@ -271,6 +271,8 @@ open class TileInfo {
|
|||||||
improvement.name == this.improvement -> false
|
improvement.name == this.improvement -> false
|
||||||
improvement.uniqueTo != null && improvement.uniqueTo != civInfo.civName -> false
|
improvement.uniqueTo != null && improvement.uniqueTo != civInfo.civName -> false
|
||||||
improvement.techRequired?.let { civInfo.tech.isResearched(it) } == false -> 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.terrainsCanBeBuiltOn.contains(topTerrain.name) -> true
|
||||||
improvement.name == "Road" && roadStatus == RoadStatus.None -> true
|
improvement.name == "Road" && roadStatus == RoadStatus.None -> true
|
||||||
improvement.name == "Railroad" && this.roadStatus != RoadStatus.Railroad -> true
|
improvement.name == "Railroad" && this.roadStatus != RoadStatus.Railroad -> true
|
||||||
|
Reference in New Issue
Block a user