1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Capitulation

Discussion in 'Civ4 - Mod Components' started by Afforess, Aug 4, 2009.

  1. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    This ModComp is no longer officially supported by me. Anyone who wants it should use it, as the feature is available in several excellent mods, such as Better BUG AI, and Better BTS AI.

    For those interested, the old page is here:
    Spoiler :

    This modcomp allows humans to capitulate or become vassals of the AI. It may not be the most useful tool immediately, but in a losing war, it is a way to save face...and cities.

    If you don't fully understand vassalage as it is in Warlords, please read this article.

    Almost any combination of Masters and Vassals are possible, except for loops. The game will not let you be a Master of Lincoln, Lincoln your vassal and Master of Louis XIV, and Louis XIV the Vassal of Lincoln and the Master of you. The game breaks this up by setting Lincoln free.

    Made for BTS 3.19. This modcomp is meant for merging only.

    There is no download for this modcomp, as it would just be one file, and even that file would only have one line changed. Why bother?

    If you want to add this to your SDK follow these instructions:
    Spoiler :

    Open "CvPlayer.cpp" and Search for (Control - F) this line:

    Code:
    if (!isHuman() || GET_PLAYER(eWhoTo).isHuman()) [COLOR=SeaGreen]//  human can't be vassal of AI[/COLOR]
            {
                CvTeam& kVassalTeam = GET_TEAM(getTeam());
                CvTeam& kMasterTeam = GET_TEAM(GET_PLAYER(eWhoTo).getTeam());
                if (kMasterTeam.isVassalStateTrading()) [COLOR=SeaGreen]// the master must possess the tech[/COLOR]
                {
                    if (!kVassalTeam.isAVassal() && !kMasterTeam.isAVassal() && getTeam() != GET_PLAYER(eWhoTo).getTeam())
                    {
    and change it to:

    Code:
    /*************************************************************************************************/
    /** Afforess  Realistic Diplomacy             08/12/09                                              */
    /**                                                                                              */
    /**                                                                                              */
    /*************************************************************************************************/
    [COLOR=SeaGreen]        //if (!isHuman() || GET_PLAYER(eWhoTo).isHuman()) //  human can't be vassal of AI        (OLD CODE)[/COLOR]
            if (getTeam() != GET_PLAYER(eWhoTo).getTeam()) [COLOR=SeaGreen]//Human can be vassal of AI[/COLOR]
    
            {
                CvTeam& kVassalTeam = GET_TEAM(getTeam());
                CvTeam& kMasterTeam = GET_TEAM(GET_PLAYER(eWhoTo).getTeam());
                if (kMasterTeam.isVassalStateTrading())[COLOR=SeaGreen] // the master must possess the tech[/COLOR]
                {
    [COLOR=SeaGreen] [COLOR=black]               if(!kVassalTeam.isAVassal() && [/COLOR]/*!kMasterTeam.isAVassal() && */[COLOR=black]getTeam() != GET_PLAYER(eWhoTo).getTeam())[/COLOR]  //vassal may not be a master (OLD CODE)[/COLOR]
                    {
    /*************************************************************************************************/
    /** Afforess  Realistic Diplomacy                         END                                      */
    /*************************************************************************************************/
    I left part of the original code intact, because otherwise, vassals could have multiple masters. If you want vassals to be able to have multiple masters, changes this line:

    Code:
    [COLOR=SeaGreen] [COLOR=black]               if(!kVassalTeam.isAVassal() && [/COLOR]/*!kMasterTeam.isAVassal() && */[COLOR=black]getTeam() != GET_PLAYER(eWhoTo).getTeam())[/COLOR]  //vassal may not be a master (OLD CODE)[/COLOR]
    
    to this one:
    Code:
    [COLOR=SeaGreen]// [COLOR=black]   [COLOR=SeaGreen]            if(!kVassalTeam.isAVassal() && [/COLOR][/COLOR]!kMasterTeam.isAVassal() && [COLOR=SeaGreen]getTeam() != GET_PLAYER(eWhoTo).getTeam())[/COLOR]  //vassal may not be a master (OLD CODE)[/COLOR]
    




    Understanding the new vassalage system:
    1. If my vassal has his/her own vassal, do they count as my vassal as well?
      • Indirectly. You can't make demands like you can with your own vassals, but if you enter a war, they will join it with you.
    2. If my vassal has his/her own vassal, do they count for my total score?
      • Yes, but not as much as a regular vassal does. Your own vassals add 50% of their score to yours. This means indirect vassals would add 25% of their score to their master, and 25% to their master's Master.
    If you have other questions, please post them, and I will respond to the best of my ability.

    Screenshots:
    Civ4ScreenShot0028.JPG
    Civ4ScreenShot0029.JPG
    Civ4ScreenShot0030.JPG

    Have fun, and enjoy.
     
  2. Cybah

    Cybah Emperor

    Joined:
    Jun 22, 2007
    Messages:
    1,480
    Great, what about a game option for it? Is anyone able to do?
     
  3. The_J

    The_J Say No 2 Net Validations Retired Moderator Supporter

    Joined:
    Oct 22, 2008
    Messages:
    31,906
    Location:
    DE/NL/FR
    I don't think, that it makes much sense, but besides that: Nice idea :goodjob:.
     
  4. keldath

    keldath LivE LonG AnD PrOsPeR

    Joined:
    Dec 20, 2005
    Messages:
    6,625
    Location:
    israel
    yeah i agree, great idea here.
     
  5. Yared

    Yared That Guy

    Joined:
    May 21, 2009
    Messages:
    4,516
    Location:
    Hufvudstaden
    Just what kind of power does the AI have over their vassals?
     
  6. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    A game option? I don't think you really need one. If you don't want to capitulate, don't. It's completely in the players control.

    I realize that in most games this probably doesn't make much sense (at least if you're winning), but it is interesting for games with the max difficulty.
     
  7. Cybah

    Cybah Emperor

    Joined:
    Jun 22, 2007
    Messages:
    1,480
    well we need a game option for multiplayer games.
     
  8. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    I'm not sure how that changes anything. Humans can already become vassals of other Humans, without this modcomp. Plus, making a gameoption is complicated and would require a lot of work.
     
  9. Cybah

    Cybah Emperor

    Joined:
    Jun 22, 2007
    Messages:
    1,480
    well, there are also mp games with AI AND human players. ;)
     
  10. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    I think your fears are unfounded. The AI rarely are powerful enough to be a significant enough threat to warrant vassalage. I made this out of a desire for realism in Civ4 and fairness on the part of the AI.
     
  11. Arian

    Arian No more ghostbusting!!

    Joined:
    May 10, 2008
    Messages:
    2,088
    Location:
    The Netherlands
    Defenitely a modcomp for losers! :lol:
     
  12. GeoModder

    GeoModder Deity

    Joined:
    Nov 29, 2005
    Messages:
    7,512
    Not really. It gives a military weak player the chance to grow stronger while under the protection of a dominant AI.
    Once your civ is strong/large enough, you can always break free. :D
     
  13. TheLadiesOgre

    TheLadiesOgre Aspiring Codesmith

    Joined:
    Jan 16, 2009
    Messages:
    505
    Another option is to hide under the wing of a militarily dominant AI and go for a cultural victory. I build a minimal military and focus on culture while my master depletes himself marching across the world
     
  14. Cybah

    Cybah Emperor

    Joined:
    Jun 22, 2007
    Messages:
    1,480
    how can I cancel the vassalage without declaring war?
     
  15. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    If you offered to be a vassal, you should be able to break it the same way you break open borders agreements. If you capitulated in a war, you have to become almost as strong as your master before you are released.
     
  16. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    Updated, with a new feature, complex vassalage.
     
  17. phungus420

    phungus420 Deity

    Joined:
    Mar 1, 2003
    Messages:
    6,296
    How does the AI handle offered vassalage? Will it accept you as a vassal even if it hates you, ie can you get out of war you know you don't want to fight by offering yourself as a vassal to an AI you know is gunning for you (not capitulation, I mean if there is no war, but you just rejected demands and you see a SoD coming your way)?
     
  18. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    The AI will always accept vassalage if you offer it to them, unless you are in a war that they don't want to get involved in. [I experienced a similar scenario to what you described, Mansu Musa had -8 relations with me, but he still accepted me as a vassal.] They (correctly, I might add) see vassalage as a form of surrender. Don't think you'll get out of war easy, just because you're the AI's vassal. I've noticed they like demanding tribute often from the human. If you refuse, it's war.

    Vassalage in the face off a SoD might not be the best option though. If it is an aggressive AI, they'll just use the army that was for you for someone else, and you have to help them. Or else.
     
  19. phungus420

    phungus420 Deity

    Joined:
    Mar 1, 2003
    Messages:
    6,296
    Thanks of the response. Bummer though, I was thinking about using this in LoR, but I think the automatic acceptance of Vassalage is the reason Firaxis decided to remove the option for humans in the first place, just seems too exploitable.

    How hard do you think it would be to add in a Pleased check, so that the AI would only accept voluntary vassals it was pleased with?
     
  20. Afforess

    Afforess The White Wizard

    Joined:
    Jul 31, 2007
    Messages:
    12,239
    Location:
    Austin, Texas
    No Idea. I'll look into it though. I'm also trying to see I can allow the master to release the vassal voluntarily.
     

Share This Page