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

Scottx105

Second Lieutenant
55 Badges
Jul 18, 2015
114
318
  • Cities: Skylines - Natural Disasters
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Europa Universalis 4: Emperor
  • Crusader Kings II: Conclave
  • Prison Architect
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Crusader Kings II: Way of Life
  • Hearts of Iron IV: Together for Victory
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Golden Century
  • Crusader Kings II: Holy Fury
  • Hearts of Iron IV: Death or Dishonor
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Dharma
  • War of the Roses
  • Cities: Skylines
  • Victoria 2
  • 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
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Stellaris: Leviathans Story Pack
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Call to arms event
  • Magicka
  • March of the Eagles
  • Stellaris
  • Europa Universalis IV: Res Publica
  • Cities: Skylines - Snowfall
  • Victoria: Revolutions
  • Cities: Skylines - After Dark
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Crusader Kings II
Hi, this is my first time modding and I've looked through a ton of the files in CK2/common but can't for the life of me find the behaviour that governs how the inheritance law works. Btw when I mean inheritance law, I mean the behaviour that governs the "set_protected_inheritance" behaviour. I'm trying to modify it so when the law is enacted vassals cannot inherit land between separate internal kingdoms within an empire.
 
set_protected_inheritance uses hardcoded logic. To get the behaviour you seek, you need to create a set of events to implement inheritance restrictions, though this could get very messy and the displayed heir in the title and character screens would rather frustratingly not necessarily be the true heir. Alternatively, you could create a new succession law to restrict this kind of inheritance but it would need to be an elective-type law
 
  • 2
Reactions:
I was afraid someone would say something like that... I don't see how an elective system as you described would work. All I can think of is in the event of a characters death with no actual heirs or siblings, grant the province to the vassals king. And in the event disallow external inheritance is not in force just allow the normal rules to apply. Do you happen to know what the event is for when a character dies and the land gets given to the closest relative?
 
Inheritance isn't handled by event. There are on_actions that can be used to fire events when titles change hands, however
 
  • 2
Reactions:
Now I know why nobody has modded this before, why isn't there documentation that clearly outlines what every event ID is. I'd have to spend hours experimenting.. You would have thought the dev's would have put a bit more time into naming stuff properly. Like I've got events here like 8250.. All I can tell is it's a plot event. Aside from that I've no clue what it does.