Thank you so much for trying atleast.Gona create a new thread about this issue.Well, the method I used is step by step identical to the wiki. I don't find it hard though, but here I can't see what issue you have.
Thank you so much for trying atleast.Gona create a new thread about this issue.Well, the method I used is step by step identical to the wiki. I don't find it hard though, but here I can't see what issue you have.
Now that can't be trueAGOT is overwriting events in the mod file and they still have that event firing on childbirth.
There must be some miscomunication here haha. The popup to name children is hardcoded and NOT a scriptable event.
Yes I imagined it would be, however the problem I am having is that it's not firing at all in my mod.
character_event = {
id = YULE.200#
hide_window = yes
religion = pagan
trigger = {
controls_religion = yes
month = 11
}
immediate = {
character_event = { id = YULE.201 days = 20 }
}
}
character_event = {
id = YULE.201
hide_window = yes
is_triggered_only = yes
immediate = {
any_playable_ruler = { character_event = { id = YULE.202 days = 1 } }
}
}
Wel... that's weird. Maybe report it as a bug? So your playable character is having children and you are unable to name them?
Yes, but i don't see how it can be a bug if AGOT is not having issues![]()
This is province file i modded i didnt used same colour twice so i dont think thats the problem.
Hello community....I have yet another silly question
I wanna make an event that fires on when someone's opinion is lesser than certain value...so how can I make this work as intended?
I made some but I dont think its firing like what I expected please help!
NOT = { opinion = { who = ROOT value = -25 } }
castle = {
# toy_factory
toy_factory = {
desc = toy_factory_desc
trigger = FROM = { has_character_flag = toy_factory_enabled }
gold_cost = 1
build_time = 1
toy_soldier = 1000
tech_growth_modifier = 0.25
}
}
character_event = {
id = YULE.203
desc = YULE.203
is_triggered_only = yes
immediate = {
capital_holding = {
add_building = toy_factory
set_character_flag = toy_factory_enabled
}
}
option = {
name = YULE.203A
trigger = { always = yes
set_character_flag = toy_factory_built
}
}
}
[
First thing: Add 'only_playable = yes' to YULE.200. That will make this whole event chain more efficient.How do I add a cooldown on the following events?
Code:character_event = { id = YULE.200# hide_window = yes religion = pagan trigger = { controls_religion = yes month = 11 } immediate = { character_event = { id = YULE.201 days = 20 } } } character_event = { id = YULE.201 hide_window = yes is_triggered_only = yes immediate = { any_playable_ruler = { character_event = { id = YULE.202 days = 1 } } } }
I tried playing around with flags but just broke it, The problem basically is that YULE.202 fires a second time in january when i dotn want it to
First thing: Add 'only_playable = yes' to YULE.200. That will make this whole event chain more efficient.
Next: A cooldown dould make the event happen on once in December, but it won't accomplish what you actually want (event on Christmas day). Random events are checked every 20 days (in vanilla), not guaranteed to be on a given day of the month or year. December is 31 days long. So YULE.200 will sometimes fire once (in the middle of December), sometimes twice (early & late December). And nothing in this event chain ensures that the final event happens on Dec 25. It's *possible* to get an event to fire on a specific day of the year, but not simple, because you can check the game year and the game month, but not the game day.
First off: 'trigger = FROM = { has_character_flag = toy_factory_enabled }' is wrong. It would need more brackets: 'trigger = { FROM = { has_character_flag = toy_factory_enabled } }'. I've seen you make this error in at least 1 other post. You *always* have to surround complex values in brackets.I need help modding custom buildings in. I want these buildings to only appear when build and they are only build via event. I have come across two problems. This first is localisation conventions, for example in the below screen grab:
View attachment 226927
That should read "Toy Soldiers", a custom troop. I have coded the soldiers exactly like the war elephants in the same file and tried to copy the localization keys but this one is missing, ive got toy_soldier; and toy_soldier_desc, what other strings could i try?
The second question is, how to I hide it till teh event? Im currently using the following:
For the building andCode:castle = { # toy_factory toy_factory = { desc = toy_factory_desc trigger = FROM = { has_character_flag = toy_factory_enabled } gold_cost = 1 build_time = 1 toy_soldier = 1000 tech_growth_modifier = 0.25 } }
Code:character_event = { id = YULE.203 desc = YULE.203 is_triggered_only = yes immediate = { capital_holding = { add_building = toy_factory set_character_flag = toy_factory_enabled } } option = { name = YULE.203A trigger = { always = yes set_character_flag = toy_factory_built } } } [
For the event. This stops it building without the event, however every time I try to move the flag check to "potential" rather than "trigger" it breaks the event so that the event no longer builds it. Anyone got the answer to this one?
character_event = {
id = YULE.205
desc = YULE.205
is_triggered_only = yes
immediate = {
create_character = {
random_traits = no
name = "Elvish Agent"
dynasty = none
religion = pagan
culture = ROOT
female = no
age = 23
attributes = {
martial = 5
}
trait = elusive_shadow
trait = cynical
trait = shrewd
trait = deceitful
trait = ambitious
new_character = {
spawn_unit = {
province = PREV
owner = ROOT
match_character = FROM
match_mult = 0.05
attrition = 1.0
}
}
}
}
option = {
name = YULE.204A
trigger = { always = yes }
}
}
Needs closing bracket for the create_character after 'ambitious'.For example why isnt the option in this event showing up?
Code:character_event = { id = YULE.205 desc = YULE.205 is_triggered_only = yes immediate = { create_character = { random_traits = no name = "Elvish Agent" dynasty = none religion = pagan culture = ROOT female = no age = 23 attributes = { martial = 5 } trait = elusive_shadow trait = cynical trait = shrewd trait = deceitful trait = ambitious new_character = { spawn_unit = { province = PREV owner = ROOT match_character = FROM match_mult = 0.05 attrition = 1.0 } } } } option = { name = YULE.204A trigger = { always = yes } } }
I cant for the lfie of me figure out what is wrong.
but but but...Needs closing bracket for the create_character after 'ambitious'.
Also, see my comments above: the events you've posted here & the other thread will *not* make it happen on Dec 25 each year. And events 199 & 200 will be checked every 20 days for every character to see if they are pagans and if they control their religion, to decide who to fire it for. Very inefficient.
Recommendation: Download 'The Validator' (it has it's own thread here). Use that to check the syntax of your mods. It catches missing brackets and a whole lot more.![]()
Did you try different start dates? Or start a game, save it after a few days, then load it and see what day you get?but but but...
it DOES fire every year on 25th December, every time i test it, for 10 years running it fires on the 25th
Did you try different start dates? Or start a game, save it after a few days, then load it and see what day you get?
castle = {
# toy_factory
toy_factory = {
potential = { FROM = { has_character_flag = toy_factory_enabled } }
desc = toy_factory_desc
gold_cost = 1
build_time = 1
toy_soldier = 1000
tech_growth_modifier = 0.25
}
}
character_event = {
id = YULE.203
desc = YULE.203
is_triggered_only = yes
immediate = {
capital_holding = {
add_building = toy_factory
set_character_flag = toy_factory_enabled
}
}
option = {
name = YULE.203A
trigger = { always = yes }
set_character_flag = toy_factory_built
}
}
character_event = {
id = YULE.205
desc = YULE.205
is_triggered_only = yes
immediate = { }
option = {
name = YULE.203A
trigger = { always = yes }
create_character = {
random_traits = no
name = "Elvish Agent"
dynasty = none
religion = pagan
culture = ROOT
female = no
age = 23
attributes = {
martial = 5
}
trait = elusive_shadow
trait = cynical
trait = shrewd
trait = deceitful
trait = ambitious
}
new_character = {
spawn_unit = {
province = PREV
owner = ROOT
troops = {
reindeer_cavalry = { 10 10 }
}
match_character = FROM
match_mult = 0.05
attrition = 1.0
war = { target = PREVPREV casus_belli = independence }
}
}
}
}
Also Im gonna walk my dog now but this event:
Code:character_event = { id = YULE.205 desc = YULE.205 is_triggered_only = yes immediate = { } option = { name = YULE.203A trigger = { always = yes } create_character = { random_traits = no name = "Elvish Agent" dynasty = none religion = pagan culture = ROOT female = no age = 23 attributes = { martial = 5 } trait = elusive_shadow trait = cynical trait = shrewd trait = deceitful trait = ambitious } new_character = { spawn_unit = { province = PREV owner = ROOT troops = { reindeer_cavalry = { 10 10 } } match_character = FROM match_mult = 0.05 attrition = 1.0 war = { target = PREVPREV casus_belli = independence } } } } }
Why isnt it working as it should? Currently it is spawning the Elvish agent but he doesnt declare war or get an army![]()
Yes, in all the start dates ive tried and every year it fires on the 25th :/
also your Toy Factory doesnt appear with the event:
Toy Factory
EventCode:castle = { # toy_factory toy_factory = { potential = { FROM = { has_character_flag = toy_factory_enabled } } desc = toy_factory_desc gold_cost = 1 build_time = 1 toy_soldier = 1000 tech_growth_modifier = 0.25 } }
Code:character_event = { id = YULE.203 desc = YULE.203 is_triggered_only = yes immediate = { capital_holding = { add_building = toy_factory set_character_flag = toy_factory_enabled } } option = { name = YULE.203A trigger = { always = yes } set_character_flag = toy_factory_built } }
:'( ive been trying this toy factory event for a day now and one of my friends who works ont eh HIP mod tried helping but that didnt resolve it (i think he actually gave me the same code you gave me