Results 1 to 9 of 9

Thread: Bad Discipline (and temporary fix)

Threaded View

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

    Default Re: Bad Discipline (and temporary fix)

    Quote Originally Posted by mmiki View Post
    I've posted about this in the main mod forum, but I thought I'd post here as well. The problem is that PercentageRoutedOffField in triggers doesn't seem to be working properly - it seems to be counting the routed enemy forces as well. My generals ended up with worse and worse discipline traits as game went on through no fault of their own, so I decided to make a fix of some kind rather than keep fixing it through console.

    This is a quick and dirty fix, until it's officially handled in some way. After a battle discipline has a 3 percent chance to be affected in a random way. I would rather have it depend on the personality of the general - stern, stoic types tending to go heavy on the discipline and easy-going, hedonistic types tending to be lax about it, with some amount of randomness. However, I'm not familiar enough with the EB2 traits system yet, and export_descr_character_traits is a big file, so I'm using this for now.

    Anyway, backup export_descr_character_traits.txt, open the file with some kind of text editor and replace the Army discipline section with this:


    Code:
    ;--------------------------------------------------------------------------------------------------------------------
    ;------------------------------------------
    ; Army discipline
    ;------------------------------------------
    Trigger SomewhatGoodDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and Trait BadDisciplinarian < 1
    
      Affects Disciplinarian  1  Chance  3
    
    ;------------------------------------------
    Trigger SomewhatGoodDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and Trait BadDisciplinarian > 0
    
      Affects BadDisciplinarian -1  Chance  3
    
    ;------------------------------------------
    
    Trigger SomewhatBadDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral 
            and WonBattle
            and BattleOdds > 0.7
            and Trait Disciplinarian > 1
    
      Affects Disciplinarian -1  Chance  3
      
    ;------------------------------------------
    Trigger SomewhatBadDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and WonBattle
            and BattleOdds > 0.7
            and Trait Disciplinarian < 1
    
      Affects BadDisciplinarian  1  Chance  3
      
    ;------------------------------------------
    Trigger Disciplinarian_Selfperpetuating
      WhenToTest CharacterTurnEnd
    
      Condition IsGeneral
            and Trait Disciplinarian > 1
    
      Affects Disciplinarian  1  Chance  2
    ;------------------------------------------
    Trigger BadDisciplinarian_Selfperpetuating
      WhenToTest CharacterTurnEnd
    
      Condition IsGeneral
            and Trait BadDisciplinarian > 1
    
      Affects BadDisciplinarian  1  Chance  2
    ;------------------------------------------
    You fix is functional, but it makes changes in Disciplinarian and BadDisciplinarian very rare.

    I suggest doing a test, replacing the buggy PercentageRoutedOffField with something of the variety:

    Code:
    ;------------------------------------------
    Trigger SomewhatGoodDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and PercentageEnemyKilled > 12    ;the PercentageOfArmyKilled * BattleOdds 
            and PercentageOfArmyKilled < 10
            and Trait BadDisciplinarian > 0
    
      Affects BadDisciplinarian -1  Chance  20
    
    ;------------------------------------------

    Specifically, here is the section redone, with comments illustrating how I generated the numbers. I'll put this in my game see how it goes:

    Code:
    ;------------------------------------------
    ; Army discipline
    ;------------------------------------------
    Trigger SomewhatGoodDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and PercentageEnemyKilled > 50
            and PercentageOfArmyKilled < 40
            and Trait BadDisciplinarian < 1
    
      Affects Disciplinarian  1  Chance  10
    
    ;------------------------------------------
    Trigger SomewhatGoodDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and PercentageEnemyKilled > 50
            and PercentageOfArmyKilled < 40
            and Trait BadDisciplinarian > 0
    
      Affects BadDisciplinarian -1  Chance  10
    
    ;------------------------------------------
    Trigger VeryGoodDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and PercentageEnemyKilled > 60
            and PercentageOfArmyKilled < 30
            and Trait BadDisciplinarian < 1
    
      Affects Disciplinarian  1  Chance  20
    
    ;------------------------------------------
    Trigger VeryGoodDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and BattleOdds < 1.2
            and PercentageEnemyKilled > 60
            and PercentageOfArmyKilled < 30
            and Trait BadDisciplinarian > 0
    
      Affects BadDisciplinarian -1  Chance  20
    
    ;------------------------------------------
    Trigger SomewhatBadDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and WonBattle
            and BattleOdds > 0.7
            and PercentageEnemyKilled < 40
            and PercentageOfArmyKilled > 60
            and Trait Disciplinarian > 1
    
      Affects Disciplinarian -1  Chance  30
      Affects Disciplinarian -1  Chance  30
    
    ;------------------------------------------
    Trigger SomewhatBadDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and WonBattle
            and BattleOdds > 0.7
            and PercentageEnemyKilled < 40
            and PercentageOfArmyKilled > 60
            and Trait Disciplinarian < 1
    
      Affects BadDisciplinarian  1  Chance  30
      Affects BadDisciplinarian  1  Chance  30
    
    ;------------------------------------------
    Trigger VeryBadDiscipline_Disciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and WonBattle
            and BattleOdds > 0.7
            and PercentageEnemyKilled < 35
            and PercentageOfArmyKilled > 70
            and Trait Disciplinarian > 1
    
      Affects Disciplinarian -1  Chance  50
      Affects Disciplinarian -1  Chance  50
    
    ;------------------------------------------
    Trigger VeryBadDiscipline_Undisciplined
      WhenToTest PostBattle
    
      Condition IsGeneral
            and WonBattle
            and BattleOdds > 0.7
            and PercentageEnemyKilled < 35
            and PercentageOfArmyKilled > 70
            and Trait Disciplinarian < 1
    
      Affects BadDisciplinarian  1  Chance  50
      Affects BadDisciplinarian  1  Chance  50
    
    ;------------------------------------------
    Trigger Disciplinarian_Selfperpetuating
      WhenToTest CharacterTurnEnd
    
      Condition IsGeneral
            and Trait Disciplinarian > 1
    
      Affects Disciplinarian  1  Chance  2
    ;------------------------------------------
    Trigger BadDisciplinarian_Selfperpetuating
      WhenToTest CharacterTurnEnd
    
      Condition IsGeneral
            and Trait BadDisciplinarian > 1
    
      Affects BadDisciplinarian  1  Chance  2
    Last edited by Twigvest; 09-16-2014 at 11:28. Reason: Chaging percentages so they are more possible to occur ingame
    Vlad is your Impaler.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO