Sun 17 Jun 2012 09:44:32 PM UTC, comment #5:
> ; only lake fish
> reqs =
> { "type", "name", "range"
> "Terrain", "Lake (Fish)", "Adjacent"
> }
Do you plan to give city a bonus if it's adjacent to at least one Fish tile?
I think tile bonus (such as increase to food/shield/trade) applied to every applicable tile adjacent to city center is more like what you are after:
reqs =
{ "type", "name", "range"
"Resource", "Fish", "Local"
"Terrain", "Lake", "Local"
"CityTile", "Center", "Adjacent"
}
As range here for Resource and Terrain requirements is "Local" (the tile itself) it's guaranteed that it's the same tile fulfilling both requirements.
|
Sun 17 Jun 2012 09:52:37 AM UTC, comment #3:
Hm, I see what you're saying, but there's no reason it should be limited to a terrain+resource combination. You could reasonably require other combinations of properties on a single tile: terrain, resources, specials, roads, bases, a city, ...
e.g., Terrain(Mountains) + Resource(Gold) + Base(Gold mine).
So rather than calling this "Resource", I think it would be a new universal called something like "Tile" or "TileProperties". Its argument would have a mini expression language for specifying combinations of things (possibly with some disambiguation syntax for the case where, say, a special and a resource have the same name).
Off-hand, I don't see any reason in principle why such a thing couldn't be done; I think the most complicated aspect would be for those parts of the system that take apart requirements and try to analyse them, such as the AI (to work out how to meet them) and the on-line help.
I think those things suggest that the expression language should only be additive ("Lake AND Fish", but not "Plains AND NOT Road"), at least at first.
Covering all tile properties with this is unlikely to be much more work than just Terrain+Resources.
However... knowing how much effort we have available, I'm inclined to aim for the simple Resource universal first, because that should be easy and obvious, and gets you some capability before we get round to the complicated thing.
|
Sun 17 Jun 2012 02:42:02 AM UTC, comment #2:
I can see two ways in which you would want to search for a resource; Just for itself, and for it on a terrain. e.g.
; Voting governments have a senate that may prevent war
; any fish
reqs =
{ "type", "name", "range"
"Resource", "(Fish)", "Adjacent"
}
; only lake fish
reqs =
{ "type", "name", "range"
"Terrain", "Lake (Fish)", "Adjacent"
}
So which is more extensible? The first seems simpler but there is no way to get the information of the tile back. Putting a terrain req below it will match even if the terrain is in another square on any range other than CityCentre or Local (Am I correct on this?). As such, I recommend the second way. Even though it takes may take more reqs to define events, it seems a more powerful method.
|
Sat 16 Jun 2012 11:53:46 AM UTC, original submission:
Effects can specify requirements of terrain, specials, bases, and roads, but not resources (wheat, gold, etc).
This seems like an oversight that would be easy to fix.
|