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

HREmperor

Colonel
1 Badges
Jun 16, 2015
873
1.229
  • Crusader Kings II
Okay, I messed up somewhere.
http://prntscr.com/7nr48d
<ignore stupid name of mod, just temporary as it has several life and death traits>
Where did I go wrong with this? Also I dont know how to do the boxes for code as done above.

namespace = Trait1
character_event = {
id = Lifemods.001 }
desc = "LFM.001.DESC"
is_triggered_only = yes
trigger = {
piety = -200}
effect = {
NOT = {trait = Anti_Christ}
}
option = {
name = "LFM.001.A"}

* edit to say I noticed I'm missing a }
Oh wait I didn't notice. Your trigger means that any time the game sees that the character has -200 piety, it'll trigger the event. That means it'll keep happening until they gain piety. I think it should be like this:
Code:
namespace = Trait1
character_event = {
    id = Lifemods.001 }
    desc = "LFM.001.DESC"
trigger = {
piety = -200
NOT = {trait = Anti_Christ}
}
effect = {
trait = Anti_Christ
}
option = {
name = "LFM.001.A"}
That'll trigger the event and give the character the trait Anti-Christ if they have -200 piety and don't have it already.
 
Last edited:
  • 1
Reactions:

richvh

Preserver of the Light
63 Badges
Dec 1, 2001
14.691
1.999
Visit site
  • Stellaris: Leviathans Story Pack
  • Pillars of Eternity
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Knights of Pen and Paper 2
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Crusader Kings II: Reapers Due
  • Tyranny: Archon Edition
  • Tyranny: Archon Edition
  • Tyranny: Gold Edition
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Surviving Mars
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Age of Wonders III
  • Age of Wonders: Shadow Magic
  • Age of Wonders
  • Age of Wonders II
  • Crusader Kings II: Jade Dragon
  • Crusader Kings III: Royal Edition
  • 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 IV
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • A Game of Dwarves
  • King Arthur II
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Europa Universalis: Rome
  • Rome Gold
  • Rome: Vae Victis
  • 500k Club
  • Cities: Skylines
Okay, I messed up somewhere.
http://prntscr.com/7nr48d
<ignore stupid name of mod, just temporary as it has several life and death traits>
Where did I go wrong with this? Also I dont know how to do the boxes for code as done above.

namespace = Trait1
character_event = {
id = Lifemods.001 }
desc = "LFM.001.DESC"
is_triggered_only = yes
trigger = {
piety = -200}
effect = {
NOT = {trait = Anti_Christ}
}
option = {
name = "LFM.001.A"}

* edit to say I noticed I'm missing a }
You have an extra } after the event ID line (and are missing one after the end of your option, which is doing nothing.) You don't use effect in events (and wouldn't put a condition in it even if it was allowed.) Your namespace doesn't match the namespace used in your event ID. It's fine to use is_triggered_only with trigger, just be aware that even if the calling event/decision/on_action fires the event, it will abort if the trigger conditions aren't met.
Code tags are done like this: {code}Insert code here{/code} except with [ and ] instead of { and }.

@HREmperor: I think you're forgetting that piety = -200 means piety is AT LEAST -200.
 
  • 1
Reactions:

stedavies112

Sergeant
39 Badges
Jul 1, 2015
94
1
  • Knights of Pen and Paper +1 Edition
  • Europa Universalis IV: Common Sense
  • Ship Simulator Extremes
  • Sengoku
  • Magicka
  • Impire
  • Hearts of Iron III
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • 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: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II
  • Crusader Kings III
  • Prison Architect
  • Crusader Kings II: Holy Fury
  • Shadowrun Returns
  • Crusader Kings II: Jade Dragon
  • Crusader Kings II: Monks and Mystics
  • Tyranny: Archon Edition
  • Crusader Kings II: Reapers Due
  • Stellaris
  • Crusader Kings II: Conclave
  • Crusader Kings II: Horse Lords
  • Humble Paradox Bundle
  • Pillars of Eternity
  • Crusader Kings II: Way of Life
  • Magicka: Wizard Wars Founder Wizard
  • Cities: Skylines
  • War of the Roses
  • Victoria 2
  • Teleglitch: Die More Edition
  • Europa Universalis IV
  • Cities: Skylines Deluxe Edition
You have an extra } after the event ID line (and are missing one after the end of your option, which is doing nothing.) You don't use effect in events (and wouldn't put a condition in it even if it was allowed.) Your namespace doesn't match the namespace used in your event ID. It's fine to use is_triggered_only with trigger, just be aware that even if the calling event/decision/on_action fires the event, it will abort if the trigger conditions aren't met.
Code tags are done like this: {code}Insert code here{/code} except with [ and ] instead of { and }.

@HREmperor: I think you're forgetting that piety = -200 means piety is AT LEAST -200.

Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001
    desc = "LFM.001.DESC"
trigger = {
piety = -200
NOT = {trait = Anti_Christ}
}
effect = {
trait = Anti_Christ
}
option = {
name = "LFM.001.A"} }
So would this be right?
 

TruckFeet

First Lieutenant
31 Badges
Jun 24, 2014
208
225
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Reapers Due
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Crusader Kings II
  • Victoria: Revolutions
  • Magicka
  • 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
  • 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
  • Europa Universalis IV: Rights of Man
  • Crusader Kings III
  • Stellaris Sign-up
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • 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
  • Europa Universalis IV: El Dorado
  • Victoria 2
Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001
    desc = "LFM.001.DESC"
trigger = {
piety = -200
NOT = {trait = Anti_Christ}
}
effect = {
trait = Anti_Christ
}
option = {
name = "LFM.001.A"} }
So would this be right?
Use NOT = { piety = -200 }, or else it will go off when the character has more than -200 piety.
 

richvh

Preserver of the Light
63 Badges
Dec 1, 2001
14.691
1.999
Visit site
  • Stellaris: Leviathans Story Pack
  • Pillars of Eternity
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Knights of Pen and Paper 2
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Crusader Kings II: Reapers Due
  • Tyranny: Archon Edition
  • Tyranny: Archon Edition
  • Tyranny: Gold Edition
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Surviving Mars
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Age of Wonders III
  • Age of Wonders: Shadow Magic
  • Age of Wonders
  • Age of Wonders II
  • Crusader Kings II: Jade Dragon
  • Crusader Kings III: Royal Edition
  • 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 IV
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • A Game of Dwarves
  • King Arthur II
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Europa Universalis: Rome
  • Rome Gold
  • Rome: Vae Victis
  • 500k Club
  • Cities: Skylines
Close, but there shouldn't be an effect section, and the trait = Anti_Christ goes in the option section. Also, do you really want saints to get the Anti_Christ trait? I think you want your trigger to be NOT = { piety = -200 } (piety is less than -200); as it is anyone with piety of -200 or above will get the trait.

If this event isn't being called from anywhere and you want it to fire automatically, you should have a mean_time_to_happen section.
 

HREmperor

Colonel
1 Badges
Jun 16, 2015
873
1.229
  • Crusader Kings II
Close, but there shouldn't be an effect section, and the trait = Anti_Christ goes in the option section. Also, do you really want saints to get the Anti_Christ trait? I think you want your trigger to be NOT = { piety = -200 } (piety is less than -200); as it is anyone with piety of -200 or above will get the trait.

If this event isn't being called from anywhere and you want it to fire automatically, you should have a mean_time_to_happen section.
If there's no MTTH, wouldn't it fire instantly?
 

stedavies112

Sergeant
39 Badges
Jul 1, 2015
94
1
  • Knights of Pen and Paper +1 Edition
  • Europa Universalis IV: Common Sense
  • Ship Simulator Extremes
  • Sengoku
  • Magicka
  • Impire
  • Hearts of Iron III
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • 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: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II
  • Crusader Kings III
  • Prison Architect
  • Crusader Kings II: Holy Fury
  • Shadowrun Returns
  • Crusader Kings II: Jade Dragon
  • Crusader Kings II: Monks and Mystics
  • Tyranny: Archon Edition
  • Crusader Kings II: Reapers Due
  • Stellaris
  • Crusader Kings II: Conclave
  • Crusader Kings II: Horse Lords
  • Humble Paradox Bundle
  • Pillars of Eternity
  • Crusader Kings II: Way of Life
  • Magicka: Wizard Wars Founder Wizard
  • Cities: Skylines
  • War of the Roses
  • Victoria 2
  • Teleglitch: Die More Edition
  • Europa Universalis IV
  • Cities: Skylines Deluxe Edition
If there's no MTTH, wouldn't it fire instantly?
It does, I get about 100 blank dialogue boxes.
Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001 
    desc = "LFM.001.DESC"
trigger = {
NOT = {piety = -200}
NOT = {trait = Anti_Christ}
mean_time_to_happen = {
    months = 1}
{trait = Anti_Christ}
option = {
name = "LFM.001.A"} }
Is this using the meant to happen time correctly?
 

HREmperor

Colonel
1 Badges
Jun 16, 2015
873
1.229
  • Crusader Kings II
I think it should look like this:
Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001
    desc = "LFM.001.DESC"
trigger = {
NOT = {piety = -200}
NOT = {trait = Anti_Christ}
}

mean_time_to_happen = {
  months = 1
}

option = {
name = "LFM.001.A"} }
add_trait = Anti_Christ
}
}
 

stedavies112

Sergeant
39 Badges
Jul 1, 2015
94
1
  • Knights of Pen and Paper +1 Edition
  • Europa Universalis IV: Common Sense
  • Ship Simulator Extremes
  • Sengoku
  • Magicka
  • Impire
  • Hearts of Iron III
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • 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: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II
  • Crusader Kings III
  • Prison Architect
  • Crusader Kings II: Holy Fury
  • Shadowrun Returns
  • Crusader Kings II: Jade Dragon
  • Crusader Kings II: Monks and Mystics
  • Tyranny: Archon Edition
  • Crusader Kings II: Reapers Due
  • Stellaris
  • Crusader Kings II: Conclave
  • Crusader Kings II: Horse Lords
  • Humble Paradox Bundle
  • Pillars of Eternity
  • Crusader Kings II: Way of Life
  • Magicka: Wizard Wars Founder Wizard
  • Cities: Skylines
  • War of the Roses
  • Victoria 2
  • Teleglitch: Die More Edition
  • Europa Universalis IV
  • Cities: Skylines Deluxe Edition
I think it should look like this:
Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001
    desc = "LFM.001.DESC"
trigger = {
NOT = {piety = -200}
NOT = {trait = Anti_Christ}
}

mean_time_to_happen = {
  months = 1
}

option = {
name = "LFM.001.A"} }
add_trait = Anti_Christ
}
}

I applied your code but I'm still getting the same bug. Blank boxes and many of them all when having positive piety.
 

richvh

Preserver of the Light
63 Badges
Dec 1, 2001
14.691
1.999
Visit site
  • Stellaris: Leviathans Story Pack
  • Pillars of Eternity
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Knights of Pen and Paper 2
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Crusader Kings II: Reapers Due
  • Tyranny: Archon Edition
  • Tyranny: Archon Edition
  • Tyranny: Gold Edition
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Surviving Mars
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Age of Wonders III
  • Age of Wonders: Shadow Magic
  • Age of Wonders
  • Age of Wonders II
  • Crusader Kings II: Jade Dragon
  • Crusader Kings III: Royal Edition
  • 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 IV
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • A Game of Dwarves
  • King Arthur II
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Europa Universalis: Rome
  • Rome Gold
  • Rome: Vae Victis
  • 500k Club
  • Cities: Skylines
I think it should look like this:
Still not right.
Code:
namespace = Lifemods
character_event = {
    id = Lifemods.001
    desc = "LFM.001.DESC"
    trigger = {
        NOT = {piety = -200}
        NOT = {trait = Anti_Christ}
    }

    mean_time_to_happen = {
      months = 1
    }

    option = {
        name = "LFM.001.A"
        add_trait = Anti_Christ
    }
}
You also need localization for Anti_Christ and Anti_Christ_desc.
 

richvh

Preserver of the Light
63 Badges
Dec 1, 2001
14.691
1.999
Visit site
  • Stellaris: Leviathans Story Pack
  • Pillars of Eternity
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Knights of Pen and Paper 2
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Crusader Kings II: Reapers Due
  • Tyranny: Archon Edition
  • Tyranny: Archon Edition
  • Tyranny: Gold Edition
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Surviving Mars
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Age of Wonders III
  • Age of Wonders: Shadow Magic
  • Age of Wonders
  • Age of Wonders II
  • Crusader Kings II: Jade Dragon
  • Crusader Kings III: Royal Edition
  • 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 IV
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • A Game of Dwarves
  • King Arthur II
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Europa Universalis: Rome
  • Rome Gold
  • Rome: Vae Victis
  • 500k Club
  • Cities: Skylines
Anti_Christ is the trait, you need localizations for traits and the descriptions of traits. You put these in your .csv file in localisation/.
Something like:
Code:
Anti_Christ;Anti-Christ;;;;;;;;;;;;x
Anti_Christ_desc;This person is believed to be the Anti-Christ incarnate.;;;;;;;;;;;;;x