Overuse of Nukes

Since the global warming mechanics target land indiscriminately I don't see any real point in the AI being worried about it, especially in deciding whether or not to use a nuke.

Not really true. It may target indiscriminately, but the affects aren't necessarily felt indiscriminately. The larger a player's (or AI's) empire is, the more tiles they will have altered by global warming. So small nations should worry less, and larger nations should care more.
 
Why do they have to use them? In the real world only two real nukes have been dropped and those are almost nothing compared to what we have today. We do have a partially working SDI system but it has less than 50% chance of stopping enemy nukes.
Again I ask why must the AI use nuclear weapons they could just use convential armies insead of doing the unthinkable and starting a nuclear war.
 
Not really true. It may target indiscriminately, but the affects aren't necessarily felt indiscriminately. The larger a player's (or AI's) empire is, the more tiles they will have altered by global warming. So small nations should worry less, and larger nations should care more.

No, I don't agree.

You're making unstated assumptions. You are assuming just because a player loses more useful tiles he is affected more by the global warming. In fact, if you consider the proportionate effect then it's equally damaging to all empires, small or large. Actually, the larger the empire, the lower the risk that a few tiles lost will have a big impact, so it wouldn't be hard to argue that smaller empires have to worry about it more. But my position is still that it affects everyone equally so there is little point in worrying about it.

I thought this was very simple.

By the way, if you really wanted to figure out who would be affected more you would want to look at which empires depend on their tiles the most (as opposed to per city bonuses like corps and EP buildings etc.) and take into account which tiles are susceptible to global warming mechanics. For example, an empire that is getting a lot of income from coast tiles needn't worry about being affected much.

Anyway, really global warming needn't be worried about at all, except possibly for pure roleplay purposes or mod-specific circumstances.
 
Again I ask why must the AI use nuclear weapons they could just use convential armies insead of doing the unthinkable and starting a nuclear war.

'Cuz it works.
 
My point was its not realistic. I might be asking in the wrong place but I do know the AI doesn't use nuclear weapons correctly. As people have already stated they don't take diplomacy/politics, or global warming into consideration. If they took these into consideration I would've asked in a different forum, but I asked here because there are problems other than them being non-realistic.
 
My point was its not realistic. I might be asking in the wrong place but I do know the AI doesn't use nuclear weapons correctly. As people have already stated they don't take diplomacy/politics, or global warming into consideration. If they took these into consideration I would've asked in a different forum, but I asked here because there are problems other than them being non-realistic.

I agree and disagree with you.

I agree the AI should take nukes ramifications into account before launching.

I disagree that the AI need to be realistic. Realism is not the goal of Better AI.
 
What I was trying to say was that I asked here because there were more problems than it just being unrealistic. The other problems our the ones I wanted you to see and understand. Sorry if I had misphrased that.
 
If a city with nukes in it is itself nuked, do the nukes take damage and/or die?

It appears that, according to the UnitInfos xml, ICBMs are nuke immune but tactical nukes are not. I would assume tactical nukes have the same probability of being destroyed by a nuclear explosion (including meltdowns) as any other non-combat unit, but I am just guessing.
 
First of all, nukes should not, *ever* be tied to global warming, as it is illogical from both a gameplay and realism standpoint (kind of like GW in general).

Second, there are only two aspects of the use of nukes that better AI really needs to consider using basic BTS rules: :hammers::kill efficiency and diplo ramifications.

However, AFAIK the AI does not actively consider diplo ramifications of any action it does, it just makes decisions based on XML values and coding. I know betterAI has worked on war maneuvers and evaluation of the best unit to train already, and I see no reason nukes should get special consideration from that angle...just the diplo angle. But how does one get the AI to consider diplo against itself? That would be a loopy AI...maybe if each civ had some sort of long-standing dynamic learning system on a per-game basis. That's...a little outside the realm of a mod for this particular game though isn't it?

Using nukes it has is an optimal strategy for the AI, assuming the human lets them secure a meaningful quantity. Nukes can effectively destroy VERY huge stacks for the cheapest cost possible.

My biggest issue with them (and favorite too, if that makes sense) is that the AI is perfectly willing to accept and launch gifted nukes against those at war with it. Currently, the game has nothing against civs that supply units to other civs via gifting...but only the human will do it. Gifting TACTICAL NUKES, however, can completely stalemate any war no matter what. No matter how large shaka's stack was, it's gone now. Even if shaka has 40% of the world's land, he'll never beat that guy with 10% because he'll never get enough war success to cap him (and his power just got murdered, maybe he's even losing cities), all while the human player techs happily away with 1 city set to spam tac nukes.

But should better AI refuse units gifts in this fashion? Technically speaking, the civ accepting the weapons IS being helped. A lot. It does minimally increase its chance of winning, even if by a small amount (certainly better than losing 5 cities and capping for the target). From that standpoint, it's hard to argue that the AI should refuse nukes...I think that is why no BTS patch has ever touched the ability to gift them even though they can break a bleak-looking game wide open with this tactic.
 
So should gifting a nuke give a "-1 You have given nuclear weapons to our worst enemies" with people at war with the receiving civ?
 
So should gifting a nuke give a "-1 You have given nuclear weapons to our worst enemies" with people at war with the receiving civ?

Only if gifting of any units counts towards a negative value.

Arms supply has escalated many a war, in fact more often over conventional than nuclear weaponry.

It would be better for gameplay, too, because this is a hole in the AI's play for certain and open to abuses.

However, IMO this is not a valid correction for betterAI to implement. BetterAI does not generally seek to CHANGE GAME RULES, but rather allow the AI to operate better within them. Implementing a diplo penalty for gifting is a direct nerf on certain types of units, and balancing unit strengths does not seem to be in the scope of betterAI.
 
I'd disagree. Adding in diplo penalties for aiding someone you are an enemy of during a war does seem like the domain of BetterAI.

Heck, gifting troops to a 3rd party that is disliked should cause diplomatic penalties in general, sort of like the trade penalties.

If units keep track of who made them (do they?), then we could even have diplomatic penalties for your nuke being used, even if someone else used it!
 
"-1 You have supplied arms to our worst enemies" then, based on hammer value? Or you could roll it into the "-1 you have traded with our worst enemies" check.

However, IMO this is not a valid correction for betterAI to implement. BetterAI does not generally seek to CHANGE GAME RULES, but rather allow the AI to operate better within them.

I regard the diplomacy penalties and bonuses as part of the AI, rather than part of the game rules. If human players fail to get furious with AIs of differing religions, they aren't breaking the game rules.
 
Looking at the code for gifting units, it seems that it already triggers "you have traded with our worst enemies" modifiers, but it values the units too low.

Inside cvUnit::gift, there's the following line:

Code:
GET_PLAYER(pGiftUnit->getOwnerINLINE()).AI_changePeacetimeGrantValue(eOwner, (pGiftUnit->getUnitInfo().getProductionCost() / 5));

This values each hammer of production cost at a flat rate of 0.2 gold. I suggest changing this to something like this:

Code:
// one hammer is worth around two gold
int iValue = pGiftUnit->getUnitInfo().getProductionCost() * 2;

if( pGiftUnit->hasUpgrade(true) ) {
    // obsolete units are worth a fraction of their full hammer cost
    iValue = iValue / 10;
} else if( pGiftUnit->AI_getUnitAIType() = UNITAI_MISSIONARY) {
    // Gifting missionaries and executives is fine, but we'd prefer tanks
    iValue = iValue / 10
}

GET_PLAYER(pGiftUnit->getOwnerINLINE()).AI_changePeacetimeGrantValue(eOwner, iValue);
 
Hmmm ... yeah, hammers / 5 is quite low. The AI actually values gold trades at 2 or 3 * the amount of gold traded, so with that perspective it's ridiculous!

Perhaps something like 2*hammers*(combat value) for military units, this will pretty well handle gifting of obsolete units versus cutting-edge units.
 
Perhaps something like 2*hammers*(combat value) for military units, this will pretty well handle gifting of obsolete units versus cutting-edge units.

Since the hammer costs of units and combat value of units are strongly related, this is in essence a formula that is quadratic in relation to the hammer cost of the gifted unit. That makes each hammer invested in a modern armor 20 times as valuable as a hammer invested in a warrior for gifting purposes and of course the modern armor requires far more hammers. It makes gifting units late game extremely valuable for diplomacy.

A factor of (combat value gifted unit / combat value strongestt available unit) maybe even squared would help reduce the diplomatic value of gifting obsolete units.

So the diplomatic value could for instance be something like
6 * hammer value gifted unit * ((combat value gifted unit / combat value strongestt available unit)^2)
 
Sorry, when I wrote "combat value" what I meant was the percentage returned by CvGameAI::AI_combatValue, not the raw unit combat strength ... it was clear in my head, but how anyone else could have understood I'm not sure. Anyway, it does basically what you're suggesting, dividing combat value by the strongest available unit.
 
I'd be careful about weighting advanced units markedly more than obsolete ones, because the AI enjoys such an easy upgrade bonus that even crappy troops can turn into rifles or better awfully quickly.
 
Sorry, when I wrote "combat value" what I meant was the percentage returned by CvGameAI::AI_combatValue, not the raw unit combat strength ... it was clear in my head, but how anyone else could have understood I'm not sure. Anyway, it does basically what you're suggesting, dividing combat value by the strongest available unit.

Ah, clear.

Hammers are valued a bit higher than gold, but the AI cannot choose how to use those hammers anymore so maybe you're right that a similar value as the gold value is fair.

I agree with your combat value adjustment.
 
Back
Top Bottom