I'm in the process of modifying the plot_kill_character plot so that a player is given a more reasonable choice of murder victims instead of just getting three random names from his realm on your hit list.
It appears the cause of this behaviour is that the bit of code that controls who is an eligible target includes a section titled "Go nuts" that allows a lunatic character or a player's character to target anyone. (The other unproblematic sections target your spouse's lover or anyone that is the first heir to a title that you/your spouse/your kid is a pretender to). The problem with this is that instead of letting a player plot against anyone it just picks three of the valid targets to offer you, and when the valid targets are anyone in your realm the chance of getting the right victim offered to you are pretty low.
The first change I made was to stop the Go nuts option from applying to the player. With this change the Duke of Bohemia's hit list just has the nephew who would inherit the county of Brno ahead of the Duke; and the rubbish Byzantine heir can target his two kid brothers who will share the emperors demesne under gavelkind.
Next I added the ability to target your liege and made it so that the block that allowed mothers to plot against those who would inherit ahead of their kids to also allow fathers to plot if not AI.
If you want to see the lines I have changed, they are the ones that have too little indentation.
TO DO:
plot to murder title holders that you or your wife/children are heir to.
split this plot into one plot for each cause to make it more manageable
allow the ai to use these new plots without breaking Europe.
It appears the cause of this behaviour is that the bit of code that controls who is an eligible target includes a section titled "Go nuts" that allows a lunatic character or a player's character to target anyone. (The other unproblematic sections target your spouse's lover or anyone that is the first heir to a title that you/your spouse/your kid is a pretender to). The problem with this is that instead of letting a player plot against anyone it just picks three of the valid targets to offer you, and when the valid targets are anyone in your realm the chance of getting the right victim offered to you are pretty low.
The first change I made was to stop the Go nuts option from applying to the player. With this change the Duke of Bohemia's hit list just has the nephew who would inherit the county of Brno ahead of the Duke; and the rubbish Byzantine heir can target his two kid brothers who will share the emperors demesne under gavelkind.
Next I added the ability to target your liege and made it so that the block that allowed mothers to plot against those who would inherit ahead of their kids to also allow fathers to plot if not AI.
Code:
# Get a character killed
plot_kill_character = {
type = realm_characters
plot = yes
intrigue_plot = yes
# Plotter scope
potential = {
prisoner = no
age = 16
independent = no
NOT = { trait = incapable }
NOT = {
AND = {
ai = yes
trait = honest
}
}
NOT = {
AND = {
ai = yes
trait = kind
}
}
OR = {
ai = no # Human
# Pretender to a title
any_pretender_title = {
always = yes
}
# Female character's child is pretender to a title
AND = {
is_female = yes
any_child = {
any_pretender_title = {
always = yes
}
}
}
# Spouse is pretender to a title
spouse = {
any_pretender_title = {
always = yes
}
}
# Is nuts...
trait = lunatic
}
}
# Target character scope
allow = {
OR = {
#allow the player to kill his liege
AND = {
overlord_of = FROM
ai = no # Human
}
FROM = {
OR = {
# Get rid of the current heir
any_pretender_title = {
current_heir = { character = ROOT }
FROM = {
OR = {
NOT = { any_child = { character = ROOT } }
AND = {
any_child = { character = ROOT }
OR = {
AND = {
OR = {
trait = cruel
trait = ambitious
}
FROM = { NOT = { opinion = { who = ROOT value = 0 } } }
}
AND = {
OR = {
trait = arbitrary
trait = cynical
}
FROM = { NOT = { opinion = { who = ROOT value = -25 } } }
}
FROM = { NOT = { opinion = { who = ROOT value = -75 } } }
}
}
}
}
}
# Female character gets rid of the current heir to a title her child is pretender to
AND = {
OR = {
is_female = yes
ai = no # Human fathers can also get rid of current heir
}
any_child = {
any_pretender_title = {
current_heir = { character = ROOT }
}
}
NOT = { ROOT = { is_close_relative = FROM } }
FROM = { NOT = { opinion = { who = ROOT value = 0 } } }
}
# Get rid of the current heir to a title the character's spouse is a pretender to
AND = {
spouse = {
any_pretender_title = {
current_heir = { character = ROOT }
}
}
NOT = { ROOT = { is_close_relative = FROM } }
FROM = { NOT = { opinion = { who = ROOT value = 0 } } }
}
# A lover of spouse...
spouse = {
has_lover = yes
lover = {
character = ROOT
}
FROM = { NOT = { opinion = { who = ROOT value = 0 } } }
}
# Go nuts...
AND = {
same_liege = ROOT
OR = {
trait = lunatic
trait = possessed
#ai = no # Human
}
}
}
}
}
}
chance = {
factor = 1
modifier = {
factor = 0.01
FROM = { trait = content }
any_pretender_title = {
current_heir = { character = ROOT }
}
}
modifier = {
factor = 2.0
FROM = { trait = envious }
any_pretender_title = {
current_heir = { character = ROOT }
}
}
modifier = {
factor = 0.5
their_opinion = { who = FROM value = 50 }
}
modifier = {
factor = 0
their_opinion = { who = FROM value = 80 }
}
modifier = {
factor = 1.5
NOT = { their_opinion = { who = FROM value = -25 } }
}
modifier = {
factor = 1.5
NOT = { their_opinion = { who = FROM value = -50 } }
}
modifier = {
factor = 2.0
NOT = { their_opinion = { who = FROM value = -75 } }
}
modifier = {
factor = 2.0
FROM = { trait = deceitful }
}
modifier = {
factor = 3.0
FROM = { trait = ambitious }
}
}
success = {
tooltip = { is_alive = no }
FROM = { has_character_flag = plot_murderer }
has_character_flag = was_murdered_by_plot
}
abort = {
is_alive = no
}
abort_effect = {
FROM = {
# Clear flags
hidden_tooltip = {
clr_character_flag = plot_kill_character_decision_50_taken
clr_character_flag = plot_kill_character_decision_75_taken
clr_character_flag = plot_kill_character_decision_100_taken
clr_character_flag = event7040
}
}
}
effect = {
hidden_tooltip = {
death = yes
}
FROM = {
change_intrigue = 1
# Clear flags
hidden_tooltip = {
clr_character_flag = plot_murderer
clr_character_flag = plot_kill_character_decision_50_taken
clr_character_flag = plot_kill_character_decision_75_taken
clr_character_flag = plot_kill_character_decision_100_taken
clr_character_flag = event7040
}
}
}
}
TO DO:
plot to murder title holders that you or your wife/children are heir to.
split this plot into one plot for each cause to make it more manageable
allow the ai to use these new plots without breaking Europe.