RevDCM - Alliances

Mattygerst

King
Joined
Jan 19, 2008
Messages
608
Location
St. Louis, Missouri, USA
Hey man...

Have really enjoyed the new RevDCM & BBAI releases...have been playing them a lot while continuing the work on my scenario-mod.

You told me to ask this question in a forum that you could answer because there would be a lot of people interested in seeing the answer & it could add a lot to warfare fun...

My question:

In RFC, Rhye created "non-breakable upon war declaration defensive pacts" - so that it would be like, for example, in case you aren't aware of this:

USA & UK have defensive pact
Russia & China have defensive pact.

USA declares war on Russia. Defensive pact with UK stays in tact. Bc of the declaration on Russia, China declares war on USA. Because of USA-UK pact, UK declares war on China. Because of Russia-China pact, Russia declares war on UK.

So in the end, the "alliance" stays in tact & the war now becomes USA&UK vs. Russia&China.

Now, myself, I have no idea how to code this. It is probably the #1 thing on my "wish list" for game-changing play & I'd fully appreciate the help you can offer me with this.

Thanks JDog
Matt
 
Hey man...

Have really enjoyed the new RevDCM & BBAI releases...have been playing them a lot while continuing the work on my scenario-mod.

You told me to ask this question in a forum that you could answer because there would be a lot of people interested in seeing the answer & it could add a lot to warfare fun...

My question:

In RFC, Rhye created "non-breakable upon war declaration defensive pacts" - so that it would be like, for example, in case you aren't aware of this:

USA & UK have defensive pact
Russia & China have defensive pact.

USA declares war on Russia. Defensive pact with UK stays in tact. Bc of the declaration on Russia, China declares war on USA. Because of USA-UK pact, UK declares war on China. Because of Russia-China pact, Russia declares war on UK.

So in the end, the "alliance" stays in tact & the war now becomes USA&UK vs. Russia&China.

Now, myself, I have no idea how to code this. It is probably the #1 thing on my "wish list" for game-changing play & I'd fully appreciate the help you can offer me with this.

Thanks JDog
Matt

This is an easy change to make actually, commenting out the following pieces in CvTeam::declareWar should do it:

1. A big block of loops and ifs which references TRADE_DEFENSIVE_PACT

2. The line with cancelDefensivePacts()

3. The line with GET_TEAM(eTeam).cancelDefensivePacts()

(Side note: 1 and 2 look entirely redundant to me, not sure why Firaxis has both) So, for the big block you could use a c++ block comment:

Code:
/*
... several lines of code ...
*/

and for single lines you can use:

Code:
//cancelDefensivePacts();

And after making these changes you will need to recompile the DLL. When generating the DLL, the compiler simply skips over commented out pieces as if they don't exist. Commenting out code is better than deleting it though because it leaves the code intact in case you decide to change your mind later.

I think I'll create an XML flag in future releases of BBAI and RevDCM so this simple change to make Defensive Pacts more like Alliances is easily available for everyone.
 
I think I'll create an XML flag in future releases of BBAI and RevDCM so this simple change to make Defensive Pacts more like Alliances is easily available for everyone.

As I said earlier, I'd rather you didn't. Defensive pacts are just that, defensive only.

However, I would not be against allow strategic non-permanent Alliances.

I've had a few thoughts on this:

Alliances would be the same as defensive pacts in all ways, except that they would not be canceled if one party went to war. However, the issue here is that Alliances usually made joint-declarations of war, so that one member could not drag friends into a potential conflict. This would be simple enough for the AI, just check that both have a certain attitude threshold towards the enemy player. However, with the human player, it becomes much more complicated. How does the AI signal to the human that it would like to start a mutual war? How does the human signal to the AI? If two humans are in an alliance, how do they signal for war? If there are more than two members in this alliance, how does that work?

Alliances get really complicated, really fast. It would be an interesting MOD idea, way above the mod component level.

Personally, I'd love to see what others think about this, and if they have ideas to resolve the myraid of problems. But ATM, I'd rather see Jdog fix MP for RevDCM.
 
As I said earlier, I'd rather you didn't. Defensive pacts are just that, defensive only.

However, I would not be against allow strategic non-permanent Alliances.

I've had a few thoughts on this:

Alliances would be the same as defensive pacts in all ways, except that they would not be canceled if one party went to war. However, the issue here is that Alliances usually made joint-declarations of war, so that one member could not drag friends into a potential conflict. This would be simple enough for the AI, just check that both have a certain attitude threshold towards the enemy player. However, with the human player, it becomes much more complicated. How does the AI signal to the human that it would like to start a mutual war? How does the human signal to the AI? If two humans are in an alliance, how do they signal for war? If there are more than two members in this alliance, how does that work?

Alliances get really complicated, really fast. It would be an interesting MOD idea, way above the mod component level.

Personally, I'd love to see what others think about this, and if they have ideas to resolve the myraid of problems. But ATM, I'd rather see Jdog fix MP for RevDCM.

Perhaps a UN/Apostolc Palace system? One leads the alliance (of however many Civs) and they can vote on wars and peace.
 
As the person who started this Afforess:

I've talked with JDog about this dating back to April...this is not something I want "implemented" as in - "in the game"...but simply something that is an "option" to click on/off. Nothing more, nothing less. I simply am not confident/experienced enough at modding to do this myself, and being that I ONLY play RevDCM/BBAI...I had no one else to ask but JDog. And if it is simply a feature that is easily turned on/off & JDog already knows where to do this...I figured it was fair game to ask him for some help (and I'm ALSO working on my own scenario-mod - that I've put as much time/effort into as I possibly can for being as inexperienced at modding as I am) for which the code will be implemented.

I am as much for getting any more improvements as any of you. I play this game, honestly, probably as much as anyone here - even if I'm not an experienced modder, etc. But yes, like BobTheTerrible said...I'm simply looking for something that implements this into a way to basically give me an easier way to implement this into RevDCM as my own choice.
 
Since the code is done, and a custom game option button is easy to implement I say go for it. I'll be disabling the option in LoR myself because I think there are already too many game options, and things are cluttered as is in the custom game start up; but that's easy enough to do in the XML. Agree with Afforess that the optimal thing would be to create a new alliance diplo function and just make that part of RevDCM, but the AI will need to be programmed to decide when an alliance is preffered over a DP, and vice versa, and making it a whole new diplo option in it's own right would be more work. As Afforess says, there are other priorities now. But yeah, my vote is for the ultimate goal being a new diplo option "Ally", but just going for a gameoption that changes how DP works for the time being.
 
Perhaps a UN/Apostolc Palace system? One leads the alliance (of however many Civs) and they can vote on wars and peace.

That would be the optimal decision, but I have never really looked at how the UN/Apostolic palace works.

As the person who started this Afforess:

I've talked with JDog about this dating back to April...this is not something I want "implemented" as in - "in the game"...but simply something that is an "option" to click on/off. Nothing more, nothing less. I simply am not confident/experienced enough at modding to do this myself, and being that I ONLY play RevDCM/BBAI...I had no one else to ask but JDog. And if it is simply a feature that is easily turned on/off & JDog already knows where to do this...I figured it was fair game to ask him for some help (and I'm ALSO working on my own scenario-mod - that I've put as much time/effort into as I possibly can for being as inexperienced at modding as I am) for which the code will be implemented.

I am as much for getting any more improvements as any of you. I play this game, honestly, probably as much as anyone here - even if I'm not an experienced modder, etc. But yes, like BobTheTerrible said...I'm simply looking for something that implements this into a way to basically give me an easier way to implement this into RevDCM as my own choice.

IMO, changing the way defensive pacts work is sub-optimal. I'd rather Jdog left them alone. I'm with Phungus here, if he does add it as on option, I'm just going to hide it and disable it. No thank you.
 
I'd like to see alliances. even if they last 20 turns.

Make them a "permanent alliance" that end at 20 turns.
 
Back
Top Bottom