Results 1 to 5 of 5

Thread: capturing city/province scripting)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Barca Payne's Avatar Tiro
    Join Date
    May 2005
    Location
    england, machester
    Posts
    285

    Default capturing city/province scripting)

    hi

    is it possible to script losing a city/province how I mean is like when hannibal when into italy, capua and other citys left them and sided with hannibal so I though it might be possible to do it but use a form of chance system to do it like enemy army gets beat city in that province has 0.2 chance of coming over to you're side and adding more chance occurrence like that

    I've been wondering about this for a while posted it in a few places with no response and even had a go at it myself has it ever try to be done?

    any response would be appreciated

  2. #2

    Default Re: capturing city/province scripting)

    Moved to text Editing and Scripting.

  3. #3
    HouseOfHam's Avatar Primicerius
    Join Date
    Apr 2007
    Location
    Minnesota, USA
    Posts
    3,030

    Default Re: capturing city/province scripting)

    It's possible, but "console_command control" has some nasty side effects, which make it impractical to use.

    Code:
    declare_counter factionIndex
    
    monitor_event FactionTurnStart FactionIsLocal
              and I_TurnNumber = 666
    
        ; do this for all playable factions
        if FactionType = romans
            set_counter factionIndex 1
        end_if
        
        ; etc.
        
        if FactionType = blah
            set_counter factionIndex 20
        end_if
        
        
        console_command control carthage
        console_command capture_settlement SettlementName
    
        ; Restore control to the original faction
        ; do this for all playable factions
        if I_CompareCounter factionIndex = 1
            console_command control romans
        end_if
        
        ; etc.
        
        if I_CompareCounter factionIndex = 20
            console_command control blah
        end_if
        
        terminate_monitor    
    end_monitor
    RTR website/SVN admin

    - Settlement coordinate locator -for RTW/M2TW
    - EDB Validator v1.2.8 (Oct 16, 2012) - for RTW/M2TW
    - RTW scripting tutorials
    - n-turns per year script generator

  4. #4
    Barca Payne's Avatar Tiro
    Join Date
    May 2005
    Location
    england, machester
    Posts
    285

    Default Re: capturing city/province scripting)

    cool but what are the side effects and have you try getting around them?

  5. #5
    HouseOfHam's Avatar Primicerius
    Join Date
    Apr 2007
    Location
    Minnesota, USA
    Posts
    3,030

    Default Re: capturing city/province scripting)

    1. The AI does not properly control player's old faction
    2. All player settlements revert to auto-managed

    JeromeGrasdyke (CA lead dev) posted a warning about using this command on .org some years ago.
    RTR website/SVN admin

    - Settlement coordinate locator -for RTW/M2TW
    - EDB Validator v1.2.8 (Oct 16, 2012) - for RTW/M2TW
    - RTW scripting tutorials
    - n-turns per year script generator

Posting Permissions

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