• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.
@knuckey: I'm using this exact script in an event option while having a dead Duke Otto of Bavaria being the real father of Heinrich in the 1066 vanilla scenario and it seems to have the desired effect.
Code:
real_father_even_if_dead = {
    ROOT = { set_father = PREV }
}
So it seems like you manage to have a special scenario where it breaks or we messed something up with the patch.
 
@Divine
The change_infamy command added to the 2.5.2 beta doesn't appear to be working. I've added it to a custom CB for my personality trait rebalance mod, but the tooltip lists the change in Threat as 0.00, and actually declaring war doesn't add the threat either, so it isn't a tooltip issue.

Here's the relevant portion of my CB script:

Code:
    on_add = {
        ROOT = {
            add_character_modifier = {
                name = launched_arbitrary_subjugation
                days = 3285
                hidden = no
            }
            prestige = -250
            change_infamy = 20.0
        }
    }
...

Edit:
Initially, the script I used was "change_infamy = 20", and I changed it to 20.0 in the hopes that the decimal point would help.

Okay so I don't know how well this has been communicated. But the effect seems to be implemented with the current syntax:

Code:
change_infamy = {
    value = x
    localisation = y
}

Where x should be a number (can be a decimal values) and y should be the tag for a localisation entry. This is to give proper information in the interface for the threat-tooltip. Please spread this among other modders if it doesn't seem to be a well known syntax and they seem to struggle with it.
 
  • 1
Reactions:
Okay so I don't know how well this has been communicated. But the effect seems to be implemented with the current syntax:

Code:
change_infamy = {
    value = x
    localisation = y
}

Where x should be a number (can be a decimal values) and y should be the tag for a localisation entry. This is to give proper information in the interface for the threat-tooltip. Please spread this among other modders if it doesn't seem to be a well known syntax and they seem to struggle with it.
This appears to be the first time this has been communicated anywhere, actually. The command does not appear in any events or anything for us to have examples of how it works, the only places the command even appears in the steamapps\common\Crusader Kings II folder is in the exe, a pdb file, the changelog*, and this bit of localization:

Code:
CHANGE_INFAMY_EFFECT;$CHAR|Y$ Threat $VALUE|Y$ added.;Menace de $CHAR|Y$ gagne $VALUE|Y$.;$CHAR|Y$ Bedrohung $VALUE|Y$ hinzugefügt.;;$CHAR|Y$ añadido $VALUE|Y$ Amenaza.;;;;;;;;;x

* Relevant changelog line:
Code:
- Added change_infamy effect to add or remove threat from a character.

Anyway, I tested it out, and using the value syntax worked, but the tooltip for declaring the war is messed up. I think this might be because the change_infamy_effect localization is missing a line break at the end.

B4RqGMV.png


Thank you very much for clearing this up. (As a side note, could you ask whoever compiles the changelogs to include the syntax for new modding capabilities, to avoid us having to waste you time with this sort of thing?)

Edit:
I've added the info on change_infamy to the wiki.
 
Last edited:
This appears to be the first time this has been communicated anywhere, actually. The command does not appear in any events or anything for us to have examples of how it works, the only places the command even appears in the steamapps\common\Crusader Kings II folder is in the exe, a pdb file, the changelog*, and this bit of localization:

...

Thank you very much for clearing this up. (As a side note, could you ask whoever compiles the changelogs to include the syntax for new modding capabilities, to avoid us having to waste you time with this sort of thing?)

Edit:
I've added the info on change_infamy to the wiki.

Thanks for contributing to the wiki. I'll poke a bit on them to make sure they're a bit more clear in the changelog about syntax. =)
I'll also make sure to fix the localisation issue.
 
  • 1
Reactions:
Thanks for contributing to the wiki. I'll poke a bit on them to make sure they're a bit more clear in the changelog about syntax. =)
I'll also make sure to fix the localisation issue.
Thank you again. I'm particularly interested in the details for the revoke trigger for minor titles mentioned in the changelog. Would I be correct in assuming that it works like, and uses the same sort of syntax as dismiss_trigger in job_titles.txt? Also, does it work for commanders? I recall you mentioned that they work differently.
 
Thanks for contributing to the wiki. I'll poke a bit on them to make sure they're a bit more clear in the changelog about syntax. =)
I'll also make sure to fix the localisation issue.
Adding an alliance via commands also seems to not have a line break either.
eg: add_alliance = { who = ROOT years = 3 } gives the following tooltip
bch2WY1.png
 
@knuckey: I'm using this exact script in an event option while having a dead Duke Otto of Bavaria being the real father of Heinrich in the 1066 vanilla scenario and it seems to have the desired effect.
Code:
real_father_even_if_dead = {
    ROOT = { set_father = PREV }
}
So it seems like you manage to have a special scenario where it breaks or we messed something up with the patch.

My bad, I was using a slightly outdated version of the 2.5.2 beta which didn't have that change in it. It is working fine now.
 
Adding an alliance via commands also seems to not have a line break either.
eg: add_alliance = { who = ROOT years = 3 } gives the following tooltip
bch2WY1.png
Thanks for pointing that one out.
My bad, I was using a slightly outdated version of the 2.5.2 beta which didn't have that change in it. It is working fine now.
Whew, you made me a little worried there. Good to hear that it's supposedly working as intended then.
 
Just wanted to confirm that the new revoke_trigger for minor titles doesn't work for commanders. I added this bit of code to the title_commander block as a test, just before the gain_effect subblock:

Code:
    revoke_trigger = {
        FROM = {
            NOT = { religion_group = muslim }
        }
    }

I then started up the game, and was able to fire and change commanders as a Muslim.

Edit:
Here's the full script for the title:
Code:
# Commander, granted via its own interaction, so very special
title_commander = {
    is_high_prio = yes
   
    attribute = martial
    dignity = 0.05
    opinion_effect = 10
    realm_in_name = yes
   
    monthly_salary = 0.05
    monthly_prestige = 0.50
   
    allowed_to_hold = {
        OR = {
            primary_title = { temporary = no }
            NOT = {
                primary_title = {
                    always = yes
                }
            }
        }
        liege = { character = FROM }
        OR = {
            AND = {
                OR = {
                    is_female = no
                    AND = {
                        OR = {
                            religion = messalian
                            religion = cathar
                        }
                        liege = { religion = ROOT }
                    }
                    liege = {
                        primary_title = {
                            has_law = status_of_women_4
                        }
                    }
                }
                OR = {
                    NOT = { religion = hindu }
                    trait = kshatriya
                }
                is_adult = yes
            }
            has_character_flag = special_marshal
        }
       
        prisoner = no
        NOT = { trait = incapable }
        NOT = { trait = in_hiding }
        NOT = { has_character_flag = guru }
    }
   
    revoke_trigger = {
        FROM = {
            NOT = { religion_group = muslim }
        }
    }
   
    gain_effect = {
    }
    lose_effect = {
    }
   
    message = yes
}
 
Just wanted to confirm that the new revoke_trigger for minor titles doesn't work for commanders. I added this bit of code to the title_commander block as a test, just before the gain_effect subblock:

Code:
    revoke_trigger = {
        FROM = {
            NOT = { religion_group = muslim }
        }
    }

I then started up the game, and was able to fire and change commanders as a Muslim.

Edit:
Here's the full script for the title:
Code:
# Commander, granted via its own interaction, so very special
title_commander = {
    is_high_prio = yes
  
    attribute = martial
    dignity = 0.05
    opinion_effect = 10
    realm_in_name = yes
  
    monthly_salary = 0.05
    monthly_prestige = 0.50
  
    allowed_to_hold = {
        OR = {
            primary_title = { temporary = no }
            NOT = {
                primary_title = {
                    always = yes
                }
            }
        }
        liege = { character = FROM }
        OR = {
            AND = {
                OR = {
                    is_female = no
                    AND = {
                        OR = {
                            religion = messalian
                            religion = cathar
                        }
                        liege = { religion = ROOT }
                    }
                    liege = {
                        primary_title = {
                            has_law = status_of_women_4
                        }
                    }
                }
                OR = {
                    NOT = { religion = hindu }
                    trait = kshatriya
                }
                is_adult = yes
            }
            has_character_flag = special_marshal
        }
      
        prisoner = no
        NOT = { trait = incapable }
        NOT = { trait = in_hiding }
        NOT = { has_character_flag = guru }
    }
  
    revoke_trigger = {
        FROM = {
            NOT = { religion_group = muslim }
        }
    }
  
    gain_effect = {
    }
    lose_effect = {
    }
  
    message = yes
}
Unfortunately commanders have their own way of working things out.
 
  • 1
Reactions:
Unfortunately commanders have their own way of working things out.
Any chance of getting a way to lock them in anytime soon? I'm trying to put together a stratocracy type government, and being able to keep the AI from swapping commanders around would really help keep it from getting really messy.
 
Please either correct "targetted_decisions" to targeted, or add targeted as an alias. Having to intentionally make a typo is a pain in the backside, especially when you don't remember and can't figure out why your perfectly correct scripts aren't working. o_O
 
  • 5
Reactions:
Any chance of getting a way to lock them in anytime soon? I'm trying to put together a stratocracy type government, and being able to keep the AI from swapping commanders around would really help keep it from getting really messy.
I've added it to my ever-growing list of things I want to get done in the CK project. However any time soon is probably not the case. Unfortunately I don't think I'll get to it before a while.

Please either correct "targetted_decisions" to targeted, or add targeted as an alias. Having to intentionally make a typo is a pain in the backside, especially when you don't remember and can't figure out why your perfectly correct scripts aren't working. o_O
We like to tinker with employee's and modder's brains for our psychological studies on how much pain the human psyche can withstand.
In other words I've made a quick alias for it.
 
  • 5
  • 1Like
Reactions:
I've added it to my ever-growing list of things I want to get done in the CK project. However any time soon is probably not the case. Unfortunately I don't think I'll get to it before a while.


We like to tinker with employee's and modder's brains for our psychological studies on how much pain the human psyche can withstand.
In other words I've made a quick alias for it.

Thankya kindly :)
 
IS there any way to use the population mechanics from nomads in other government types? Similar to how Decadence can be determined in the government type?
 
IS there any way to use the population mechanics from nomads in other government types? Similar to how Decadence can be determined in the government type?

Not at the moment. Well, not unless you put your other governments in the nomad group, and them you also inherit all the other nomadic stuff
 
Is there / will there ever be a way to create a state stat modifier, that operates independently of personal stats? (Say I wanted an event to grant a modifier to State Diplomacy, for example, without increasing one's personal stats.)
 
@Divine does
Code:
has_earmarked_regiments
work as a limit inside the *_army scopes? If no, is it possible to scope to an army that only has event_troops in it? Alternatively, is it possible to only apply
Code:
disband_event_forces
at a location, so only disband the earmarked troops within that province?
 
We've encountered a problem in one of our scenarios/bookmarks. In this scenario the main character has a landless title, with no demesne, and is given scripted event troops to wage a war, in effect to try and simulate an adventurer. However the 2.5 patch seems to have introduced a bug where trying to merge the armies of this character causes a CTD, the apparent cause of this is having no demesne. Could this possibly be fixed?
 
We've encountered a problem in one of our scenarios/bookmarks. In this scenario the main character has a landless title, with no demesne, and is given scripted event troops to wage a war, in effect to try and simulate an adventurer. However the 2.5 patch seems to have introduced a bug where trying to merge the armies of this character causes a CTD, the apparent cause of this is having no demesne. Could this possibly be fixed?
I think that I managed to nail down this issue to being caused by a tooltip from the number in the unit selection (mouse-over on the number next to the go to location and deselect button crashed the game for characters with non-landed realms). This should be fixed but that won't reach you until a future patch.
 
  • 1
Reactions: