This one is going to be a bit tough because of the following:
it hasn’t happened on pure HPM, meaning I don’t have a save
I can’t reproduce it on my end, I received the report from someone else
It appears that under some conditions eligible colonial countries can be annexed twice, by separate countries, during dismantlement. An example where Dahomey is submitting to both Germany and Italy:
If you look at the event log, you’ll notice that two copies of Ultimatum event in charge of the annexation are being fired on the same day. I asked for & got a game.log to take a closer look at the timeline. During a different dismantlement:
In general the pattern seems to be:
70005 ‘$COUNTRY$ Dismantlement’ fires a lot, whether from the colony decision or the on_actions.txt event pump. It has allow_multiple_instances = no as a partial safety in place.
96096 ‘$COUNTRY_ADJ$ $FROMCOUNTRY$’ => ‘Let $FROMCOUNTRY$ welcome $COUNTRY_ADJ$ rule.’ and 9607 ‘The $COUNTRY_ADJ$ Ultimatum’ are next, but by this point it’s too late: 96096 is the one that offers the option to spend infamy. When a country is making this choice, we don’t want “but has someone else received the same offer at the same time” to be a consideration.
As a proof of concept, I tweaked the option in 96095 to the following:
option = {
name = "EVT96095OPTA"
# N.b. move this up front
random_country = {
limit = {
is_vassal = no
NOT = { has_country_modifier = considering_colonial_offer }
THIS = {
# N.b. new safety
NOT = { has_country_modifier = considering_colonial_offer }
overlord = { has_country_modifier = being_dismantled }
}
OR = {
neighbour = THIS
AND = {
THIS = { num_of_ports = 1 }
num_of_ports = 1
}
}
OR = {
is_greater_power = yes
is_secondary_power = yes
}
OR = {
AND = {
truce_with = FROM
has_country_modifier = dismantling_country
}
AND = {
THIS = { overlord = { has_country_modifier = international_pariah } }
has_country_flag = coalition_member
}
}
}
add_country_modifier = { name = considering_colonial_offer duration = 2 }
random_list = {
25 = { country_event = 96096 }
25 = { country_event = { id = 96096 days = 1 } }
25 = { country_event = { id = 96096 days = 2 } }
25 = { country_event = { id = 96096 days = 3 } }
}
}
random_owned = {
limit = { owner = { NOT = { has_country_flag = colony_to_be_annexed_flag } } }
owner = { set_country_flag = colony_to_be_annexed_flag }
}
random_owned = {
limit = { owner = { NOT = { has_country_modifier = colony_to_be_annexed } } }
owner = { add_country_modifier = { name = colony_to_be_annexed duration = 385 } }
}
# random_owned = {
# limit = { is_core = FROM }
# owner = { all_core = { remove_core = FROM } }
# }
random_owned = {
limit = { owner = { is_vassal = no } }
owner = { FROM = { create_vassal = THIS } }
}
# N.b. put safety in place
random_list = {
10 = { add_country_modifier = { name = considering_colonial_offer duration = 30 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 40 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 50 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 60 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 70 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 80 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 90 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 100 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 110 } }
10 = { add_country_modifier = { name = considering_colonial_offer duration = 120 } }
}
}
The intent is that an eligible colony only extends one offer at a time. This seems to be working on the other player’s end. This is little more than a proof-of-concept however because on paper this can make dismantlements take longer to complete. Let me know what you think.
This one is going to be a bit tough because of the following:
It appears that under some conditions eligible colonial countries can be annexed twice, by separate countries, during dismantlement. An example where Dahomey is submitting to both Germany and Italy:
If you look at the event log, you’ll notice that two copies of Ultimatum event in charge of the annexation are being fired on the same day. I asked for & got a
game.log
to take a closer look at the timeline. During a different dismantlement:In general the pattern seems to be:
70005 ‘$COUNTRY$ Dismantlement’ fires a lot, whether from the colony decision or the
on_actions.txt
event pump. It hasallow_multiple_instances = no
as a partial safety in place.https://github.com/arkhometha/Historical-Project-Mod/blob/09afcba51fb953097dbce5b5c424f87e32ac5cc0/HPM/events/OnAction.txt#L543-L553
however 96095 ‘The Fate of $COUNTRY$’ fires multiple times per eligible colony (that’s the part I can’t reproduce)
96096 ‘$COUNTRY_ADJ$ $FROMCOUNTRY$’ => ‘Let $FROMCOUNTRY$ welcome $COUNTRY_ADJ$ rule.’ and 9607 ‘The $COUNTRY_ADJ$ Ultimatum’ are next, but by this point it’s too late: 96096 is the one that offers the option to spend infamy. When a country is making this choice, we don’t want “but has someone else received the same offer at the same time” to be a consideration.
As a proof of concept, I tweaked the option in 96095 to the following:
The intent is that an eligible colony only extends one offer at a time. This seems to be working on the other player’s end. This is little more than a proof-of-concept however because on paper this can make dismantlements take longer to complete. Let me know what you think.