Hello Modders,
Just thought I would share this as I spent a lot of today trying to figure this out and its actually quite simple once you know how. I'm making a Christmas Mod which needed an event to fire on teh 25th. Tried various things and the thing that works best is this:
In my mod Santa is the head of the Pagan religion but if you switch out pagan for christian it works just as well with the pope.
This basically lets you set a yearly pulse specific to any day of the year. For some reason 20 days meant that the final event fired on the 25th (there are another 2 events in this chain before the player event) but it is consistent.
Using this it would be possible to set a yearly event for all kinds of holidays. Im quite a newbie at modding but Im quite proud of this chain .
Just thought I would share this as I spent a lot of today trying to figure this out and its actually quite simple once you know how. I'm making a Christmas Mod which needed an event to fire on teh 25th. Tried various things and the thing that works best is this:
Code:
character_event = {
id = YULE.200#pulse
hide_window = yes
religion = pagan
trigger = {
controls_religion = yes
NOT = { has_character_flag = cooldown }
month = 11
}
immediate = {
character_event = { id = YULE.201 days = 20 }
set_character_flag = cooldown
}
}
character_event = {
id = YULE.199#cooldown reset
hide_window = yes
religion = pagan
trigger = {
controls_religion = yes
has_character_flag = cooldown
month = 6
}
immediate = {
clr_character_flag = cooldown
}
}
In my mod Santa is the head of the Pagan religion but if you switch out pagan for christian it works just as well with the pope.
This basically lets you set a yearly pulse specific to any day of the year. For some reason 20 days meant that the final event fired on the 25th (there are another 2 events in this chain before the player event) but it is consistent.
Using this it would be possible to set a yearly event for all kinds of holidays. Im quite a newbie at modding but Im quite proud of this chain .
- 1
- 1