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

Anyasia

Lightbringer
72 Badges
Aug 5, 2015
428
265
  • Europa Universalis IV: Rights of Man
  • Crusader Kings Complete
  • Crusader Kings II
  • Crusader Kings III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Conclave
I want characters with my trate to live for 200 years and not age, but only visually.
What is the easiest way to do this?

Set the flag immortal = yes in the trait definition. This will stop them from ageing from the time they receive the trait, though if you need to later change their visual age, you can use set_immortal_age in an event, on action, or scripted effect.

Giving them a trait with immortality will prevent them from ever naturally dying; to have them die when they're 200, or 200 years after receiving the trait, there are several options available.

In the former case, if you want them to die when they're 200 years old, you can create an on action that fires on their birthday, which causes them to die:—

Code:
# common/on_action/example.txt
on_birthday = {
    effect = {
        if = {
            limit = { age = 200 }
            death = natural
        }
    }
}

You could also code this in a separate on action, which fires after a random delay, so the character dies at some point during the year following their 200th birthday, rather than on it:—

Code:
# common/on_action/example.txt
on_birthday = {
    effect = {
        if = {
            limit = { age = 200 }
            trigger_event = {
                on_action = example_kill_character
                days = { 1 365 }
            }
        }
    }
}

example_kill_character = {
    effect = {
        death = natural
    }
}

If you want to kill the character 200 years after they received the trait, you can similarly trigger an on action like this in the event or effect that gives them the trait:—

Code:
# for example, assuming the same example_kill_character on action as above is defined in common/on_action

add_trait = kill_after_200_years
trigger_event = {
    on_action = example_kill_character
    years = 200
}

You can also always simply remove the trait in a similar on action, if that is more desirable, which will then cause the affected characters to die soon after, given their extremely old age. Be aware, of course, that just because the character has an immortal trait, that won't prevent him from being assassinated, or dying in battle, or being subject to whatever other unnatural deaths may befall him.
 
  • 3Like
Reactions:

b@ron

Private
Jun 12, 2022
23
26
Code:
# common/on_action/example.txt
on_birthday = {
effect = {
if = {
limit = { age = 200 }
trigger_event = {
on_action = example_kill_character
days = { 1 365 }
}
}
}
}

example_kill_character = {
effect = {
death = natural
}
}
thanks, it looks great.I'll try it now. But if I want death to occur in more than one year.
And on some random day for 15 years. What should I add here?
 
Last edited:
  • 1Like
Reactions:

Amtep

Colonel
60 Badges
Nov 20, 2017
939
2.334
  • Crusader Kings II
  • Europa Universalis IV: Mare Nostrum
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • 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
  • Imperator: Rome - Magna Graecia
  • BATTLETECH
  • Surviving Mars
  • Europa Universalis IV: Cradle of Civilization
  • BATTLETECH: Season pass
  • Europa Universalis IV: Rights of Man
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Surviving Mars: First Colony Edition
  • Crusader Kings III
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Europa Universalis IV: Golden Century
  • Imperator: Rome Deluxe Edition
  • Stellaris: Ancient Relics
  • Surviving Mars: First Colony Edition
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV
  • BATTLETECH: Heavy Metal
  • Stellaris: Nemesis
  • Europa Universalis 4: Emperor
  • Victoria 2
  • Stellaris: Federations
  • Stellaris: Lithoids
  • 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
  • Crusader Kings II: Conclave
  • Stellaris
  • Tyranny: Archon Edition
  • 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: Sword of Islam
thanks, it looks great.I'll try it now. But if I want death to occur in more than one year.
And on some random day for 15 years. What should I add here?
The line days = { 1 365 } says how far in the future it should happen: at least 1 day, at most 365 (= one year). So you could put days = { 1 5475 } to make it a random day between now and 15 years. (5475 = 15 times 365)
 
  • 2Like
  • 1
Reactions:

WeeLittleSpoon

Never met a word he didn't like
89 Badges
Mar 30, 2017
278
1.251
  • Crusader Kings II
  • Stellaris: Synthetic Dawn
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Rights of Man
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Europa Universalis IV: Mare Nostrum
  • Cities: Skylines - Snowfall
  • Cities: Skylines - After Dark
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Semper Fi
  • Victoria: Revolutions
  • Europa Universalis IV: Res Publica
  • Hearts of Iron III: Their Finest Hour
  • For the Motherland
  • Cities in Motion
  • 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
  • Hearts of Iron III
  • Darkest Hour
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Hearts of Iron IV: Field Marshal
  • Crusader Kings Complete
  • Europa Universalis IV: Mandate of Heaven
  • Cities: Skylines - Mass Transit
  • Steel Division: Normandy 44
  • Hearts of Iron IV: No Step Back
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Crusader Kings II: Reapers Due
  • Crusader Kings II: Way of Life
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Victoria 2
  • Europa Universalis IV
  • Stellaris: Galaxy Edition
  • Cities: Skylines
  • Crusader Kings II: Conclave
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Horse Lords
I'm having some trouble with editing a custom map.

I'm trying to create a 'mini-mod' that is basically only France and some surrounding regions, and I can't get the map editor to load my heightmap. I've gone through the wiki pretty carefully, and I've edited the heightmap.heightmap, definition.csv, adjacenies.csv, 00_defines.txt, 00_graphics.txt, default.map, 00_province_terrain.txt files, and I have a rivers.png, heightmap.png, provinces.png, and I've edited all the necessary masks, but every time I try to load the game in -mapeditor mode, it crashes with the message "Failed to set up terrain for Map Editor".

In Googling it, the best clue I got was to make sure the heightmap.png is in 16-bit Grayscale, which I've confirmed multiple times to be true.

I've also tried to load the vanilla map and then import the map there, to get the indirection_heightmap and packed_heightmap, but that crashed too.

The heightmap that I have is very small, 831x931, and I'm worried that might be partially the problem, but even trying to upscale it to three times its size (and changing the necessary variable in heightmap.heightmap) I still couldn't get it to work.

I've managed to get custom maps with custom resolutions to work before, but I am just out of ideas for what to fix here.

Here's a screenshot of the map in terrain mode.

2022-06-18 08-33-22 - map messed up.png

It looks to me like the game is still taking information from the old heightmap, which I guess makes sense since I haven't been able to load mine into the game yet.

Any insight is appreciated.

EDIT: Alright, I figured it out. I had a 1 pixel transparent line on the heightmap that was preventing it from loading properly. Don't have transparency on a heightmap, lesson learned.
 
Last edited:
  • 2Like
Reactions:

b@ron

Private
Jun 12, 2022
23
26
Code:
Code:
# common/on_action/example.txt
on_birthday = {
    effect = {
        if = {
            limit = { age = 200 }
            trigger_event = {
                on_action = example_kill_character
                days = { 1 365 }
            }
        }
    }
}

example_kill_character = {
    effect = {
        death = natural
    }
}
okay, it definitely works. But as a person who has a paranoid trait, how about productivity. I don't know how this thing works. Does he read it when starting the game and remember it?Or will he check all the characters for compliance every day? Or does it not have much effect?
(5475 = 15 times 365)
same question

Code:
if = {
limit = {
    scope:real_father = { has_trait = homelander }   
 }


  #one of the two should be randomly selected
(
add_trait = Variant1
OR
add_trait = Variant2
                )
}
What should I write here so that one of the traits is randomly selected at birth?
 
  • 1Like
Reactions:

WeeLittleSpoon

Never met a word he didn't like
89 Badges
Mar 30, 2017
278
1.251
  • Crusader Kings II
  • Stellaris: Synthetic Dawn
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Rights of Man
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Europa Universalis IV: Mare Nostrum
  • Cities: Skylines - Snowfall
  • Cities: Skylines - After Dark
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Semper Fi
  • Victoria: Revolutions
  • Europa Universalis IV: Res Publica
  • Hearts of Iron III: Their Finest Hour
  • For the Motherland
  • Cities in Motion
  • 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
  • Hearts of Iron III
  • Darkest Hour
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Hearts of Iron IV: Field Marshal
  • Crusader Kings Complete
  • Europa Universalis IV: Mandate of Heaven
  • Cities: Skylines - Mass Transit
  • Steel Division: Normandy 44
  • Hearts of Iron IV: No Step Back
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Crusader Kings II: Reapers Due
  • Crusader Kings II: Way of Life
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Victoria 2
  • Europa Universalis IV
  • Stellaris: Galaxy Edition
  • Cities: Skylines
  • Crusader Kings II: Conclave
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Horse Lords
okay, it definitely works. But as a person who has a paranoid trait, how about productivity. I don't know how this thing works. Does he read it when starting the game and remember it?Or will he check all the characters for compliance every day? Or does it not have much effect?

same question

Code:
if = {
limit = {
    scope:real_father = { has_trait = homelander }  
 }


  #one of the two should be randomly selected
(
add_trait = Variant1
OR
add_trait = Variant2
                )
}
What should I write here so that one of the traits is randomly selected at birth?
You can use a random_list, I think.
Code:
random_list = {
    50 = { # Change these numbers to affect the random distribution. These are not percentages.
        add_trait = trait_1
    }
    
    50 = {
        add_trait = trait_2
    }
    
    50 = {
        trigger = { # Use triggers to include/exclude some list options in the random function dependent on its triggers
            has_trait = paranoid
        }
        
        add_trait = trait_3
    }
}
 
  • 3Like
Reactions:

KKrive500

Mors Ante Pudorem
14 Badges
Jun 28, 2013
642
427
  • Crusader Kings II
  • Europa Universalis IV
  • Crusader Kings III
  • Hearts of Iron III
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Sword of Islam
  • 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: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sunset Invasion
  • Magicka
this
Code:
krivemod = {
   krivemod = {
        traits = { krivetrait }
        dna_modifiers = {
               color = {
                gene = eye_color
                mode = replace
                x = 0.982
                y = 0.151
                }
            color = {
                gene = skin_color
                mode = replace
                x = 0.451
                y = 0.4647
            }
            color = {
                gene = hair_color
                mode = replace
                x = 0.43
                y = 0.22
            }
        morph = {
                mode = replace
                gene = gene_bs_bust
                template = bust_clothes
                value = 60065
            }
        morph = {
                mode = replace
                gene = gene_height
                template = normal_height
                value = 0.88
            }
    }
  }
}

I'm having issues getting this file to work, not seeing any of my changes related to this trait. Is there another dependent code or txt file I need somewhere to link the two besides this is portraits_modifiers?
 
  • 1Love
Reactions:

b@ron

Private
Jun 12, 2022
23
26
Is there another dependent code or txt file I need somewhere to link
No, I have 4 appearance options written down this way. this should work 100 percent if you didn't make any mistakes and put your file in the right place. You should have your trait and I suppose the file name should end with " _trait_modifiers"
1655574203472.png

1655574342098.png
 
Last edited:
  • 1
Reactions:

Anyasia

Lightbringer
72 Badges
Aug 5, 2015
428
265
  • Europa Universalis IV: Rights of Man
  • Crusader Kings Complete
  • Crusader Kings II
  • Crusader Kings III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Conclave
But as a person who has a paranoid trait, how about productivity. I don't know how this thing works. Does he read it when starting the game and remember it?Or will he check all the characters for compliance every day? Or does it not have much effect?

The on_birthday on action fires for every character on their birthdays anyway. Since the effect immediately hits a conditional check that tells it only to proceed if the character is 200—and præsumably only characters with this trait should ever live that long to trigger it—there shouldn't be any noticeable performance hit. Now that it's pointed out, however, if you ever do anything else that might create immortal characters, or otherwise extend their lifespans, without wanting to kill them after 200 years, you might want to add another check in the limit block to check if they have your trait, so you don't accidentally kill any of your other duocentenarian characters.

Code:
limit = {
    age = 200
    has_trait = yourtrait
}

The random ranges on when it should fire should also have a negligible impact; I'm not sure exactly how they work, if the duration is calculated when the event is fired, or on game load, or whatever, but it at the very least will not be checking all the characters every day, so you don't need to worry about that. Paradox learned their lessons from the performance nightmare that was Mean Time To Happen in CK2. ;)
 
  • 2Like
Reactions:

KKrive500

Mors Ante Pudorem
14 Badges
Jun 28, 2013
642
427
  • Crusader Kings II
  • Europa Universalis IV
  • Crusader Kings III
  • Hearts of Iron III
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Sword of Islam
  • 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: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sunset Invasion
  • Magicka
No, I have 4 appearance options written down this way. this should work 100 percent if you didn't make any mistakes and put your file in the right place. You should have your trait and I suppose the file name should end with " _trait_modifiers"
View attachment 851460

Alright, so what was happening is I didn't have it inside the trait_portrait_modifiers folder.. I can't believe I overlooked that. Thank you it's working now!
 
  • 1Love
Reactions:

Lord Asgar

Captain
44 Badges
Dec 26, 2013
384
202
  • Crusader Kings II
  • Pillars of Eternity
  • Tyranny - Tales from the Tiers
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Art of War
  • Darkest Hour
  • 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
  • Europa Universalis IV: Rights of Man
  • Crusader Kings III: Royal Edition
  • Tyranny: Archon Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Tyranny - Bastards Wound
  • Crusader Kings II: Jade Dragon
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Crusader Kings II: Holy Fury
  • Hearts of Iron IV: Expansion Pass
  • Crusader Kings III
  • Crusader Kings II: Reapers Due
  • Hearts of Iron IV: Cadet
  • Stellaris
  • Crusader Kings II: Conclave
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Way of Life
  • Mount & Blade: Warband
  • Europa Universalis IV: El Dorado
  • Victoria 2
  • Europa Universalis IV
  • Europa Universalis IV: Mare Nostrum
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Europa Universalis IV: Conquest of Paradise
Very simple decision to make all of root's friends also become friends to each other:

Code:
    effect = {
   
    every_ruler = { limit = { has_relation_friend = root } save_scope_as = friendmaker }
    every_ruler = { limit = { has_relation_friend = root } set_relation_friend = scope:friendmaker }
   
    }

Sort of works, but not quite as intended. It picks out one friend and makes him befriend everyone else, but doesn't make the others become friends among each other. How do you do these "everyone in a given group doing something with everyone else in a given group" scenarios work in CK3 scripting? In CK2, I'd just have used a scope defining the group and then the command with a PREV, but CK3 doesn't have PREV, I believe.
 
  • 1Love
Reactions:

Anyasia

Lightbringer
72 Badges
Aug 5, 2015
428
265
  • Europa Universalis IV: Rights of Man
  • Crusader Kings Complete
  • Crusader Kings II
  • Crusader Kings III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Conclave
Very simple decision to make all of root's friends also become friends to each other:

Code:
    effect = {
 
    every_ruler = { limit = { has_relation_friend = root } save_scope_as = friendmaker }
    every_ruler = { limit = { has_relation_friend = root } set_relation_friend = scope:friendmaker }
 
    }

Sort of works, but not quite as intended. It picks out one friend and makes him befriend everyone else, but doesn't make the others become friends among each other. How do you do these "everyone in a given group doing something with everyone else in a given group" scenarios work in CK3 scripting? In CK2, I'd just have used a scope defining the group and then the command with a PREV, but CK3 doesn't have PREV, I believe.

CK3 definitely has PREV. You don't need to use it, as you could just save scopes the way you do, anyway, but it should certainly simplify things regardless.

This would be my instinctive approach to this problem (I'll also note that your code only targets friends who are rulers, not every friend; I'm not sure if that was intentional, but if so, you could still adapt my code to check if a character is landed):—

Code:
every_relation = {
    type = friend
    add_to_temporary_list = all_roots_friends
}
every_in_list = {
    list = all_roots_friends
    every_in_list = {
        list = all_roots_friends
        if = {
            limit = { can_set_relation_friend_trigger = { CHARACTER = prev } }
            set_relation_friend = prev
        }
    }
}

Edit: This code has been edited several times from its original form based on the suggestions in the comments that follow, notably:—

That's a good idea, but wouldn't it be simpler to replace limit = { NOR = { this = prev has_relation_friend = prev } } with limit = { can_set_relation_friend_trigger = { CHARACTER = prev } }?

Also, I never tried using set_relation_friend on a rival, does it override it or just return an error?
 
Last edited:
  • 2
  • 1Like
Reactions:

WeeLittleSpoon

Never met a word he didn't like
89 Badges
Mar 30, 2017
278
1.251
  • Crusader Kings II
  • Stellaris: Synthetic Dawn
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Rights of Man
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Europa Universalis IV: Mare Nostrum
  • Cities: Skylines - Snowfall
  • Cities: Skylines - After Dark
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Semper Fi
  • Victoria: Revolutions
  • Europa Universalis IV: Res Publica
  • Hearts of Iron III: Their Finest Hour
  • For the Motherland
  • Cities in Motion
  • 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
  • Hearts of Iron III
  • Darkest Hour
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Hearts of Iron IV: Field Marshal
  • Crusader Kings Complete
  • Europa Universalis IV: Mandate of Heaven
  • Cities: Skylines - Mass Transit
  • Steel Division: Normandy 44
  • Hearts of Iron IV: No Step Back
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Crusader Kings II: Reapers Due
  • Crusader Kings II: Way of Life
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Victoria 2
  • Europa Universalis IV
  • Stellaris: Galaxy Edition
  • Cities: Skylines
  • Crusader Kings II: Conclave
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Horse Lords
CK3 definitely has PREV. You don't need to use it, as you could just save scopes the way you do, anyway, but it should certainly simplify things regardless.

This would be my instinctive approach to this problem (I'll also note that your code only targets friends who are rulers, not every friend; I'm not sure if that was intentional, but if so, you could still adapt my code to check if a character is landed):—

Code:
every_relation = {
    type = friend
    add_to_temporary_list = all_roots_friends
}
every_in_list = {
    list = all_roots_friends
    every_in_list = {
        list = all_roots_friends
        if = {
            limit = { NOT = { has_relation_friend = prev } }
            set_relation_friend = prev
        }
    }
}
Oh man, that's such a smart use of lists.
 
  • 1Love
Reactions:

Anyasia

Lightbringer
72 Badges
Aug 5, 2015
428
265
  • Europa Universalis IV: Rights of Man
  • Crusader Kings Complete
  • Crusader Kings II
  • Crusader Kings III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Conclave
Oh man, that's such a smart use of lists.

I got the notification of you saying this and immediately thought, 'I'm an idiot for not having checked to stop the character trying to befriend himself,' 'cause I have no idea what that'd do, lol. I've edited it to hopefully do that, at least.
 
  • 1Haha
  • 1Love
Reactions:

Mcgan

Lt. General
18 Badges
Mar 19, 2020
1.239
1.826
  • Crusader Kings III: Royal Edition
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Stellaris: Distant Stars
  • Stellaris: Synthetic Dawn
  • Stellaris: Leviathans Story Pack
  • Stellaris: Apocalypse
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Federations
  • Stellaris: Nemesis
  • Stellaris: Humanoids Species Pack
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Lithoids
  • Stellaris: Necroids
Code:
every_relation = {
    type = friend
    add_to_temporary_list = all_roots_friends
}
every_in_list = {
    list = all_roots_friends
    every_in_list = {
        list = all_roots_friends
        if = {
            limit = { NOR = { this = prev has_relation_friend = prev } }
            set_relation_friend = prev
        }
    }
}
That's a good idea, but wouldn't it be simpler to replace limit = { NOR = { this = prev has_relation_friend = prev } } with limit = { can_set_relation_friend_trigger = { CHARACTER = prev } }?

Also, I never tried using set_relation_friend on a rival, does it override it or just return an error?
 
  • 1
  • 1Love
Reactions:

Anyasia

Lightbringer
72 Badges
Aug 5, 2015
428
265
  • Europa Universalis IV: Rights of Man
  • Crusader Kings Complete
  • Crusader Kings II
  • Crusader Kings III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Conclave
That's a good idea, but wouldn't it be simpler to replace limit = { NOR = { this = prev has_relation_friend = prev } } with limit = { can_set_relation_friend_trigger = { CHARACTER = prev } }?

Also, I never tried using set_relation_friend on a rival, does it override it or just return an error?

Oooh, thanks! That is probably a much better idea, assuming the goal isn't to override rivalries. I didn't even know that was predefined.

To your question, I'm also not sure. I'd hope it would override it, but it's a good question, 'cause it's possible it would error instead.
 
  • 1Like
  • 1Love
Reactions:

Mcgan

Lt. General
18 Badges
Mar 19, 2020
1.239
1.826
  • Crusader Kings III: Royal Edition
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Stellaris: Distant Stars
  • Stellaris: Synthetic Dawn
  • Stellaris: Leviathans Story Pack
  • Stellaris: Apocalypse
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Federations
  • Stellaris: Nemesis
  • Stellaris: Humanoids Species Pack
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Lithoids
  • Stellaris: Necroids
assuming the goal isn't to override rivalries.
Good point. Sounds like the idea was to force friendship in this case, so your solution is better.

To your question, I'm also not sure. I'd hope it would override it, but it's a good question, 'cause it's possible it would error instead.
Just tested it, it does override it. In fact, there doesn't seem to be any restriction to the set_relation_ effect. It's even possible to have several best friends/soulmates or make a lover with the wrong sexuality. And not a single error in the log.
 
  • 2
  • 1Love
Reactions:

Gutie

First Lieutenant
147 Badges
Aug 23, 2009
269
140
  • Europa Universalis III Complete
  • 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
  • Hearts of Iron III Collection
  • Heir to the Throne
  • Impire
  • Europa Universalis IV: Art of War
  • 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
  • Majesty 2 Collection
  • March of the Eagles
  • Crusader Kings II: Sunset Invasion
  • Ancient Space
  • 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
  • Crusader Kings II: Sons of Abraham
  • A Game of Dwarves
  • Crusader Kings II: Sword of Islam
  • Commander: Conquest of the Americas
  • Darkest Hour
  • Deus Vult
  • Dungeonland
  • East India Company
  • East India Company Collection
  • Europa Universalis III Complete
  • Divine Wind
  • Europa Universalis III Complete
Is there any way to do away with/modify the 3 holy sites in order to reform a pagan faith? I don't see it in the defines file.

Did some searching and it seems like it was in CK2, but isn't in CK3... Why not?

Code:
REFORM_RELIGION_MIN_AUTHORITY = 0.5,                    -- Moral authority required to reform a pagan faith
REFORM_RELIGION_MIN_HOLY_SITES = 3,                             -- Number of holy sites you must control to reform a pagan faith
REFORM_RELIGION_PIETY_COST = 750,                               -- Piety cost of reforming a pagan faith


I can't use the bypass command via console.

Secondary question: How/Why is reforming a faith seemingly the only single thing in the entire game I cant even use console to do (via bypass command)? Its not like I'm in ironman mode. Don't see any reason why it needs to be hardcoded in when you are goofing around with mods anyhow.
 
Last edited:
  • 1Love
Reactions:

gazingrhino

Recruit
19 Badges
May 21, 2022
1
1
  • Stellaris: Apocalypse
  • Stellaris: Nemesis
  • Stellaris: Necroids
  • Crusader Kings III: Royal Edition
  • Crusader Kings III
  • Stellaris: Federations
  • Stellaris: Lithoids
  • Stellaris: Ancient Relics
  • Stellaris: Megacorp
  • Stellaris: Distant Stars
  • Pillars of Eternity
  • Stellaris: Humanoids Species Pack
  • Stellaris: Synthetic Dawn
  • Stellaris - Path to Destruction bundle
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Stellaris
So I made a congenital trait, it works but the created trait don't glow like other congenital taits. I think it's my dds file's fault. Can anybody please give me the correct saving format for dds? I'm using Photoshop cc with nvida dds pulgin.
 
  • 1Love
Reactions: