Whoa!
Okay, I just did some testing of a few different resource consumption scenarios, in order to lay the groundwork for what I can and cannot do with these HQ's. I think I just stumbled across something very interesting, and unexpected. Maybe someone else has discovered this before, but some brief searching yielded no results, and it certainly wasn't common knowledge for anyone I asked, so I've decided to quickly document my findings.
My original thought, as posted earlier, was to have some of these HQ's both
require a certain resource be available before it can be built, but then
additionally consume certain resources as well.
The former is easy enough with either
<Building_LocalResourceAnds> or
<Building_LocalResourceOrs> as these will check to make sure there's an improved source of whatever resource nearby before allowing construction.
The latter can be achieved through to use of
<Building_ResourceQuantityRequirements> except that the only examples you have in the base game is to consume
Strategic resources such as Iron and Coal. This makes sense because there is an easily visible counter at the top of the screen that shows you how many you have left.
Furthermore, both of these tables can be used in conjunction with each other to have a building both
require, for example, Horses
and consume a number of Horses at the same time.
However!
My intention was to try to consume
all types of resources, not only strategic.
Unfortunately, no one I asked seemed to know if this was possible, and I had imagined it probably wouldn't be possible, because Bonus and Luxury resources didn't seem to be "counted" (at least as visibly as the strategic resources.)
But hey, what's being a modder without testing stuff? So, off I went to test this by creating buildings which required:
In other words, a test to see if I could make a building consume Bonus and Luxury resources, as well as a "control" consuming strategics which I knew would work.
Surprisingly..
It works!
Even though Sheep and Wine are not counted in the same place as the Horses, they were still counted. This makes sense for Wine, since the game had to know how many copies of a Luxury resource to trade away, but I don't know of
anything in the base game which counts the number of Sheep (or Wheat, or Stone) you have.
Furthermore, it seems like this count is deducting from an
Empire-wide pool, just as Strategic resources add on to a globally-available pool. In other words, it didn't matter that I had 2 Sheep in separate cities, as long as
both were improved, I was able to construct the building which required/consumed 2 Sheep. This worked similarly with the Wine.
The Wine presented a slight presentational issue, as it would properly "deduct" two copies of Wine (this matched up with the inability to trade any Wine to another Civ once construction of the building was begun, while reclaiming the ability to trade 2 copies of Wine once construction was canceled) but if it included my very last copy of Wine, the Happiness counter did not update properly.
Specifically, it would deduct the +4 Happiness from no longer having a luxury resource, but it would
appear to add +4 Happiness to the "from difficulty" line.
However, this was
not actually calculated upon advancement into the next turn -- The Golden Age meter only gained however many points of Happiness you
would have gotten without the +4 from the now-missing Luxury.
Now, here's the next surprising part:
Bonus and Luxury resources also come from a global pool!
Going back to my test, I had 2 Cities and 2 Sheep. Once I began construction of the building which consumed 2 Sheep,
the game would not let me build another one in the other city! It demanded that I connect
two more Sheep before allowing me to build a second instance of the building.
The only inconsistency left, then, is that while Luxury and Strategic resources are forever "consumed" by the building, Bonus resources will continue to exist as a workable tile (just as Luxuries are after being traded.) However, they will still act as a "global limiter" on those buildings. As well, I have not yet tested what happens when you build a building requiring Bonus or Luxury resources, and then lose all your copies of them. I suspect nothing will happen, though, just that you won't be able to construct new buildings, and you probably won't take a Happiness penalty from "using more Wine than you have available."
This seems to have massive potential for allowing some very unorthodox things, including potentially something like
dummy resources?
I'm not sure, but I'm pretty excited, and with some tweaking and re-imagining, I think I can actually go ahead with my original plan of requiring
and consuming all types of resources with my HQ's.