Results 1 to 5 of 5

Thread: Changing Ownership/Allegiance by Script

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Changing Ownership/Allegiance by Script

    Hi,

    I am trying to figure out some less painful and less buggy way to change the ownership of a settlement or allegiance of a character by script. I need this because of strat map models. Consider Anatolia which is in Turkish hands at the start but should still look Roman. One option which works for forts (not sure if for settlements) is to give it to faction which look I prefer and then at the start of the game kill the garrison and spawn and move the proper owner inside. However this approach is often quite problematic and unreliable. Also for many places it takes significant amount of time to process as the armies actually have to move one by one.

    I am therefore wondering if there is any easier way to change ownership/allegiance by script?

    capture_settlement console command is supposedly only for player but perhaps it can be used between AIs too? It would solve the problem for the settlements.

    Then there is control which switches the Local faction. Maybe combination of the two could do the trick? Still there is an outstanding issue of how to change ownership of forts - they are of the region owners appearance and ownership when without garrison at start OR of the actual owner's appearance and ownership when garrisoned at start.


    Thank you in advance for any advice on this!
    Last edited by Resurrection; January 01, 2012 at 03:52 AM.

    Mod Leader, Mapper & Bohemian Researcher

  2. #2

    Default Re: Changing Ownership/Allegiance by Script

    For settlements it's fairly easy. In the descr_strat there is a faction_creator entry for every settlement:
    Code:
    year_founded 0
        population 3800
        plan_set default_set
        faction_creator england
    This determines how the settlement looks in the beginning. It will look as if it belonged to the faction you write into this line.

    For forts I don't know a similarly easy way.

  3. #3

    Default Re: Changing Ownership/Allegiance by Script

    Unfortunalty, there is no way, besides of using command maintain or attack, to change the owner of the settlement.

  4. #4

    Default Re: Changing Ownership/Allegiance by Script

    Thx vercassivelaunos. I have tried that long time ago and I thought it didn't work but it probably did.

    2attyla: Hm, since there is a way to set up a siege in descr_strat.txt and influence it in CS I think this could be the way to go!

    Mod Leader, Mapper & Bohemian Researcher

  5. #5

    Default Re: Changing Ownership/Allegiance by Script

    Quote Originally Posted by Resurrection View Post
    Thx vercassivelaunos. I have tried that long time ago and I thought it didn't work but it probably did.
    It works correctly both in RTW and M2TW. faction_creator is responsible for the .cas model of the settlement, dependent on the culture it has.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •