• 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.

slothinator

Colonel
55 Badges
Oct 20, 2016
955
833
  • Stellaris: Humanoids Species Pack
  • Stellaris
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Third Rome
  • Stellaris: Synthetic Dawn
  • Europa Universalis IV: Cradle of Civilization
  • Crusader Kings II: Jade Dragon
  • Europa Universalis IV: Mare Nostrum
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Europa Universalis IV: Golden Century
  • Imperator: Rome
  • Imperator: Rome Sign Up
  • Stellaris: Ancient Relics
  • Stellaris: Federations
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II
  • Europa Universalis IV: Res Publica
  • Victoria 3 Sign Up
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Cossacks
Question about event modding

I would like to know how I can avoid character's portraits from appearing in event options. I found how to avoid that in the event itself but not in the option
 

Rags17

Ludere Ludum
62 Badges
Dec 11, 2014
5.953
3.631
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II
  • Europa Universalis IV: Rights of Man
  • Cities: Skylines - Mass Transit
  • Steel Division: Normandy 44
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Monks and Mystics
  • Hearts of Iron IV: Together for Victory
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Surviving Mars
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Mandate of Heaven
  • Crusader Kings II: Holy Fury
  • Crusader Kings Complete
  • Stellaris: Distant Stars
  • Europa Universalis IV: Cossacks
  • Hearts of Iron IV: Death or Dishonor
  • Europa Universalis IV: Cradle of Civilization
  • Battle for Bosporus
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Europa Universalis IV: Rule Britannia
  • Imperator: Rome Sign Up
  • Crusader Kings III
  • Stellaris: Megacorp
  • Cities: Skylines Industries
  • Europa Universalis IV: Dharma
  • Victoria 2
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: Expansion Pass
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Conclave
  • Hearts of Iron IV: La Resistance
  • Stellaris
  • Europa Universalis IV: Pre-order
  • Europa Universalis IV: Call to arms event
  • Stellaris: Synthetic Dawn
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
Okay, what the hell am I doing wrong this time ?

The following scripts come down to two main streams called by two settlement_decisions - go_hunting and go_scavenging. These decisions have various outcomes depending upon caller stats, time of year and various other factors. Four outcomes for go_hunting (very good, okay, bad and warrior wounded), three for go_scavenging (very good, okay and bad) with the best outcome also having a chance of spitting out a trophy/artifact.

After days of futzing around I fixed the most obvious errors but I am still getting no pop ups for any outcome except the best result for go_hunting. The Validator says that there are no issues, I have reorganized and re-placed most of the immediate blocks into the option blocks but still no luck. And yes, the decisions all seem to be well formed and WAI.

Anyone ?

Code:
# Hunting outcomes
# Scavenging outcomes

namespace = dawn


character_event = { # Hunting - Capture big game
    id = dawn.510
    desc = EVTDESCdawn.510
    picture = GFX_evt_tribal_warriors #Something about hunting---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.510
        prestige = 25
    }
   
    after = {
        random_list = { #Chance to hunt out the area
            50 = {
                modifier = {
                    factor = 2
                    trait = gluttonous
                }
               
                piety = -10
               
                event_target:hunting_range = {
                    if = {
                        limit = { has_holding_modifier = hunted_out_2 }
                        add_holding_modifier = hunted_out_3
                    }
                    if = {
                        limit = { has_holding_modifier = hunted_out_1 }
                        add_holding_modifier = hunted_out_2
                    }
                    if = {
                        limit = {
                            NOT = { has_holding_modifier = hunted_out_1 }
                        }
                        add_holding_modifier = hunted_out_1
                    }
                }
            }
            1 = {#50--------------------------------------------------------------xxxxxxxxxxxxxx
                modifier = {
                    factor = 2
                    trait = temperate
                }
            }
        }
        random_list = { # Chance to bring home a trophy
            1000 = { #1--------------------------------------------------------xxxxxxxxxxxxxx
                modifier = {
                    factor = 3
                    trait = proud
                }
                modifier = {
                    factor = 2
                    trait = impaler
                }
                modifier = {
                    factor = 1.5
                    trait = cruel
                }
                character_event = { id = dawn.5101 }
            }
            99 = { }
        }
    }
}
character_event = { # Hunting - Bring home a trophy !
    id = dawn.5101
    desc = EVTDESCdawn.5101
    picture = GFX_evt_tribal_warriors #Something about trophies------------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.5101
        prestige = 25
    }
   
    after = {
        random_list = {
            50 = { add_artifact = ingredient_animal5 } #Antlers
            30 = { add_artifact = rival_skull } #Rival's Skull
            15 = { add_artifact = ingredient_animal4 } #Cloven hooves
            5 = { add_artifact = ingredient_animal7 } #Heart
        }
    }
}

character_event = { # Hunting - Capture small game
    id = dawn.511
    desc = EVTDESCdawn.511
    picture = GFX_evt_tribal_warriors #Something about rabbits---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.511
        prestige = 10
    }
   
    after = {
        random_list = {
            25 = {
                modifier = {
                    factor = 2
                    trait = gluttonous
                }
               
                piety = -10
               
                event_target:hunting_range = {
                    if = {
                        limit = { has_holding_modifier = hunted_out_2 }
                        add_holding_modifier = hunted_out_3
                    }
                    if = {
                        limit = { has_holding_modifier = hunted_out_1 }
                        add_holding_modifier = hunted_out_2
                    }
                    if = {
                        limit = {
                            NOT = { has_holding_modifier = hunted_out_1 }
                        }
                        add_holding_modifier = hunted_out_1
                    }
                }
            }
            75 = {
                modifier = {
                    factor = 2
                    trait = temperate
                }
            }
        }
    }
}

character_event = { # Hunting - Scraps and leftovers
    id = dawn.512
    desc = EVTDESCdawn.512
    picture = GFX_evt_tribal_warriors #Something about leftovers---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.512
        prestige = -5
    }
}

character_event = { # Hunting - Warrior wounded !
    id = dawn.513
    desc = EVTDESCdawn.513
    picture = GFX_evt_tribal_warriors #Something about being injured---------------------------------------------------------
   
    is_triggered_only = yes
   
    immediate = {
        random_courtier = {
            limit = {
                prisoner = no
                age >= 14
                NOT = {    trait = incapable }
            }
            random_list = {
                75 = { add_trait = wounded }
                20 = {add_trait = maimed }
                5 = { death = { death_reason = death_accident } }
               
            }
            save_event_target_as = mauled_warrior
        }
    }
   
    option = {
        name = EVTOPTAdawn.513
        prestige = -20
        piety = -10
    }
}


character_event = { # Scavenging - Find big resource
    id = dawn.520
    desc = EVTDESCdawn.520
    picture = GFX_evt_tribal_warriors #Something about scavenging---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.520
        wealth = 25
    }
   
    after = {      
        random_list = { # Chance to scavenge out the area
            50 = {
                modifier = {
                    factor = 2
                    trait = greedy
                }
               
                piety = -10
               
                event_target:scavenging_range = {
                    if = {
                        limit = { has_holding_modifier = scavenged_out_2 }
                        add_holding_modifier = scavenged_out_3
                    }
                    if = {
                        limit = { has_holding_modifier = scavenged_out_1 }
                        add_holding_modifier = scavenged_out_2
                    }
                    if = {
                        limit = {
                            NOT = { has_holding_modifier = scavenged_out_1 }
                        }
                        add_holding_modifier = scavenged_out_1
                    }
                }
            }
            50 = {
                modifier = {
                    factor = 2
                    trait = temperate
                }
            }
        }
        random_list = { # Chance to find a resource
            5 = {
                modifier = {
                    factor = 3
                    trait = gardener
                }
                modifier = {
                    factor = 2
                    trait = genius
                }
                modifier = {
                    factor = 1.5
                    trait = diligent
                }
                character_event = {id = dawn.5201 } # Bring home a trophy !
            }
            5 = {
                character_event = {id = dawn.5202 } # Find a rock quarry !
            }
            90 = { }
        }
    }
}
character_event = { # Scavenging - Bring home a trophy !
    id = dawn.5201
    desc = EVTDESCdawn.5201
    picture = GFX_evt_tribal_warriors #Something about trophies------------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.5201
        piety = 25
    }
   
    after = {
        random_list = {
            30 = { add_artifact = ingredient_metal_exotic1 } #Silver
            15 = { add_artifact = ingredient_metal_exotic6 } #Gold
            10 = { add_artifact = ingredient_metal_exotic8 } #Iron
            10 = { add_artifact = ingredient_metal_exotic7 } #Copper
            10 = { add_artifact = ingredient_herb3 } #Mandrake
            10 = { add_artifact = ingredient_herb6 } #Wormwood
            5 = { add_artifact = axe_tier_1 } #Common Axe
            3 = { add_artifact = axe_tier_2 } #Big Axe
            1 = { add_artifact = axe_tier_3_cleaver } #Huge Axe !
            1 = { add_artifact = obsidian_axe } #Obsidian Axe
            1 = { add_artifact = mace_tier_3_foe_hammer } #Huge Mace
            1 = { add_artifact = mace_tier_3_bone_breaker } #Huge Mace
            1 = { add_artifact = mace_tier_3_shatterer } #Huge Mace
            1 = { add_artifact = cursed_diamond } #Cursed Diamond
            1 = { add_artifact = fetish_of_souls } #Fetish of Souls
        }
    }
}
character_event = { # Scavenging - Find a rock quarry
    id = dawn.5202
    desc = EVTDESCdawn.5202
    picture = GFX_evt_tribal_warriors #Something about rocks------------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.5202
        piety = 10
    }
   
    after = {
        add_province_modifier = {
            name = stone_quarry
            duration = 29200 # 80 years
        }
    }
}

character_event = { # Scavenging - Find small resource
    id = dawn.521
    desc = EVTDESCdawn.521
    picture = GFX_evt_tribal_warriors #Something about rabbits---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.521
        wealth = 10
    }
   
    after = { #Chance to scavenge out the area
        random_list = {
            25 = {
                modifier = {
                    factor = 2
                    trait = greedy
                }
               
                piety = -10
               
                event_target:scavenging_range = {
                    if = {
                        limit = { has_holding_modifier = scavenged_out_2 }
                        add_holding_modifier = scavenged_out_3
                    }
                    if = {
                        limit = { has_holding_modifier = scavenged_out_1 }
                        add_holding_modifier = scavenged_out_2
                    }
                    if = {
                        limit = {
                            NOT = { has_holding_modifier = scavenged_out_1 }
                        }
                        add_holding_modifier = scavenged_out_1
                    }
                }
            }
            75 = {
                modifier = {
                    factor = 2
                    trait = temperate
                }
            }
        }
    }
}

character_event = { # Scavenging - Odds and ends
    id = dawn.522
    desc = EVTDESCdawn.522
    picture = GFX_evt_tribal_warriors #Something about odds and ends---------------------------------------------------------
   
    is_triggered_only = yes
   
    option = {
        name = EVTOPTAdawn.522
        piety = -5
    }
}
 

jordarkelf

01_TITLE_STRING
164 Badges
Jul 13, 2005
8.040
647
erbkaiser.nl
  • Impire
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • For the Motherland
  • Galactic Assault
  • Gettysburg
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Divine Wind
  • Europa Universalis III Complete
  • Iron Cross
  • King Arthur II
  • Knights of Pen and Paper +1 Edition
  • Lead and Gold
  • Legio
  • Leviathan: Warships
  • The Kings Crusade
  • Lost Empire - Immortals
  • Magicka
  • Majesty 2
  • Victoria 3 Sign Up
  • Crusader Kings II: Sons of Abraham
  • Ancient Space
  • Hearts of Iron Anthology
  • Arsenal of Democracy
  • Hearts of Iron II: Armageddon
  • Cities in Motion
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • A Game of Dwarves
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Commander: Conquest of the Americas
  • Darkest Hour
  • Deus Vult
  • Diplomacy
  • Dungeonland
  • East India Company
  • East India Company Collection
  • Europa Universalis III
looking at doing some things evolving duchies and changing dejure land of counties into different duchies. is it possible to do on the creation of a titular duchy through normal means? adding effect or creation_effect into landed_titles doesn't seem to work or at least work with this type of thing.
I have never tried it with counties, but for duchies you can get it to work by using gain_effect. (not effect or creation_effect).
Take a look at the default landed_titles.txt for a gain_effect example with k_jerusalem.
 

jursamaj

General
125 Badges
Aug 20, 2012
2.360
216
  • Victoria 2: Heart of Darkness
  • Hearts of Iron III
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
  • Cities in Motion
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Victoria 2: A House Divided
  • Leviathan: Warships
  • Rome: Vae Victis
  • Stellaris
  • Europa Universalis IV: Pre-order
  • Magicka 2 - Signup Campaign
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis III
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis III Complete
  • Europa Universalis IV: Conquest of Paradise
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Europa Universalis III: Chronicles
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Conclave
  • Europa Universalis III Complete
  • Europa Universalis IV: Common Sense
  • Europa Universalis III Complete
  • Pillars of Eternity
  • Europa Universalis IV
  • Europa Universalis IV: El Dorado
  • 500k Club
  • Stellaris Sign-up
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: No Step Back
Possibly, though I expect the computational cost is roughly the same as you still compare all realm provinces to a list of provinces (though it definitely will look prettier in the events/decisions).
If I understand correctly, any_* triggers shortcut. That is, as soon as they find 1 province/character/whatever for which it evaluates as true, it quits checking. In any case, unless your realm is really big, it shouldn't be a problem.

Also, if region checks are implemented at all sanely (hash table), checking each tested province is nearly as fast as simply province = N. It should *not* have to scan the whole list.
 

jursamaj

General
125 Badges
Aug 20, 2012
2.360
216
  • Victoria 2: Heart of Darkness
  • Hearts of Iron III
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
  • Cities in Motion
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Victoria 2: A House Divided
  • Leviathan: Warships
  • Rome: Vae Victis
  • Stellaris
  • Europa Universalis IV: Pre-order
  • Magicka 2 - Signup Campaign
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis III
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis III Complete
  • Europa Universalis IV: Conquest of Paradise
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Europa Universalis III: Chronicles
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Conclave
  • Europa Universalis III Complete
  • Europa Universalis IV: Common Sense
  • Europa Universalis III Complete
  • Pillars of Eternity
  • Europa Universalis IV
  • Europa Universalis IV: El Dorado
  • 500k Club
  • Stellaris Sign-up
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: No Step Back
looking at doing some things evolving duchies and changing dejure land of counties into different duchies. is it possible to do on the creation of a titular duchy through normal means? adding effect or creation_effect into landed_titles doesn't seem to work or at least work with this type of thing.

Code:
d_amalfi = {
    color={ 140 200 230 }
    capital = 935 # Amalfi
   
    dignity = 10
   
    allow = {
        is_republic = yes
    }
    effect = {
        c_amalfi = {
            de_jure_liege = d_amalfi
        }
    }
}

when using creation_effect instead it just changed the dejure instantly upon game start/load and results in no king or empire dejure ties

also on a similar note how would I go about using title_decisions (right click interact menu on title flags directly) to make it so i can flag a duchy and then right click interact with a county to make it under dejure for that selected duchy?

this is what i have so far on the matter but it doesn't work on changing the county dejure duchy to flaged one nor does it work so i can only allow it to only work on your realm

Code:
    set_duchy_for_swap_original = {
        filter = realm_owned
        only_playable = yes
       
        from_potential = {
            ai = no
            is_playable = yes
            #tier = DUKE
            #war = no
            #wealth = 600
        }
       
        potential = {
            tier = DUKE
        }
       
        allow = {
            always = yes
            #war = no
        }
       
        ai_will_do = {
            factor = 0
        }
       
        effect = {
            set_title_flag = SWAP_TO_ME
        }
    }

    canclel_duchy_for_swap = {
        only_playable = yes
       
        from_potential = {
            ai = no
            is_playable = yes
            #tier = DUKE
            #war = no
            #wealth = 600
        }
       
        potential = {
            tier = DUKE
            has_title_flag = SWAP_TO_ME
        }
       
        allow = {
            always = yes
            #war = no
        }
       
        ai_will_do = {
            factor = 0
        }
       
        effect = {
            clr_title_flag = SWAP_TO_ME
        }
    }
   
    swap_county_dejure_to_duchy = {
        only_playable = yes
       
        from_potential = {
            ai = no
            is_playable = yes
            #tier = DUKE
            #war = no
            #wealth = 600
            any_realm_title = {
                has_title_flag = SWAP_TO_ME
            }
        }
       
        potential = {
            tier = COUNT
        }
       
        allow = {
            always = yes
            #war = no
        }
       
        ai_will_do = {
            factor = 0
        }
       
        effect = {
            THIS = {
                de_jure_liege = {
                    any_realm_title = {
                        has_title_flag = SWAP_TO_ME
                    }
                }
            }
        }
    }
Since you have your title 'effect' written with no limit, it *would* fire every time there's a new owner, including at game start.

Vanilla has 2 ways of putting in creation effect for titles.

1: Kingdom of Jerusalem has a 'gain_effect' in landed_titles.txt, that uses a global flag to make sure this is the 1st time it has been gained (thus created, rather than inherited, usurped, etc.). Will not fire a 2nd time, even if k_jerusalem is destroyed and then created again. If you don't like to use a flag, this can also be accomplished with NOT={any_previous_holder={always=yes}}.

2: Add an event to the on_create_title action. In that event, check that FROM is the title you are interested in. This can also be limited with a flag or any_previous_holder check so that it's only the 1st time it's created.

Your decisions look OK, except the de_jure_liege part. de_jure_liege takes a title, either explicitly or ROOT/FROM/etc. Instead:
Code:
any_realm_title = {
    limit = { has_title_flag = SWAP_TO_ME } 
    ROOT = { de_jure_liege = PREV }
}
 

jursamaj

General
125 Badges
Aug 20, 2012
2.360
216
  • Victoria 2: Heart of Darkness
  • Hearts of Iron III
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
  • Cities in Motion
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Victoria 2: A House Divided
  • Leviathan: Warships
  • Rome: Vae Victis
  • Stellaris
  • Europa Universalis IV: Pre-order
  • Magicka 2 - Signup Campaign
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis III
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis III Complete
  • Europa Universalis IV: Conquest of Paradise
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Europa Universalis III: Chronicles
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Conclave
  • Europa Universalis III Complete
  • Europa Universalis IV: Common Sense
  • Europa Universalis III Complete
  • Pillars of Eternity
  • Europa Universalis IV
  • Europa Universalis IV: El Dorado
  • 500k Club
  • Stellaris Sign-up
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: No Step Back
Also wondering another thing that i also cant seem to figure out, would it be possible to make it so a custom created title (via charlemagne) uses the coat of arms from your dynasty or from another title instead of inheriting from the original target? Like how the patricians manor has the dynastic flag. because you can adapt the intrigue decision into a title_decisions and create new titles of any tier (at the least duke and up that i have tested) from any title

this is what i have to do that but i dont know how to change or add to it to do that this also dosent give you the title unless you are the owner of the title that you are making a duke clone of

Code:
    create_new_titular_dutchy_from_title = {
        only_playable = yes
       
        from_potential = {
            ai = no
            is_playable = yes
            #tier = DUKE
            #war = no
            #wealth = 600
        }
       
        potential = {
            OR = {
                tier = BARON
                tier = COUNT
                tier = DUKE
                tier = KING
                tier = EMPEROR
            }
        }
       
        allow = {
            always = yes
            #war = no
        }
       
        ai_will_do = {
            factor = 0
        }
       
        effect = {
            create_title = {
                tier = DUKE
                landless = no
                temporary = no
                custom_created = yes
                culture = ROOT
                holder = ROOT
                base_title = THIS
                copy_title_laws = yes
            }
        }
    }


EDIT: after doing a quick test baron titles can be duped into a duchy but the flag will result in the black and red null rebel flag. is it possible to have it so that created titles can use the dynamic house flags like the patrician palace or no?
Check out the set_coa command. It will take any existing title, and copy it's coat of arms (flag) to the current title. I don't know if it will take a character and copy *their* coa.
 

SirRitter

First Lieutenant
1 Badges
Oct 1, 2014
299
301
  • Crusader Kings II
It annoys me that every vassal of the HRE duke tier or above can vote for the next emperor.

A silly question, but is there a way to make it so that only the traditional seven prince-electors can vote? Other than messing up all titles so that there are only 7 vassals of duke tier(which would be both difficult and buggy).
 
Last edited:

philanthropic19

Khan of Khans
36 Badges
Sep 13, 2013
476
742
  • Crusader Kings II
  • Cities in Motion 2
  • Magicka
  • Hearts of Iron III
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: The Republic
  • Crusader Kings II: Reapers Due
  • Crusader Kings II: Monks and Mystics
  • Cities: Skylines - Mass Transit
  • Age of Wonders III
  • Age of Wonders
  • Age of Wonders II
  • Crusader Kings II: Jade Dragon
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Crusader Kings II: Holy Fury
  • Prison Architect
  • Crusader Kings III
  • Hearts of Iron IV Sign-up
  • Cities: Skylines - Snowfall
  • Crusader Kings II: Conclave
  • Cities: Skylines - After Dark
  • Crusader Kings II: Horse Lords
  • Magicka 2
  • Crusader Kings II: Way of Life
  • Magicka: Wizard Wars Founder Wizard
  • Cities: Skylines
  • Victoria 2
  • Stellaris
  • Cities: Skylines Deluxe Edition
Question about regency:
I'm looking to make a mod that would cause a regency to occur if the ruler was leading troops outside the capital province. However, the only way I see to do it right now is to give him a hidden trait with "pilgrimage = yes" or "incapacitating = yes" - however both of these make him unable to lead troops anymore. Is there a way to cause a regency to occur while still having the ruler available to lead troops?
 

Metanetwork

Major
36 Badges
Jul 7, 2016
514
16
  • Europa Universalis IV: Cradle of Civilization
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Conclave
  • Europa Universalis IV: Mare Nostrum
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Third Rome
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Jade Dragon
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Dharma
  • Crusader Kings II: Holy Fury
  • Europa Universalis IV: Golden Century
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Europa Universalis 4: Emperor
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
Random question about errors.

Is there anything bad that could happen if I reference things like traits that does not exist in the code? It create an error in the log, but nothing bad seem to happen in game.
I don't know about traits, but unusual behavior can happen for religions.

Any religion that isn't defined in the files defaults to "no_religion". It's a fallback to avoid crashes. If a character switches to religion "covfefe" (where "covfefe" is not defined), they switch to no_religion instead. If an event trigger in the same mod is "religion = covfefe", that trigger is respected for any no_religion character. I suspect that the same thing is true for government types since there is also a no_government government. But I didn't try giving an inexistent trait to a character.
 

Maal

Society Master
115 Badges
Nov 10, 2013
691
81
  • Rome: Vae Victis
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Rome Gold
  • Semper Fi
  • Sengoku
  • Stellaris: Galaxy Edition
  • Stellaris
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • King Arthur II
  • Warlock: Master of the Arcane
  • Warlock 2: The Exiled
  • Europa Universalis IV: Mare Nostrum
  • Cities: Skylines Deluxe Edition
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Pre-order
  • Knights of Pen and Paper 2
  • Crusader Kings II: Monks and Mystics
  • Magicka 2
  • Crusader Kings II: Reapers Due
  • Cities: Skylines - After Dark
  • Europa Universalis III: Chronicles
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Ancient Space
  • Divine Wind
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III Collection
  • Heir to the Throne
@Metanetwork
I see, but my situation is a little bit different. My mod wouldn't give any possibly "non-existent" traits, it is mostly to add triggers. It's to make my mod compatible with others without making dozens of patches, these non-existent traits exist is those other mods. None of the events that include triggers based on these missing traits should happen to begin with because of the missing global flags (set at the game start if X mod is enabled) would have stopped the event.

In any case, I have not seen any issue in game, but it is hard to tell when you are looking for non-existant stuff.
 

LordPeter

Marjoram
49 Badges
Mar 5, 2012
2.249
382
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Crusader Kings II: Monks and Mystics
  • Crusader Kings II: Conclave
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Prison Architect
  • Stellaris - Path to Destruction bundle
  • Cities: Skylines - Mass Transit
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Imperator: Rome
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: El Dorado
  • 500k Club
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Europa Universalis IV
  • Crusader Kings II: Sword of Islam
  • Stellaris
  • Europa Universalis IV: Third Rome
  • Cities: Skylines
  • Crusader Kings II: Jade Dragon
  • Europa Universalis IV: Cradle of Civilization
@Maal:
Afaik you can check for a non-existent trait in conditions as much as you want, the game will just not find it and resolve the condition as failed.
Within an effect, it probably shouldn't be much different, as - in contrast to religions - traits are optional. So if the engine fails to find a trait, it can just ignore it and need not e.g. assign "no_religion".
A quick test seems to confirm that: When I use a targeted decision to give a character a trait with a nonsensical name (e.g. "add_trait = agbnloubiyt"), the trait name is just displayed as " (literally one of these characters) in the decision, and nothing happens. The error log might complain of course, but no harm done.

Pls keep in mind that I am just guessing here, I don't actually know how the engine works. But it seems to be fine as far as I can see - as long as it is about optional things like traits or modifiers, and not fundamental and mutually exclusive stuff like culture or religion.
 

Thezezeal

Captain
3 Badges
Dec 28, 2014
375
3
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Monks and Mystics
  • Crusader Kings II: Charlemagne
Is there a way to make a Dynasty use a County Flag instead of a normal Dynasty CoA? From looking at the Dynasty modding page, it looks like I'd have to make new patterns and icons, rather than just force the flag directly?
 

ThePatriot1776

Colonel
53 Badges
Sep 13, 2012
1.116
326
  • Surviving Mars
  • Europa Universalis 4: Emperor
  • Europa Universalis IV: Res Publica
  • Cities in Motion
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Rights of Man
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Third Rome
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Cradle of Civilization
  • Europa Universalis IV: Rule Britannia
  • Surviving Mars: Digital Deluxe Edition
  • Europa Universalis IV: Dharma
  • Surviving Mars: First Colony Edition
  • Europa Universalis IV: Golden Century
  • Imperator: Rome
  • Surviving Mars: First Colony Edition
  • Europa Universalis IV: Call to arms event
  • Crusader Kings III
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Europa Universalis IV
  • Heir to the Throne
  • Divine Wind
  • Europa Universalis III Complete
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: The Republic
  • 500k Club
  • Crusader Kings II: Holy Fury
  • Shadowrun: Dragonfall
  • Shadowrun Returns
  • Crusader Kings II: Jade Dragon
  • Age of Wonders III
  • Crusader Kings II: Monks and Mystics
  • Crusader Kings II: Reapers Due
  • Crusader Kings II: Conclave
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Way of Life
  • War of the Roses
Is there a way to make a Dynasty use a County Flag instead of a normal Dynasty CoA? From looking at the Dynasty modding page, it looks like I'd have to make new patterns and icons, rather than just force the flag directly?

Easiest way is to take all the county flags you like and put them into a pattern.tga file. Then use the texture calls as normal. Here is an example from my Aliyah. I force the unlanded duchy dynasty titles to use the dynasty flags.

Code:
 CoatofArms.txt
textures = {
        texture = {
            file = "gfx\\coats_of_arms\\pattern.tga"
            size = { x = 10 y = 7 }
            noOfFrames = 62
            color = 4
            emblem = no
        }
    }
Code:
Dynasties.txt
100154000 = {
    name = bet Ach'av
    culture = romaniote
    coat_of_arms = {
        template = coa_plain
        layer = {
            texture = 0
            texture_internal = 1
            color = 0
            color = 0
            color = 0
            color = 0
        }
    }
}
 

CorpusIurisCivilis

First Lieutenant
41 Badges
Aug 3, 2017
277
47
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sons of Abraham
  • Stellaris: Lithoids
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • BATTLETECH: Flashpoint
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Imperator: Rome
  • Imperator: Rome Sign Up
  • Stellaris: Ancient Relics
  • BATTLETECH: Season pass
  • BATTLETECH
  • BATTLETECH: Heavy Metal
  • Stellaris: Federations
  • Imperator: Rome - Magna Graecia
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Nemesis
  • Stellaris: Synthetic Dawn
  • Crusader Kings II: The Republic
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Conclave
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Crusader Kings II: Reapers Due
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Jade Dragon
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
Quick question... I'm creating a Gothic Culture for Crimea... I want to name Independent dukes to be named Prince and their duchies Principalities. Is there a way to do it in the localisation?