PDA

View Full Version : Crusader Kings II - Mod General



Monk
06-06-2012, 11:04
Just thought i'd make this thread for us modders to talk about various aspects of modding crusader kings II. Along with answering any questions that anyone might have, it can serve as a show off thread where we talk about what we're currently modding into ours games. I suppose I'll start, here's what I'm working on currently:

https://i182.photobucket.com/albums/x301/swcsalha/joan2.jpg

I have three narrative arcs planned to be implemented, this one will be the first and as they say big things have small beginnings. This narrative event chain has a chance of becoming triggered when one of your demesne provinces suffers either the high tax modifier, thieves' guild, or has a revolt risk of 5 or above.

You start by dealing with peasants not wanting to work your land (a direct violation of the very idea of feudalism, after all) and will soon meet the "Joan of Arc" character I have planned for my mod. How she reacts to you as a player is entirely dependent on how you deal with the problem as it evolves.

Coding the syntax was especially annoying, even more so than the first event I did due to how intricate i wanted to make the event (giving traits, adding province modifiers, ect). I'm quite grateful all of the Crusader kings II files are text based and easy to fix should errors arise. Because they do. Often. I'm really excited to code more of this event line.

Kekvit Irae
06-06-2012, 12:33
This has given me a good idea for a History of the World, Part I mod

Monk
06-06-2012, 13:07
This has given me a good idea for a History of the World, Part I mod

That's nothing, you should have seen the first version - I had to tone down the humor due to the event windows not scaling to your localisation of options. :laugh4:

Kekvit Irae
06-06-2012, 14:35
That's nothing, you should have seen the first version - I had to tone down the humor due to the event windows not scaling to your localisation of options. :laugh4:

We should collaborate and make a parody mod. :3

Ishmael
06-07-2012, 02:37
I feel somewhat embarrassed at having to ask, but is there a save game folder anywhere? I just want to alter a provinces culture in a single game only, so that my Khan of Ulster can convert the rest of Ireland to the Mongol culture (massively OP? Yes. Fun though :beam:).

Kekvit Irae
06-07-2012, 04:25
I feel somewhat embarrassed at having to ask, but is there a save game folder anywhere? I just want to alter a provinces culture in a single game only, so that my Khan of Ulster can convert the rest of Ireland to the Mongol culture (massively OP? Yes. Fun though :beam:).

Assuming you're not on an OS that sucks, your save games will be in your My Documents/Paradox Interactive/Crusader Kings II/ folder

Ishmael
06-07-2012, 04:28
Thanks! Now for the next problem - is there a simple way to edit .ck2 files?

Beskar
06-07-2012, 05:20
notepad, but that can be.. very buggy due to the large file sizes. So get notepad++

For quickly finding your character do a search for "player = yes", though if you other random characters, use "charinfo" console game in-game to get the character id. Another search is to search via title so the duke of york holder would be d_york =

Monk
06-07-2012, 06:00
notepad, but that can be.. very buggy due to the large file sizes. So get notepad++

For quickly finding your character do a search for "player = yes", though if you other random characters, use "charinfo" console game in-game to get the character id. Another search is to search via title so the duke of york holder would be d_york =

This. Saves are ridiculously huge. They are essentially all of the history files combined with the landed_titles file. If you don't search for specific variables you'll likely go insane trying to sort through them yourself. When it comes to file editing or new coding notepad++ has been my tool of choice for bigger files and error hunting. Can't recommend it more.

Kekvit Irae
06-07-2012, 08:39
Well I've finally hit a wall. I wanted to add in a new councilor to my mod. Edited all the files, put the files in the right places, and everything works fine. Unfortunately, when I place my new councilor on the map, I get a CTD. Searching around reveals that the xsc and xac files are part of a modeling program called Emotion FX, and simply renaming the spymaster model files to what I want wont work. Did I mention that Emotion FX uses proprietary software and costs 10,000 dollars a license?

I can just move all the new actions over to the old councilors, but meh. I wanted my seamstress!

Monk
06-07-2012, 09:45
Well I've finally hit a wall. I wanted to add in a new councilor to my mod. Edited all the files, put the files in the right places, and everything works fine. Unfortunately, when I place my new councilor on the map, I get a CTD. Searching around reveals that the xsc and xac files are part of a modeling program called Emotion FX, and simply renaming the spymaster model files to what I want wont work. Did I mention that Emotion FX uses proprietary software and costs 10,000 dollars a license?

I can just move all the new actions over to the old councilors, but meh. I wanted my seamstress!

Yikes. Well good to know some limitations before i spend some time going in that direction. I actually had a few ideas myself, a little disappointed I won't be able to see those realized. Oh well. Back to population event coding :sad3:

edit: Also having a :daisy: of a time striking a good balance for Iberia. While i have it to where it's not so hopeless for the northern kingdoms currently, it feels like the AI weights holy wars way too heavily as that's all it ever does. All the time. It doesn't seem able to cope with the new mechanics of religious defense. It makes trying to balance areas of religious tension (any place where Islam/Christianity meet) incredibly hard.

Secura
06-07-2012, 10:06
Well I've finally hit a wall. I wanted to add in a new councilor to my mod. Edited all the files, put the files in the right places, and everything works fine. Unfortunately, when I place my new councilor on the map, I get a CTD. Searching around reveals that the xsc and xac files are part of a modeling program called Emotion FX, and simply renaming the spymaster model files to what I want wont work. Did I mention that Emotion FX uses proprietary software and costs 10,000 dollars a license?

I can just move all the new actions over to the old councilors, but meh. I wanted my seamstress!

I'm unsure if you have played the Game of Thrones mod for CK2, but adding another role to the Council should be possible without the need for expensive software; that mod added Castellans/Hand of the King as a sixth member, which combined abilities from the other roles (mainly the Steward and Chancellor, I think).

I'd be interested to see what this seamstress was capable of (and why her sewing led to a council place!) :3

Ishmael
06-07-2012, 10:17
I'd be interested to see what this seamstress was capable of (and why her sewing led to a council place!) :3

Anybody else thinking Terry Pratchett here? :beam:

Kekvit Irae
06-07-2012, 11:06
I'm unsure if you have played the Game of Thrones mod for CK2, but adding another role to the Council should be possible without the need for expensive software; that mod added Castellans/Hand of the King as a sixth member, which combined abilities from the other roles (mainly the Steward and Chancellor, I think).

I'd be interested to see what this seamstress was capable of (and why her sewing led to a council place!) :3

I'll need to reverse engineer it then and see what the hell they did.

The seamstress was designed to act like the court bishop's inquisition, only you can convert counties and characters to your culture. Sure beats having to wait decades for a county to convert on its own.


EDIT: BINGO! Found in the Avatars.gfx file.

EMFXActorType = {
name = "westerngfx_job_castellan"
actorfile = "gfx\models\Mapindicators\Western_Chancellor.xac"

idle = "gfx\models\Mapindicators\Western_Chancellor_Idle.xsm"
scale = 1.0f
}

rickinator9
06-08-2012, 11:31
Kekvit Irae

As your mod focuses at the more female aspects of CKII, you could try to make women generals. You could also make an event where, if woman have been on the throne for a long time, you make succession cognatic.

Monk
06-08-2012, 14:40
About 2 hours coding this morning has turned up 5 new events. A few of these i probably won't implement but overall this is the direction i'm taking my mod. More Events for the player that allow direct interaction with his/her subjects. :yes:

Some examples...

https://i.imgur.com/yu0Te.jpg
https://i.imgur.com/qCm7t.jpg


I tried to focus on events that I haven't personally seen before, but I'm sure there's probably going to be some overlap with what paradox has already done and what I'm planning. Nearly all of these events either allow you a small chance to gain traits, or apply provincial modifiers to your demesne as a direct result of your actions. I've tried to strike a good balance between personal actions and provincial actions, and not have an entire populace get upset if there isn't reason to.

rickinator9
06-08-2012, 15:06
I would love an event in the style of Barbarossa drowns.

Monk
06-08-2012, 15:40
I would love an event in the style of Barbarossa drowns.

:laugh4:

Oh man that's something I have do now. Won't be too hard to do either. Most of my events are tagged to trigger based on various actions, most of which require you to be at peace, or when your character is NOT in command of an army. A "player has drowned!" event would consequently require those variables changed to yes and allow random chance for death. Actually.. one moment..



#Barbarossa Death
character_event = {
id = 2000007
desc = EVTDESC2000007
picture = GFX_evt_crusaders
is_ruler = yes
only_playable = yes
capable_only = yes
trigger = {
age = 20
is_ill = no
war = yes
in_command = yes
NOT = {
has_character_flag = barbarossa_drowns
}
}
immediate = {
set_character_flag = barbarossa_drowns
}
mean_time_to_happen = {
months = 6
}
option = {
name = EVTOPTA2000007
prestige = 15
random = {
chance = 25
death = {
death_reason = death_battle
}
}
}
option = {
name = EVTOPTB2000007
if = {
limit = {
NOT = {
trait = craven
}
}
add_trait = craven
hidden_tooltip = {
character_event = {
id = 38257
# Notify craven
}
}
}
}
}

Here's an event just like you outlined rick! It requires the character to be both at war AND currently leading troops. It's mean time to happen is an average time to expect this event to fire once all triggers have been met, i set it to 6 months for demonstration purposes, but you'd probably want to mess with that yourself. Unless you wanted every character you play to face the peril of the river. I also included a character flag, which applies immediately upon firing. Note I also defined in the triggers that, if the character s to see this event, they CANNOT have that flag. Which basically just means it's a once in a life-time event.

I also took a bit of liberties with the second option. Who wouldn't want to avoid any chance of death and game the system? Well, your troops might think less of you and think you're a coward, that's why.

The event id can be whatever you want, for the purposes of my mod I am using 2,000,000 as a starting base as to not interact with any of paradox's events.

Kekvit Irae
06-08-2012, 16:56
I've ran into a problem with letters. When I try to use my steward to convert a county's culture, I get this letter on success:

http://i49.tinypic.com/2qluyvq.png

A little help here?

job_steward.txt

character_event = {
id = seam900
title = "EVTNAME_seam900.1"
desc = "EVTDESC_seam900.1"
picture = GFX_evt_market

capable_only = yes
prisoner = no

trigger = {
has_job_action = action_flattermerchant
NOT = { location = { culture = ROOT } }
}


mean_time_to_happen = {
months = 20
modifier = {
factor = 0.5
location = { religion_group = ROOT }
}
modifier = {
factor = 1.25
NOT = { stewardship = 2 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 3 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 4 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 5 }
}
modifier = {
factor = 0.75
stewardship = 10
}
modifier = {
factor = 0.75
stewardship = 11
}
modifier = {
factor = 0.75
stewardship = 12
}
modifier = {
factor = 0.75
stewardship = 13
}
}

option = {
name = "EVTOPTA_seam900.1"
prestige = 10
location = { culture = ROOT }
liege = {
letter_event = {
id = seam20000.1
tooltip = EVTTOOLTIP_seam20000.1
}
hidden_tooltip = {
if = {
limit = {
top_liege = {
NOT = { character = PREV }
culture = ROOT
}
}
top_liege = { letter_event = { id = seam20001.1 } }
}
}
}
}
}

# 20000: The Lord Spiritual informs his liege of the conversion
letter_event = {
id = seam20000.1
desc = "EVTDESC_seam20000.1"

is_triggered_only = yes

option = {
name = "EVTOPTA_seam20000.1"
prestige = 15
if = {
liege = {
opinion = {
modifier = opinion_converted_province
who = ROOT
months = 24
}
}
}
}
}

# 20001: Informs top liege
letter_event = {
id = seam20001.1
desc = "EVTDESC_seam20001.1"

is_triggered_only = yes

option = {
name = "EVTOPTA_seam20001.1"
}
}

culture.csv

EVTNAME_seam900.1;County Culture Converted;;;;;;;;;;;;;x
EVTDESC_seam900.1;The people in [Root.Location.GetName], or, at least, most of them, have embraced the [Root.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam900.1;My hard work has paid off!;;;;;;;;;;;;;x
EVTTOOLTIP_seam20000.1;Send a letter to my liege!;;;;;;;;;;;;;x
EVTDESC_seam20000.1;My liege, I am pleased to report the success of my mission to [From.Location.GetName]. The majority of the population have been converted to the [From.Culture.GetName] culture!\n\n[From.GetTitledName];;;;;;;;;;;;;x
EVTOPTA_seam20000.1;That's haute.;;;;;;;;;;;;;x
EVTDESC_seam20001.1;My [Root.GetTitle], I am pleased to report the success of my mission to [From.Location.GetName]. The majority of the population have been converted to the [From.Culture.GetName] culture!\n\n[From.GetTitledName]
EVTOPTA_seam20001.1;That's haute.;;;;;;;;;;;;;x
EVTNAME_seam901.1;Subject Culture Converted;;;;;;;;;;;;;x
EVTDESC_seam901.1;Due to my tiredless efforts, a humble subject in [Root.Location.GetName] has embraced the [Root.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam901.1;No one can resist the haute culture!;;;;;;;;;;;;;x
EVTTOOLTIP_seam20010.1;[This.GetTitledName] embraces the [Root.Culture.GetName] culture;;;;;;;;;;;;;x
EVTDESC_seam20010.1;The [From.GetJobTitle] of [From.Host.PrimaryTitle.GetName], [From.GetTitledName], has strongly influenced me and I have decided to convert to the [From.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam20010.1;I will truly embrace the [From.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTDESC_seam20011.1;My liege, I am pleased to report that your errant subject, [From.GetTitledName], has converted to the [Root.Culture.GetName] culture.;;;;;;;;;;;;;x
EVTOPTA_seam20011.1;But how does [From.GetPossPronoun] rate on Haute Or Not?;;;;;;;;;;;;;x
EVTDESC_seam20012.1;My liege, after being convinced by the Chancellor from another province, I have decided to convert to the [From.Culture.GetName] culture!\n\nYour humble servant,\n[From.GetTitledName];;;;;;;;;;;;;x
EVTOPTA_seam20012.1;Good!;;;;;;;;;;;;;x
EVTOPTB_seam20012.1;Who dares lead my subjects astray like this!;;;;;;;;;;;;;x
action_flattermerchant;Flatter Merchants;;;;;;;;;;;;;x
action_flatternoble;Flatter Nobles;;;;;;;;;;;;;x
action_flattermerchant_desc;Flatter merchants to convince them that your culture is more haute than theirs.;;;;;;;;;;;;;x
action_flatternoble_desc;Flatter nobles to convince them that your culture is more haute than theirs.;;;;;;;;;;;;;x

Monk
06-08-2012, 17:48
Your event ids should be whole numbers. The inclusion of the . and the letters is what's giving the event fits when it tries to parse the file and dump it into the game engine. You were also missing a separater value in the localisation file which was causing further issues. I'm afraid it's difficult for me to properly troubleshoot the file, as I lack the on action commands that you've plugged in and thus my attempts get strange behavior no matter what I do. However, try this:


EVTNAME_seam900.1;County Culture Converted;;;;;;;;;;;;;x
EVTDESC_seam900.1;The people in [Root.Location.GetName], or, at least, most of them, have embraced the [Root.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam900.1;My hard work has paid off!;;;;;;;;;;;;;x
EVTTOOLTIP_seam20000.1;Send a letter to my liege!;;;;;;;;;;;;;x
EVTDESC_seam20000.1;My liege, I am pleased to report the success of my mission to [From.Location.GetName]. The majority of the population have been converted to the [From.Culture.GetName] culture!\n\n[From.GetTitledName];;;;;;;;;;;;;x
EVTOPTA_seam20000.1;That's haute.;;;;;;;;;;;;;x
EVTDESC_seam20001.1;My [Root.GetTitle], I am pleased to report the success of my mission to [From.Location.GetName]. The majority of the population have been converted to the [From.Culture.GetName] culture!\n\n[From.GetTitledName];;;;;;;;;;;;;x
EVTOPTA_seam20001.1;That's haute.;;;;;;;;;;;;;x
EVTNAME_seam901.1;Subject Culture Converted;;;;;;;;;;;;;x
EVTDESC_seam901.1;Due to my tiredless efforts, a humble subject in [Root.Location.GetName] has embraced the [Root.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam901.1;No one can resist the haute culture!;;;;;;;;;;;;;x
EVTTOOLTIP_seam20010.1;[This.GetTitledName] embraces the [Root.Culture.GetName] culture;;;;;;;;;;;;;x
EVTDESC_seam20010.1;The [From.GetJobTitle] of [From.Host.PrimaryTitle.GetName], [From.GetTitledName], has strongly influenced me and I have decided to convert to the [From.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTOPTA_seam20010.1;I will truly embrace the [From.Culture.GetName] culture!;;;;;;;;;;;;;x
EVTDESC_seam20011.1;My liege, I am pleased to report that your errant subject, [From.GetTitledName], has converted to the [Root.Culture.GetName] culture.;;;;;;;;;;;;;x
EVTOPTA_seam20011.1;But how does [From.GetPossPronoun] rate on Haute Or Not?;;;;;;;;;;;;;x
EVTDESC_seam20012.1;My liege, after being convinced by the Chancellor from another province, I have decided to convert to the [From.Culture.GetName] culture!\n\nYour humble servant,\n[From.GetTitledName];;;;;;;;;;;;;x
EVTOPTA_seam20012.1;Good!;;;;;;;;;;;;;x
EVTOPTB_seam20012.1;Who dares lead my subjects astray like this!;;;;;;;;;;;;;x
action_flattermerchant;Flatter Merchants;;;;;;;;;;;;;x
action_flatternoble;Flatter Nobles;;;;;;;;;;;;;x
action_flattermerchant_desc;Flatter merchants to convince them that your culture is more haute than theirs.;;;;;;;;;;;;;x
action_flatternoble_desc;Flatter nobles to convince them that your culture is more haute than theirs.;;;;;;;;;;;;;x


character_event = {
id = 900000
title = "EVTNAME_seam900.1"
desc = "EVTDESC_seam900.1"
picture = GFX_evt_market

capable_only = yes
prisoner = no

trigger = {
has_job_action = action_flattermerchant
NOT = { location = { culture = ROOT } }
}


mean_time_to_happen = {
months = 20
modifier = {
factor = 0.5
location = { religion_group = ROOT }
}
modifier = {
factor = 1.25
NOT = { stewardship = 2 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 3 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 4 }
}
modifier = {
factor = 1.25
NOT = { stewardship = 5 }
}
modifier = {
factor = 0.75
stewardship = 10
}
modifier = {
factor = 0.75
stewardship = 11
}
modifier = {
factor = 0.75
stewardship = 12
}
modifier = {
factor = 0.75
stewardship = 13
}
}

option = {
name = "EVTOPTA_seam900.1"
prestige = 10
location = { culture = ROOT }
liege = {
letter_event = {
id = 200001
tooltip = EVTTOOLTIP_seam20000.1
}
hidden_tooltip = {
if = {
limit = {
top_liege = {
NOT = { character = PREV }
culture = ROOT
}
}
top_liege = { letter_event = { id = 200011 } }
}
}
}
}
}

# 20000: The Lord Spiritual informs his liege of the conversion
letter_event = {
id = 200001
desc = "EVTDESC_seam20000.1"

is_triggered_only = yes

option = {
name = "EVTOPTA_seam20000.1"
prestige = 15
if = {
liege = {
opinion = {
modifier = opinion_converted_province
who = ROOT
months = 24
}
}
}
}
}

# 20001: Informs top liege
letter_event = {
id = 200011
desc = "EVTDESC_seam20001.1"

is_triggered_only = yes

option = {
name = "EVTOPTA_seam20001.1"
}
}

All i did was change each event ID to be a whole number and take out the "seam" from each entry. I also changed the personal character event to be an id of 900,000, as i am fairly certain the base 900 is taken. I also added in the missing seperation into your localisation. Should make a bit more sense now.

Lemme know if that helps.

Kekvit Irae
06-08-2012, 19:17
Your event ids should be whole numbers. The inclusion of the . and the letters is what's giving the event fits when it tries to parse the file and dump it into the game engine. You were also missing a separater value in the localisation file which was causing further issues. I'm afraid it's difficult for me to properly troubleshoot the file, as I lack the on action commands that you've plugged in and thus my attempts get strange behavior no matter what I do. However, try this:


All i did was change each event ID to be a whole number and take out the "seam" from each entry. I also changed the personal character event to be an id of 900,000, as i am fairly certain the base 900 is taken. I also added in the missing seperation into your localisation. Should make a bit more sense now.

Lemme know if that helps.

The id was the same format used in my heretic removal portion, as well as a few other mods I've come across, all with no problem. I don't know what's different with this.

hereticremoval.csv

CODE;ENGLISH;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTNAME_HR567890.1;Heretic Stronghold Removed;Conversion religieuse d’un comté;Grafschaftsreligion konvertiert;;Condado convertido;;;;;;;;;x
EVTDESC_HR567890.1;I have forcefully removed the local heretic stronghold in [Root.Location.GetName]!;J'ai enlevé avec force la forteresse hérétique locale [Root.Location.GetName]!;Ich habe mit Nachdruck die lokale Ketzer Hochburg in entfernt [Root.Location.GetName]!;;¡Me han quitado la fuerza de la fortaleza local en hereje [Root.Location.GetName]!;;;;;;;;;x
EVTTOOLTIP_HR567890.2;Send a letter to my liege!;J’envoie une lettre à mon suzerain !;Schickt einen Brief an meinen Lehnsherrn!;;¡Envía una carta a mi señor!;;;;;;;;;x
EVTDESC_HR567890.3;I have forcefully removed the local heretic stronghold in [Root.Location.GetName]!;J'ai enlevé avec force la forteresse hérétique locale [Root.Location.GetName]!;Ich habe mit Nachdruck die lokale Ketzer Hochburg in entfernt [Root.Location.GetName]!;;¡Me han quitado la fuerza de la fortaleza local en hereje [Root.Location.GetName]!;;;;;;;;;x
EVTOPTA_HR567890.3;My hard work has paid off!;Mes efforts ont payé !;Meine Anstrengungen haben sich ausgezahlt!;;¡Mis esfuerzos han dado su fruto!;;;;;;;;;x
EVTDESC_HR567890.4;I have forcefully removed the local heretic stronghold in [Root.Location.GetName]!;J'ai enlevé avec force la forteresse hérétique locale [Root.Location.GetName]!;Ich habe mit Nachdruck die lokale Ketzer Hochburg in entfernt [Root.Location.GetName]!;;¡Me han quitado la fuerza de la fortaleza local en hereje [Root.Location.GetName]!;;;;;;;;;x


job_lord_spiritual.txt

# 567890: The Lord Spiritual removes a heretic stronghold!
character_event = {
id = HR567890.1
title = "EVTNAME_HR567890.1"
desc = "EVTDESC_HR567890.1"
picture = GFX_evt_heretic

# only_men = yes
capable_only = yes
prisoner = no

trigger = {
has_job_action = action_inquisition
location = {
owner = { same_realm = ROOT }
religion = ROOT
has_province_modifier = heretic_stronghold
}
}

mean_time_to_happen = {
months = 120
modifier = {
factor = 0.75
location = { culture_group = ROOT }
}
modifier = {
factor = 0.75
location = { culture = ROOT }
}
modifier = {
factor = 0.5
location = { religion_group = ROOT }
}
modifier = {
factor = 1.25
NOT = { learning = 2 }
}
modifier = {
factor = 1.25
NOT = { learning = 3 }
}
modifier = {
factor = 1.25
NOT = { learning = 4 }
}
modifier = {
factor = 1.25
NOT = { learning = 5 }
}
modifier = {
factor = 0.75
learning = 10
}
modifier = {
factor = 0.75
learning = 11
}
modifier = {
factor = 0.75
learning = 12
}
modifier = {
factor = 0.75
learning = 13
}
modifier = {
factor = 2.0
NOT = { religion_authority = 0.4 }
}
modifier = {
factor = 4.0
NOT = { religion_authority = 0.2 }
}
modifier = {
factor = 0.75
religion_authority = 0.6
}
modifier = {
factor = 0.75
religion_authority = 0.8
}
modifier = {
factor = 1.5
is_heresy_of = ROOT
}
modifier = {
factor = 0.75
has_province_modifier = force_converting
}

}

option = {
name = "HR567890.2"
piety = 10
location = { remove_province_modifier = heretic_stronghold }
liege = {
letter_event = { id = HR567890.4 tooltip = EVTTOOLTIP_HR567890.2 }
hidden_tooltip = {
if = {
limit = {
top_liege = {
NOT = { character = PREV }
religion = ROOT
}
}
top_liege = { letter_event = { id = HR567890.3 } }
}
}
}
}
}

# 20000: The Lord Spiritual informs his liege of the removal
letter_event = {
id = HR567890.3
desc = "EVTDESC_HR567890.3"

is_triggered_only = yes

option = {
name = "EVTOPTA_HR567890.3"
piety = 15
if = {
limit = {
is_heretic = no
rightful_religious_head_scope = {
ROOT = {
NOT = { excommunicated_for = PREV }
}
}
}

}
}
}

# 20001: Informs top liege
letter_event = {
id = HR567890.4
desc = "EVTDESC_HR567890.4"

is_triggered_only = yes

option = {
name = "EXCELLENT"
}
}

rickinator9
06-08-2012, 19:22
I'm pretty sure that's not a problem. That's the namespace mechanic. That 'title' I am not familiar with.

Monk
06-08-2012, 19:26
I'm pretty sure that's not a problem. That's the namespace mechanic. That 'title' I am not familiar with.

Title is displayed at the top of the event. Most character events don't have them but some do, they're optional.


The id was the same format used in my heretic removal portion, as well as a few other mods I've come across, all with no problem. I don't know what's different with this.

Perhaps the validator was simply giving fits for no reason over that, if so feel free to ignore that. The changes I made to the localisation and the events provided a perfectly readable event on all levels. Maybe the problem was solely in the localisation? :shrug:

Kekvit Irae
06-09-2012, 05:59
http://dl.dropbox.com/u/52845763/equalitytest.zip

Mind giving it a look and seeing what's wrong? I've made some necessary changes, but it still screws up. The new actions are in the Steward and Chancellor.

rickinator9
06-09-2012, 10:57
In case you didn't know, here's a CKII modding IRC channel: http://qchat.rizon.net/?channels=ckii

Monk
06-09-2012, 12:23
Isolated the problem and what is different: your events are overlapping.

After some experimenting i discovered that trying to keep the event at seam900.1 was overlaping with the base game's event of 900.

I thought it might be a localisation error but no matter what i changed (caps, decimal inclusion, ect) nothing would change about the way the event displayed, all i would get is this:

https://i.imgur.com/MNRum.jpg

After some messing around and experimenting I struck on the idea.. maybe somehow the game was confusing seam900.1 with the base event id 900? Went back in and changed only the id to SEAM900001 as well as all the localisations related to that. End result:

https://i.imgur.com/nnDZ3.jpg

I think decimals are fine but the game will still get confused unless you're in your own id range. 900,000 isnt used for anything in vanilla, which lets the event fire on its own. Same with your heretic events. 567,890 is not used in vanilla, so its free to fire on its own without overlap

edit: to be honest Kekvit this is my best guess. I changed the id to SEAM900001 and it worked, changed it back (along with all localisations) and it instantly broke, then changed it back and it worked again. :shrug:

Kekvit Irae
06-09-2012, 12:46
Isolated the problem and what is different: your events are overlapping.

After some experimenting i discovered that trying to keep the event at seam900.1 was overlaping with the base game's event of 900.

I thought it might be a localisation error but no matter what i changed (caps, decimal inclusion, ect) nothing would change about the way the event displayed, all i would get is this:

After some messing around and experimenting I struck on the idea.. maybe somehow the game was confusing seam900.1 with the base event id 900? Went back in and changed only the id to SEAM900001 as well as all the localisations related to that. End result:

I think decimals are fine but the game will still get confused unless you're in your own id range. 900,000 isnt used for anything in vanilla, which lets the event fire on its own. Same with your heretic events. 567,890 is not used in vanilla, so its free to fire on its own without overlap

Oh thank god. I was about to completely ditch progress on my mod because of the frustration.
The implication for this would be that event names seem to ignore everything except the number, probably. The funny thing is that the Courts And Titles mod doesn't use numbers in the localisation file or event names except when seperated by a period. So I'm thinking I can completely ditch the seam900.1 and turn it into seam.1 and work from there. Since there are no numbers before the period, I should be safe.

Many thanks

EDIT: And just for reference, here is the CATs mod localisation file:

CODE;ENGLISH;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTDESC_gift.0;My wife looks lonely. Maybe I should send my confidant to find her a cat.;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTA_gift.0;Go find one in the alley behind the marketplace.;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTB_gift.0;How about a lovely, fluffy one?;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTDESC_gift.1;Thank you, my lord husband.;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTA_gift.1;I love it. Poor little half-starved thing.;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTB_gift.1;I would rather it keep the rats at bay;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTA_gift.2;What a fluffy little thing!;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
EVTOPTB_gift.2;Aaaaaaachhooooooo!;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
gift_cat;Felis silvestris catus;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
obj_conjugal_love_title;Family Pet;FRENCH;GERMAN;;SPANISH;;;;;;;;;x
obj_conjugal_love_desc;Get My spouse a cat;FRENCH;GERMAN;;SPANISH;;;;;;;;;x

Monk
06-09-2012, 13:08
To be honest if that hadn't worked i was just about out of ideas. :laugh4:

Happy I could be of assistance.


EDIT: And just for reference, here is the CATs mod localisation file:

Very interesting. I'd say it's a fair bet your assumption is correct in that light. For my own events i've been sticking to a numbered scheme, but it's nice to know you can have a bit of flexibility in how you set up your ids.

Although now I have the strangest desire to include cat related events in my mod...

Kekvit Irae
06-09-2012, 15:42
Although now I have the strangest desire to include cat related events in my mod...

Cat related events? BURN THE WITCH!

(first you need to see if she weighs more than a duck)

Monk
06-09-2012, 15:52
Cat related events? BURN THE WITCH!

(first you need to see if she weighs more than a duck)

:laugh4: I have to admit that was the very first thing that came to mind when I said "more interactions with your peasants." I've had to be careful not to make my mod TOO silly. Though, I wonder if there's any witch events in vanilla. I dont remember seeing any.

Might be fun to mess around with. :idea:

Kekvit Irae
06-09-2012, 16:03
:laugh4: I have to admit that was the very first thing that came to mind when I said "more interactions with your peasants." I've had to be careful not to make my mod TOO silly. Though, I wonder if there's any witch events in vanilla. I dont remember seeing any.

Open up text1.csv and search for EVTDESC4035. 4035 and 4036 are witch events. Also modifier_witch and tortured_witch in the same file.

rickinator9
06-09-2012, 16:16
Apart from sacrificing relatives, you could also make an event where you can just execute everyone you hate by saying: "She's a witch, kill her!"

Monk
06-09-2012, 16:20
Open up text1.csv and search for EVTDESC4035. 4035 and 4036 are witch events. Also modifier_witch and tortured_witch in the same file.

Oh nice. Thank you for that. :bow:

Double A
06-11-2012, 02:25
This has given me a good idea for a History of the World, Part I mod

Will part 2 have Jews in space?


Well I've finally hit a wall. I wanted to add in a new councilor to my mod. Edited all the files, put the files in the right places, and everything works fine. Unfortunately, when I place my new councilor on the map, I get a CTD. Searching around reveals that the xsc and xac files are part of a modeling program called Emotion FX, and simply renaming the spymaster model files to what I want wont work. Did I mention that Emotion FX uses proprietary software and costs 10,000 dollars a license?

I can just move all the new actions over to the old councilors, but meh. I wanted my seamstress!

Kickstarter!

Monk
06-11-2012, 21:43
I bet you never thought you'd see this again!

https://i.imgur.com/nwkb1.jpg

The current build of my mod has officially reached a 50/50 split on Iberia. It all depends on who works together better. Sometimes that's the northern christians, and sometimes that's the muslims. I was really close in the v0.2 build but it was still a bit one sided I think, so i instituted a rather popular change: holy wars now cost piety to declare. I've found that its more so to help the AI than balance the player since if the AI is concerned it has low piety it will actually press de-jure claims instead of holy warring from day one.

This means that at the 1066 start, the Jimena brothers start fighting each other, attempting to solidify the north before they holy war. In vanilla, they holy war from the start and get smacked up pretty badly without once attempting to unify. Overall, while i'm not totally happy with the balance, I think it's hit a good spot for now.

I'm going to wait to see how 1.06 and the new combat system impacts the balance of both vanilla and my mod, until then I will probably stop messing with the starting balance of the 1066 date. Gonna release v0.3 after the new patch comes out and i know for sure it isn't broken. Seems like a good idea and all. Till then back to event coding.

I don't have a screenshot of it, but i've also been messing around in the Ethiopian area. Gave monophysite a new holy order and a fresh batch of new mercenaries to help them stay alive much longer. It's not perfect, but it does the job and keeps the factions down in that area alive much longer than they otherwise would be able. :yes:

rickinator9
06-12-2012, 02:41
I had never thought there's so little information about some regions in antiquity. I was struggling to find any lydian towns other than Sardis.

Also, if you wanna see some pictures of Tamriel, I can show you some. If there's anyone who can make portraits, well, we need you!

Ibn-Khaldun
06-20-2012, 16:35
Can anyone tell me what files do I have to change in order to mod a kingdom into my game?

Ibn-Khaldun
06-20-2012, 16:36
I had never thought there's so little information about some regions in antiquity. I was struggling to find any lydian towns other than Sardis.

Also, if you wanna see some pictures of Tamriel, I can show you some. If there's anyone who can make portraits, well, we need you!

Can't you use portraits from EU: Rome? It could make your life a bit easier.

rickinator9
06-20-2012, 19:48
Can't you use portraits from EU: Rome? It could make your life a bit easier.

As far as I know, the portraits of Rome are static, while those of CK2 are randomly generated.

rickinator9
06-20-2012, 20:14
Nvm doublepost

Monk
06-21-2012, 10:07
Can anyone tell me what files do I have to change in order to mod a kingdom into my game?

Sure. Rather than tell you myself though I'll point you to this really helpful tutorial that covers just about everything you need to know: http://forum.paradoxplaza.com/forum/showthread.php?602571-Creating-a-Kingdom-Title

Pretty much covers everything in there about creating a formable de jure title. Making a titular title is the same way just ignore where you assign duchies to it in landed_titles.txt

For creating a kingdom that appears on start, rather than a title that is formable, this tutorial will be helpful to your efforts.
http://forum.paradoxplaza.com/forum/showthread.php?598651-Tutorial-Making-a-Kingdom-and-overriding-default-title-names&highlight=rename+factions

The second link is not as clearly written as the first but is still helpful for people willing to play around and tinker with various aspects of the files. It's always a great idea to use a mod directory, but don't be afraid of 'breaking' things in the files.

rickinator9
06-22-2012, 18:45
So I always wanted to extend the map further into the Indus, the only issue was that the CKII map had a odd trajectory and topology is very difficult to make. I found some NASA heightmaps which would serve well for topology and I decided to make a custom map. This is the basic map:
https://i1155.photobucket.com/albums/p543/rickinator9/CKII/CK2Mod/Basicmapoutline.jpg

PS: Ignore the lower countries, still have to edit them to look like they were in 280 BCE

Kekvit Irae
06-22-2012, 23:04
I found some NASA heightmaps which would serve well for topology

Finding DEMs is always a pain. I should know, I have a certification in GIS (Geographic Information Systems, AKA: maps are my specialty).
The only reliable (HAHAHAHAHA) sources of DEMs are NASA and USGS.

Monk
06-25-2012, 10:12
Figured out a cool trick to stop holy war spam, and i'm not sure why I didn't think of it sooner: tie holy wars into character modifiers.

It is possible with the game engine to assign character modifiers as apart of the victory/defeat section of a casus belli. Once i figured that out, it's a logical step to them make that CB only valid if you have/don't have said modifier. Bingo! Instant war cooldowns that EVERYONE (AI and player) must respect. I wouldn't be surprised if others have figured it out way before me. I mean it's pretty obvious of a solution, but it was the final component in all of my balance frustrations that I was trying to solve.

How it works is actually pretty simple. As part of the war rewards on a successful holy war, a character receives a special modifier that will show up in their character screen and give you a visual countdown. For the sake of balance i've set the cooldown for just under 5 years. Here, the AI king of Castile has won a war against Cordoba and now has the modifier.

https://i.imgur.com/EmhKf.jpg

John malkoviching into him we go to the CB area and see that the Holy War CB has vanished. It's gone! Spooky! Well not really - all i did was tie the Holy War CB into the character modifier. Now for it to be active, no character can have the truce modifier. Once the modifier goes away, the CB becomes valid again.

https://i.imgur.com/gSYRV.jpg

There is a cheese way around it, however. Since the cooldown is tied into the character itself all you have to do is find a way to suicide and you can holy war again. :shrug: But to be honest that is only a problem for the player. The AI is forced to respect the cooldown because the CB literally becomes invalid. This ensures a number of things that make me quite happy. First: Holy War spam is GONE (combined with requiring piety to be spent for holy wars, that is). Secondly: The early game snowball effect is gone as well. It is no longer possible to declare Holy Wars one after another without finding a way to cheat the system. The 5 year cooldown now lets other factions step in and fight a bit, and also encourages the AI and player alike to actually use their chancellors. Expansion is much slower, and as a result, you can expect to see the reconquista lasting for centuries with this change, rather than decades.

I'm really anxious to see how SoI impacts these recent (at least for me) discoveries :grin2:

Docus
06-30-2012, 00:18
I'm busy working on an Elder Scrolls mod for Crusader Kings 2. Right now I'm working on the map. I've got all of Tamriel planned out, but before proceeding I want tot try to get a small portion of the map ingame as a test. The current testmap contains Skyrim, Solstheim and Vvardenfell and all their provinces.

http://imgur.com/a/tYAPl#4

However, I just can't seem to get it to work. The game crashes at "calculating paths" in the startup load screen. I've tried everything: cleaning up stray pixels, editing all the text and CSV files in the map folder, doublechecking the amount of provinces, sea_starts, etc... I'm at my wits end.

Does anyone here have an idea what could be wrong?

https://i.imgur.com/HYQcrh.jpg

rickinator9
06-30-2012, 02:52
I don't know anything about your issue, but there is already a elder scrolls mod. I don't want to discourage you to make a map, but we have already completed a large part of it. Here is a link to our site: http://ck2.knuddelwuddel.net/

For quick modding questions like these, there's a thread for that on the paradox forums: http://forum.paradoxplaza.com/forum/showthread.php?589686-Modding-Quick-questions

Docus
06-30-2012, 08:10
I don't know anything about your issue, but there is already a elder scrolls mod. I don't want to discourage you to make a map, but we have already completed a large part of it. Here is a link to our site: http://ck2.knuddelwuddel.net/

For quick modding questions like these, there's a thread for that on the paradox forums: http://forum.paradoxplaza.com/forum/showthread.php?589686-Modding-Quick-questions

Your mod looks absolutely terrific. Anything that will let me play Crusader Kings II in the world of Tamriel has my blessing. I'm considering of maybe joining your team.

naut
07-02-2012, 16:39
Is anyone else having difficulty manipulating the landed_titles.txt? I'm trying to move d_flanders to k_france. However, even after enabling it, the change is not registered, contrary to version 1.05.

Monk
07-02-2012, 19:10
Is anyone else having difficulty manipulating the landed_titles.txt? I'm trying to move d_flanders to k_france. However, even after enabling it, the change is not registered, contrary to version 1.05.

No. It should work when you move the duchy from k title to k title to get it to be de jure. I just tested it myself and I was able to move d_holland over to k_france without a problem. My own mod has also messed with de jure lines in Iberia successfully as well.

If you are using a mod make sure your mod path loads correctly. You need a .mod file with something like:



name = "tweakstest"
path = "mod/tweakstest"

sitting in your /mod folder, telling the game how to load your mod. The name of your mod should replace the name of my test build. Also know that any crazy characters (like - ) will break the mod path.

naut
07-03-2012, 06:06
I've not altered my folder structure or my .mod file. I made the same change in your Tweaks mod to see the result. Flanders remains De Jure Frisia and the Count/Duke flags for several titles (in and beyond Flanders) switches to generic flags, not the historic flags.

Monk
07-03-2012, 09:01
I've not altered my folder structure or my .mod file. I made the same change in your Tweaks mod to see the result. Flanders remains De Jure Frisia and the Count/Duke flags for several titles (in and beyond Flanders) switches to generic flags, not the historic flags.

In that case it could be one of two things, an out of place bracket causing the engine to get confused and throw flags everywhere, or a mismatched flag cache. Both are relatively simple fixes.

Code placement:


I went ahead and tested de jure placement in my mod with the following results. I took out d_flanders from k_frisia and plugged it into k_france with the following code:

duchy code

d_flanders = {
color={ 255 120 0 }
color2={ 255 255 255 }

capital = 78

culture = dutch

c_artois = {
color={ 39 72 212 }
color2={ 255 255 255 }

b_arras = {
}
b_terwaan = {
}
b_bethune = {
}
b_lens = {
}
b_lille = {
}
b_bouvines = {
}
b_beaumetz = {
}
b_bapaume = {
}
}
c_boulogne = {
color={ 43 76 216 }
color2={ 255 255 255 }

b_boulogne = {
}
b_montreuil = {
}
b_saintpol = {
}
b_hesdin = {
}
b_fauquembergues = {
}
b_ternouis = {
}
b_therouanne = {
}
b_ardres = {
}
}
c_guines = {
color={ 47 80 220 }
color2={ 255 255 255 }

b_guines = {
}
b_saintomer = {
}
b_calais = {
}
b_dunkerque = {
}
b_bourbourg = {
}
b_marck = {
}
b_gravelines = {
}
b_coulogne = {
}
}
c_yperen = {
color={ 51 84 224 }
color2={ 255 255 255 }

b_ypres = {
}
b_rosebeke = {
}
b_cassel = {
}
b_roeselare = {
}
b_poperinge = {
}
b_menen = {
}
b_diksmuide = {
}
b_wervik = {
}
}
c_brugge = {
color={ 55 88 228 }
color2={ 255 255 255 }

b_brugge = {
}
b_damme = {
}
b_sluys = {
}
b_oostende = {
}
b_male = {
}
b_nieuwpoort = {
}
b_torhout = {
}
b_aardenburg = {
}
}
c_gent = {
color={ 59 92 232 }
color2={ 255 255 255 }

b_gent = {
}
b_doornik = {
}
b_oudenaarde = {
}
b_aalst = {
}
b_st_niklaas = {
}
b_dendermonde = {
}
b_kortrijk = {
}
b_geraardsbergen = {
}
}
}


kingdom code (includes above)

k_france = {
color={ 15 27 187 }
color2={ 255 255 20 }
capital = 112 # Ile de France
dignity = 20 # Counted as having this many more counties than it does

culture = frankish

catholic = 700 # Crusade target weight

d_flanders = {
color={ 255 120 0 }
color2={ 255 255 255 }

capital = 78

culture = dutch

c_artois = {
color={ 39 72 212 }
color2={ 255 255 255 }

b_arras = {
}
b_terwaan = {
}
b_bethune = {
}
b_lens = {
}
b_lille = {
}
b_bouvines = {
}
b_beaumetz = {
}
b_bapaume = {
}
}
c_boulogne = {
color={ 43 76 216 }
color2={ 255 255 255 }

b_boulogne = {
}
b_montreuil = {
}
b_saintpol = {
}
b_hesdin = {
}
b_fauquembergues = {
}
b_ternouis = {
}
b_therouanne = {
}
b_ardres = {
}
}
c_guines = {
color={ 47 80 220 }
color2={ 255 255 255 }

b_guines = {
}
b_saintomer = {
}
b_calais = {
}
b_dunkerque = {
}
b_bourbourg = {
}
b_marck = {
}
b_gravelines = {
}
b_coulogne = {
}
}
c_yperen = {
color={ 51 84 224 }
color2={ 255 255 255 }

b_ypres = {
}
b_rosebeke = {
}
b_cassel = {
}
b_roeselare = {
}
b_poperinge = {
}
b_menen = {
}
b_diksmuide = {
}
b_wervik = {
}
}
c_brugge = {
color={ 55 88 228 }
color2={ 255 255 255 }

b_brugge = {
}
b_damme = {
}
b_sluys = {
}
b_oostende = {
}
b_male = {
}
b_nieuwpoort = {
}
b_torhout = {
}
b_aardenburg = {
}
}
c_gent = {
color={ 59 92 232 }
color2={ 255 255 255 }

b_gent = {
}
b_doornik = {
}
b_oudenaarde = {
}
b_aalst = {
}
b_st_niklaas = {
}
b_dendermonde = {
}
b_kortrijk = {
}
b_geraardsbergen = {
}
}
}
d_berry = {
color={ 24 52 226 }
color2={ 255 255 255 }

capital = 140 # Tours

c_tourraine = {
color={ 27 55 229 }
color2={ 255 255 255 }

b_chinon = {
}
b_tours = {
}
b_beaulieu = {
}
b_amboise = {
}
b_loches = {
}
b_langeais = {
}
b_fierbois = {
}
b_montbazon = {
}
}
c_bourges = {
color={ 30 58 232 }
color2={ 255 255 255 }

b_chateauroux = {
}
b_deols = {
}
b_bourges = {
}
b_issoudun = {
}
b_stsatur = {
}
b_sancerre = {
}
b_mehun = {
}
b_vierzon = {
}
}
}
d_anjou = {
color={ 43 24 226 }
color2={ 255 255 255 }

capital = 107 # Anjou

c_anjou = {
color={ 45 26 228 }
color2={ 255 255 255 }

b_vihiers = {
}
b_angers = {
}
b_fontevraud = {
}
b_saumur = {
}
b_montsoreau = {
}
b_cholet = {
}
b_treves = {
}
b_chateaugontier = {
}
}
c_maine = {
color={ 49 30 232 }
color2={ 255 255 255 }

b_le_mans = {
}
b_beaumont = {
}
b_evron = {
}
b_mayenne = {
}
b_laval = {
}
b_sable = {
}
b_craon = {
}
b_montenay = {
}
}
}
d_normandy = {
color={ 71 24 226 }
color2={ 255 255 255 }

capital = 97 # Rouen

culture = norman

c_evreux = {
color={ 74 27 229 }
color2={ 255 255 255 }

b_evreux = {
}
b_falaise = {
}
b_lisieux = {
}
b_alencon = {
}
b_argentan = {
}
b_sees = {
}
b_verneuil = {
}
b_honfleur = {
}
}
c_avranches = {
color={ 77 30 232 }
color2={ 255 255 255 }

b_caen = {
}
b_coutances = {
}
b_bayeux = {
}
b_avranches = {
}
b_mortain = {
}
b_domfront = {
}
b_barfleur = {
}
b_cherbourg = {
}
}
c_vexin = {
color={ 80 33 235 }
color2={ 255 255 255 }

b_larocheguyon = {
}
b_mantes = {
}
b_pontoise = {
}
b_harcourt = {
}
b_gisors = {
}
b_andely = {
}
b_ivry = {
}
b_abbayedemortemer = {
}
}
c_arques = {
color={ 83 36 238 }
color2={ 255 255 255 }

b_fecamp = {
}
b_rouen = {
}
b_lillebonne = {
}
b_harfleur = {
}
b_arques = {
}
b_dieppe = {
}
b_jumieges = {
}
b_longueville = {
}
}
c_eu = {
color={ 86 39 241 }
color2={ 255 255 255 }

b_eu = {
}
b_mortemer = {
}
b_gournay = {
}
b_aumale = {
}
b_forges = {
}
b_drincourt = {
}
b_neufchatel-en-bray = {
}
b_serqueux = {
}
}
}
d_orleans = {
color={ 126 124 226 }
color2={ 255 255 255 }

capital = 138 # Orleans

c_orleans = {
color={ 94 32 234 }
color2={ 255 255 255 }

b_gien = {
}
b_orleans = {
}
b_fleury = {
}
b_lepuiset = {
}
b_sully = {
}
b_meung = {
}
b_janville = {
}
b_jargeau = {
}
}
c_blois = {
color={ 90 28 230 }
color2={ 255 255 255 }

b_beaugency = {
}
b_blois = {
}
b_staignan = {
}
b_chaumontsurloire = {
}
b_montrichard = {
}
b_fougeressurbievre = {
}
b_romorantin = {
}
b_stgeorgesdubois = {
}
}
c_vendome = {
color={ 47 28 230 }
color2={ 255 255 255 }

b_lavardin = {
}
b_vendome = {
}
b_cloyes = {
}
b_freteval = {
}
b_chateaurenault = {
}
b_montoire = {
}
b_montmirail = {
}
b_stavit = {
}
}
c_chartres = {
color={ 98 36 238 }
color2={ 255 255 255 }

b_chateaudun = {
}
b_chartres = {
}
b_dreux = {
}
b_nogent = {
}
b_gallardon = {
}
b_epernon = {
}
b_bonneval = {
}
b_tiron = {
}
}
}
d_champagne = {
color={ 95 24 226 }
color2={ 255 255 255 }

capital = 114 # Reims

c_troyes = {
color={ 99 28 230 }
color2={ 255 255 255 }

b_brienne = {
}
b_troyes = {
}
b_langres = {
}
b_chaumont = {
}
b_clairvaux = {
}
b_rosnay = {
}
b_joinville = {
}
b_chacenay = {
}
}
c_reims = {
color={ 101 30 232 }
color2={ 255 255 255 }

b_reims = {
}
b_chateauthierry = {
}
b_provins = {
}
b_chalons = {
}
b_chatillon = {
}
b_vertus = {
}
b_epernay = {
}
b_roucy = {
}
}
c_sens = {
color={ 102 40 242 }
color2={ 255 255 255 }

b_montargis = {
}
b_sens = {
}
b_nemours = {
}
b_chateaulandon = {
}
b_nogentsurseine = {
}
b_joigny = {
}
b_montereau = {
}
b_villeneuveleroi = {
}
}
}
d_valois = {
color={ 35 141 208 }
color2={ 255 255 255 }
capital = 112 # Ile de France

c_ile_de_france = {
color={ 38 144 211 }
color2={ 255 255 255 }

b_paris = {
}
b_melun = {
}
b_stdenis = {
}
b_meaux = {
}
b_etampes = {
}
b_montfortlamaury = {
}
b_senlis = {
}
b_compiegne = {
}
}
c_vermandois = {
color={ 41 147 214 }
color2={ 255 255 255 }

b_coucy = {
}
b_stquentin = {
}
b_laon = {
}
b_crepy = {
}
b_montaigu = {
}
b_rethel = {
}
b_guise = {
}
b_signy = {
}
}
c_amiens = {
color={ 44 151 217 }
color2={ 255 255 255 }

b_peronne = {
}
b_amiens = {
}
b_beauvais = {
}
b_soissons = {
}
b_corbie = {
}
b_noyon = {
}
b_montdidier = {
}
b_breteuil = {
}
}
}
d_burgundy = {
# French, or Lower Burgundy
color={ 153 67 108 }
color2={ 255 255 255 }
capital = 136 # Dijon

c_chalons = {
color={ 161 22 60 }
color2={ 255 255 255 }

b_brancion = {
}
b_chalon = {
}
b_tournus = {
}
b_louhans = {
}
b_chamilly = {
}
b_seurre = {
}
b_stjeandelosne = {
}
b_cuisery = {
}
}

c_auxerre = {
color={ 97 26 228 }
color2={ 255 255 255 }

b_auxerre = {
}
b_druyes = {
}
b_tonnerre = {
}
b_pontigny = {
}
b_cravant = {
}
b_crisenon = {
}
b_stsauveurenpuisaye = {
}
b_mailly = {
}
}
c_macon = {
color={ 27 165 229 }
color2={ 255 255 255 }

b_fuisse = {
}
b_macon = {
}
b_cluny = {
}
b_davaye = {
}
b_beaujeu = {
}
b_lugny = {
}
b_berze = {
}
b_villefranchesursaone = {
}
}
c_dijon = {
color={ 30 168 232 }
color2={ 255 255 255 }

b_semur = {
}
b_dijon = {
}
b_autun = {
}
b_vezelay = {
}
b_avallon = {
}
b_citeaux = {
}
b_beaune = {
}
b_noyers = {
}
}
c_nevers = {
color={ 33 171 235 }
color2={ 255 255 255 }

b_courtenay = {
}
b_nevers = {
}
b_lacharite = {
}
b_donzy = {
}
b_chateauchinon = {
}
b_vandenesse = {
}
b_clamecy = {
}
b_cosne = {
}
}
c_charolais = {
color={ 36 174 238 }
color2={ 255 255 255 }

b_montstvincent = {
}
b_charolles = {
}
b_paray = {
}
b_semurenbrionnais = {
}
b_toulonsurarroux = {
}
b_perrecy = {
}
b_digoine = {
}
b_joncy = {
}
}
}
}

End result was that the de jure moved but more importantly flags were fine shown here:
https://i.imgur.com/ahR5f.jpg
https://i.imgur.com/Nok46.jpg

landed_titles and flag generation is just about the most pain in the ass thing about CK2 and it's really finicky. Always a good idea to double check your code before moving on.

It could also be a mismatched flag cache. Whenever you are moving between versions that mess with landed_titles, your game may not generate a new cache if it doesn't detect that it's loading a new version properly. This means that it will try to apply improper flags to titles. It's always a good idea to delete the flag cache when you are swapping between vanilla and a mod that makes de jure changes for this very reason and is a lesson i've learned the hard way.

In order to force the game to to re-scan your landed_titles to apply the proper flags go to my documents\paradox interactive\Crusader Kings 2\gfx and delete the entire 'flags' folder there.



Lemme know if that helps.

rickinator9
07-03-2012, 12:27
I've not altered my folder structure or my .mod file. I made the same change in your Tweaks mod to see the result. Flanders remains De Jure Frisia and the Count/Duke flags for several titles (in and beyond Flanders) switches to generic flags, not the historic flags.

There seems to be a bug right now that makes replace_path fail. Maybe that's what's up.

Monk
07-03-2012, 20:23
I am constantly amazed by the things i discover when I am just messing around with files.

https://i.imgur.com/Oa4Rf.jpg

I had no idea restricting laws was this easy. I remember that trying to put time limits on the laws was a pain and ultimately proved a dead-end due to how laws work, but limiting based on title works perfectly. This means that you can effectively keep certain powers locked and unable to go beyond certain crown authority with the adition of:

example


NOT = {
title = e_hre
}


In the grand scheme of things i suppose this isn't a huge discovery as I doubt I would implement this for any title other than the hre, but it's an interesting one for that very reason.

naut
07-04-2012, 12:46
Cheers Monk! =)


There seems to be a bug right now that makes replace_path fail. Maybe that's what's up.
I have a feeling it is the flag cache, but I'll keep this in mind.

Restricting laws like that is very useful! I've been wondering if it is possible to make the plot "Reduce Crown Authority" easier to accomplish? I've never been able to achieve the plot, even if potential co-conspirators like me 100%. Currently everyone must hate the liege almost 100% as well, which is way too hard to achieve!

Ibn-Khaldun
07-04-2012, 21:48
Is there a way to make an "Insulted" CB?

What I'm thinking is that you get this against foreign rulers(or against your vassals) in some cases and it would allow you to declare war on them. If you win you would gain large prestige bonus while the loser gets prestige penalty?

Also, is there a way to make some battles more important than others? For example, winning a battle against the king would give you mor warscore than a battle against a courtier?

Monk
07-04-2012, 23:51
Is there a way to make an "Insulted" CB?

What I'm thinking is that you get this against foreign rulers(or against your vassals) in some cases and it would allow you to declare war on them. If you win you would gain large prestige bonus while the loser gets prestige penalty?

Sorta like the diplomatic insult CB from EUIII? Hm. I don't see why not. Have the winner get prestige and money from the loser instead of titles. There's already CB that are similiar but not the same thing in the files, all you'd have to do is mod them to be of the desired effect. It's got me curious. Might mess around with that later.


Also, is there a way to make some battles more important than others? For example, winning a battle against the king would give you mor warscore than a battle against a courtier?

I'm not sure, i have no idea where to even look for that one. Likely hidden away in defines.lua if i had to guess.


Restricting laws like that is very useful! I've been wondering if it is possible to make the plot "Reduce Crown Authority" easier to accomplish? I've never been able to achieve the plot, even if potential co-conspirators like me 100%. Currently everyone must hate the liege almost 100% as well, which is way too hard to achieve!

Same as above, i have no idea. Will need to do some file hunting tomorrow and see if I can locate that, not sure i'd mess with it myself but I like to know where things are. :yes:

naut
07-05-2012, 16:27
I'm a dummy. Wrong thread.

D.PHa
07-08-2012, 13:10
I don't intend to make any mod, i just want to make just a few tweaks, so I'm trying to do so in the main game files, but i had a hard time understanding how does event triggering chances work.
Can anyone please explain just in a few words how does event trigger chances work? I mean, I've found those event files and "meant time to happen/Factor/chance" things, but i don't understand what do they really do, should i increase factor value to make event more frequent or should i do opposite? what meant time to happen really does? and etc. if you tell me basics i'll manage to get through it, so give me few word please :)

and one more question


character_event = {
id = 73006
desc = "EVTDESC73006"
picture = GFX_evt_pregnancy

is_triggered_only = yes

min_age = 16
only_playable = yes
prisoner = no
only_men = yes

trigger = {
any_child = {
is_married = no
is_female = no
age = 16
NOT = { age = 21 }
NOT = { demesne_size = 1 }
NOT = { trait = chaste }
NOT = { trait = celibate }
}

in this code, what do those "age =" stand for? do they automatically stand for minimum and maximum age? i can't really figure out what else they might be pointing to, but even if my guess was true, i don't understand why do we need age = 16, as it is already defined up there by min_age = 16. thanks for your help in advance.

rickinator9
07-08-2012, 15:06
character_event = {
id = 73006
desc = "EVTDESC73006"
picture = GFX_evt_pregnancy

is_triggered_only = yes

min_age = 16
only_playable = yes
prisoner = no
only_men = yes

trigger = {
any_child = {
is_married = no
is_female = no
age = 16
NOT = { age = 21 }
NOT = { demesne_size = 1 }
NOT = { trait = chaste }
NOT = { trait = celibate }
}
The min_age is for the character the event is happening to.

trigger = {
}
defines the condition under which the event will happen. In this case it is odd that there is even a trigger as there is

is_triggered_only = yes
which means that this event can only be triggered by another event.

As for the
age = 16, that applies to any child as there is a
any_child = {
} tag. Judging from the conditions and the picture, it's probable that a son has made love to someone and has created a bastard.

D.PHa
07-08-2012, 17:19
thank you very much, but i have few more questions

I found (but not sure if it is true) file "CK2defaultfolder"\common\on_actions\00_on_actions.txt and there are listed events and their firing chances i guess, can you tell me if i'm not mistaken and what those values before events like "10 = 3320" mean(percentage maybe if the conditions are met? but there are some events with 250 or more also)?

Could you tell me what does that age = 16 exactly signify? now i know that it's for any child but, does it mean that any child that is exactly 16 or does it mean any child that is 16 and above(and below 21 as there is "NOT = { age = 21 }")?

thanks once more

rickinator9
07-08-2012, 17:39
I'm not sure about the on_action events, but the age = 16 means that only people who are 16 or older can get the event(in this case the son must be 16 or older) .

Monk
07-09-2012, 02:36
thank you very much, but i have few more questions

I found (but not sure if it is true) file "CK2defaultfolder"\common\on_actions\00_on_actions.txt and there are listed events and their firing chances i guess, can you tell me if i'm not mistaken and what those values before events like "10 = 3320" mean(percentage maybe if the conditions are met? but there are some events with 250 or more also)?

Could you tell me what does that age = 16 exactly signify? now i know that it's for any child but, does it mean that any child that is exactly 16 or does it mean any child that is 16 and above(and below 21 as there is "NOT = { age = 21 }")?

thanks once more

The on actions pulses will fire events as a consequence of another event happening. A child's birth is a very good example of this. Once a female character is married (or has a lover) they have a yearly pulse to check if they get pregnant. CyberSpider from the Paradox forums sums it up nicely in the massive mod FAQ thread:


Event pulses are actually fairly straightforward.

1. The game engine decides when a 'pulse' happens for a character - there are annual 'pulses', biannual, pentannual, annual-between-2-and-16, combat pulses, and siege pulses.
2. Each pulse has a list of events (the right-hand number) and their associated weighting (the left-hand number).
3. The game goes through the list of events, and eliminates any for which the character receiving the 'pulse' doesn't qualify.
4. Each event's weight is then adjusted by the modifiers listed in the event's "mean time to happen". Note that these modifiers are essentially backwards from the normal use of modifiers; a high number makes the event more probable, not less.
5. Once the game has produced this list of modified weights for events for which the character is qualified, it "rolls a die" to pick one based on the weighting.
6. The character gets the event.

If you want to set up an event to fire on a pulse through the on_actions file, you'll need to give it a mean_time_to_happen as well as a is_triggered_only = yes. If you do not tie it correctly to the actions file, you will instead have it firing every day. Which can be very annoying :no:

A useful link for learning about events is here:http://forum.paradoxplaza.com/forum/showthread.php?604588-Events

It includes a lot of the triggers you want to learn in the first two posts, after all the triggers, the OP explains what a lot of them mean. But still there's no substitute for good old fashioned experimenting.


Could you tell me what does that age = 16 exactly signify? now i know that it's for any child but, does it mean that any child that is exactly 16 or does it mean any child that is 16 and above(and below 21 as there is "NOT = { age = 21 }")?

thanks once more

It means that you must be at least age 16 or above in order for that character to receive that event. The NOT 21 tag means that after a character is older than 21 they cannot receive that event any longer.

Rooster
07-10-2012, 10:21
I just joined The Org, and thought I'd check out the modding scene.

I am the one working on the CAT mod, so I am happy to see it being used and hopefully enjoyed. Like all things, it evolves, and I am working on an Arthurian mod, but it's slow going.

The starting years will be 495 (Arthur's Coronation) to 518 (Battle of Badon Hill), but you will be able to play up to 1066. Currently, you can play any Irish or Briton Christian lord, but I would like to be able to expand this to the pagan Saxons and Picts as well. I am testing the alpha version of the Arthurian stuff right now, so I can post screenshots later this week if anyone is interested.

Monk
07-10-2012, 10:53
I just joined The Org, and thought I'd check out the modding scene.

I am the one working on the CAT mod, so I am happy to see it being used and hopefully enjoyed. Like all things, it evolves, and I am working on an Arthurian mod, but it's slow going.

The starting years will be 495 (Arthur's Coronation) to 518 (Battle of Badon Hill), but you will be able to play up to 1066. Currently, you can play any Irish or Briton Christian lord, but I would like to be able to expand this to the pagan Saxons and Picts as well. I am testing the alpha version of the Arthurian stuff right now, so I can post screenshots later this week if anyone is interested.

Ah, welcome to the Org Rooster :bow: You'll find our mod community here is much smaller than, say, the paradox forums, but we're no less as passionate about our work. Your project sounds quite interesting, would love to see screenshots. :yes:

Rooster
07-12-2012, 03:43
Ah, welcome to the Org Rooster :bow: You'll find our mod community here is much smaller than, say, the paradox forums, but we're no less as passionate about our work. Your project sounds quite interesting, would love to see screenshots. :yes:

Thank you for the polite welcome. Here is a little collage of what I am working on. I am progressively adding rulers to the map, but I have South Wales, Brittany, Cornwall, and the area from Somerset to Oxford put in yet. The latter I have decided is where Arthur's own demesne should be. He was a descendant of the legendary King of Brittany and Cornwall, Conan Meriadoc (it is a large dynasty with 37 living characters in 495), so I have called the family Meriadoc. I might change this to something else later. Ideas? In 495, Arthur is the king of Britain (an empire-level title), and his heir is Eliwlod, the son of his dead half-brother Madoc. His half-siblings, including the infamous Morgan le Fay, are married into royal houses in Brittany and what is now lowland Scotland. I've thrown in Kay so far who is a baron in Dyfed, where the historical Sir Ector (an an Irishman named Connor Fair-Beard who was the son of the King of Connacht as it turns out). I'm trying to balance between history and legend, drawing on the Welsh sources to help fill out family trees.

https://img525.imageshack.us/img525/3084/arthurcollage.jpg
Clockwise from top: House Meriadoc, of which both Arthur's parents were members; Arthur's immediate family, including his half-siblings Madoc ap Uther, Morgan, Anna, Elaine, and Gormand. The current realm of Britain, including the two subject Kingdoms of Gwent and Dumnonia. I used the vanilla e_britannia flag, which ended up being a really cool looking red dragon on a white field.

rickinator9
07-12-2012, 11:50
Welcome. Already spoke to you on the modding IRC. Your mod looks really good.

Rooster
07-13-2012, 06:47
Welcome. Already spoke to you on the modding IRC. Your mod looks really good.

Thanks. I'm holding off releasing it publicly until I have the history done. The core game will be over the high-kingship of each of the major realms. But there are a lot of possibilities.

Rooster
07-14-2012, 19:23
Just a little update. I made an entry on the CK2 wiki that links to the official forum thread. I am calling it the Matter of Britain and it will cover the British Isles, the realms of the Franks, and Brittany between 410 and 1066.

Cheers,
Rooster

rickinator9
07-14-2012, 22:37
Just a little update. I made an entry on the CK2 wiki that links to the official forum thread. I am calling it the Matter of Britain and it will cover the British Isles, the realms of the Franks, and Brittany between 410 and 1066.

Cheers,
Rooster

Here's the link: http://forum.paradoxplaza.com/forum/showthread.php?620137-Mod-The-Matter-of-Britain
Just so you know, the ORG does allow external links, as opposed to PPlaza which sadly doesn't.

Rooster
07-20-2012, 17:14
Here's the link: http://forum.paradoxplaza.com/forum/showthread.php?620137-Mod-The-Matter-of-Britain
Just so you know, the ORG does allow external links, as opposed to PPlaza which sadly doesn't.

I should just start my own thread, but here is the current image of Wales. 44 provinces, two big kingdoms (Gwynedd and Deheubarth), ten duchies. Glamorgan is going to be a lot of fun; Dyfed is pretty strong and has an allied minor kingdom, and Gwynedd, well, Gwynedd is HUGE! :) I still have to add in Powys, and spruce up the barony names, which are in early medieval Welsh for the most part. Some roll off the tongue, but some are a bit awkward to modern eyes IMO.

http://desmond.imageshack.us/Himg404/scaled.php?server=404&filename=mob11.jpg&res=landing

Only the beginning, probably about an eighth of the whole map, give or take.

rickinator9
07-20-2012, 18:42
I love your dedication. I would find it pretty difficult to find out that sort of info from legends and after that trying to find out where it is on the map.

Monk
07-21-2012, 05:07
Very impressive work. :thumbsup:

Rooster
07-21-2012, 17:49
Thanks, guys. Here is the download link for the current version. Here (http://www.mediafire.com/download.php?bf8caz9r4s2nmjd).

All of Wales is in there, but no special events yet. All I've changed so far is the map. You have seven independent kingdoms to play with, with no game killing bugs, except I forgot to create a way to go from Anglesey to the mainland, so you might want to avoid Gwynedd for now.

Dyfed is my personal favorite right now, but I like the idea of an Irish enclave in Wales. Powys is a bit crazy (but it was the biggest kingdom in southern Britain at the time).

PhilliptheGreat
08-23-2012, 15:49
Have you thought about making a mod that covers India? The feudal system in India during this time period is similar to the one depicted in the game. I don't know anything about modding but I can help you with research. Factions can include the Kingdom of Rajputana and the Dehli Sultunate.

rickinator9
08-24-2012, 00:45
Have you thought about making a mod that covers India? The feudal system in India during this time period is similar to the one depicted in the game. I don't know anything about modding but I can help you with research. Factions can include the Kingdom of Rajputana and the Dehli Sultunate.

Welcome to the .Org Philip. Although I aren't really interested in India, you could search on the Paradox Plaza forums.

Elder Kings (http://forum.paradoxplaza.com/forum/showthread.php?624367-MOD-Elder-Kings-a-CK2-Elder-Scrolls-mod) has been announced (for a while). While I work for that mod, I'm also making a Diadochi mod in my spare time, whenever I'm not playing games or adding things to Elder kings.

rickinator9
09-19-2012, 15:22
So I have been modding a little over the last few weeks. I am aiming to make a mod about the diadochi wars. Here's some early screens:

https://i.imgur.com/NN7MP.jpg (http://imgur.com/NN7MP)
https://i.imgur.com/oTvCL.jpg?1 (http://imgur.com/oTvCL)

rickinator9
10-16-2012, 10:59
From the 1.07 changelog:
FOR MODDERS:
- IMPORTANT: Added 'inherit_chance' to traits, replacing 'congenital'
- The 'replace_path' bug is now fixed for real
- Added 'effect' character history command. It's like an event option that's run for the character at game start.
- Fixed a bug with 'immortal' traits and sex appeal
- Added trigger 'leads_faction'
- Added trigger 'faction_power'
- Added trigger and effect 'any_faction_backer'
- Added trigger 'completely_controls = [title]' (I or my vassals hold everything in it)
- Added trigger 'revolt_distance'
- The 'ai_will_do' clause in Decisions is no longer binary (the value determines the MTTH)
- Fixed an issue with law triggers in the 'ai_will_do' field of decisions
- Added trigger 'in_faction'
- Added trigger 'war_title'
- Added trigger 'defending_against_claimant'
- Added event targets 'supported_claimant' and 'supported_claimant_title'
- Added 'set_parent_religion' effect
- Can now create Lowborn characters with the 'create_character' effect
- Fixed a bug with scripted attributes in the 'create_character' effect
- Fixed a bug in the 'conquest_culture' trigger
- Added 'is_conquered' trigger
- Added event targets 'heir_under_seniority_law' and 'heir_under_primogeniture_law'
- Added trigger 'any_claimant'
- Added 'from_potential' trigger to decisions (vassal and dynasty decisions only)
- Added event effect 'add_spouse_matrilineal'
- Added 'opinion_diff' trigger
- The event targets 'owner' and 'holder_scope' are now the same and work on both titles and provinces
- Added event effect 'copy_title_history'
- Added event effect 'copy_title_laws'
- Fixed a bug with trigger 'is_landed = no'
- Fixed a bug in the effect 'spawn_unit' with the 'match' argument
- Can now set a specific leader in the effect 'spawn_unit'
- Fixed a bug in trigger 'de_jure_liege_or_above'
- Fixed a bug in trigger 'de_jure_vassal_or_below'
- Fixed some bugs with the 'set_name' effect
- The 'set_name' effect can now change the name of titles
- Added 'capital' effect
- Added 'province_capital' effect
- Added effect 'participation_scaled_decadence'
- Added trigger 'num_of_faction_backers'
- Added trigger 'race'
- Added trigger 'graphical_culture'
- Fixed a bug with event name spaces not working in 'events' fields in On Actions
- Fixed a bug with event name spaces not working in 'events' fields in Job Actions
- Added 'divine_blood' marriage opinion modifiers
- Added more gradual Attrition Defines
- Added 'secondary_graphical_culture' to cultures and culture groups (a fallback option, when not having certain DLCs)
- Added trigger 'has_earmarked_regiments'
- Added 'earmark' argument to the 'spawn_unit' event effect
- The 'disband_event_forces' effect now takes an earmark argument
- Added trigger 'diplomatic_immunity'
- Added effect 'diplomatic_immunity'
- Exported PORTRAIT_MID_AGE_THRESHOLD, PORTRAIT_OLD_AGE_THRESHOLD, PORTRAIT_ADULT_MALE_AGE_THRESHOLD and PORTRAIT_ADULT_FEMALE_AGE_THRESHOLD to defines
- Exported AGE_OF_MARRIAGE to defines
- Ported the last old defines to lua
- Added SeaZone province text promotion
- Added PrevPrev text promotion
- Added trigger 'is_tribal_type_title'
- Added trigger 'has_horde_culture'

Namorax
10-25-2012, 17:02
Hi, I wanted to ask a small question about traits and how to make them "congenial only":

The idea was to have a trait like "Arthurian Blood", which can only be selected with the Ruler Designer and is always passed on to all your children. There is no w for anyone else to get this trait except for marrying into the bloodline.
On the one hand you get a small stat-bonus but on the other hand this means your family-members are a bit more dangerous. Anyway, I wanted to try this but I cannot make the "restriction" work...
Either none of my children get the trait, or they do and somewhere in the world others with the same trait are popping up, even if their parents dont have the trait.

My current trait-code looks like this



bloodline00 = {
inherit_chance = 100

health = 1
fertility = 0.5
vassal_opinion = 10
}


I tried experimenting with various conditions listed on the CKIIwiki, but they either cause my game to crash or dont have the wanted effect. Any ideas on how to do this? Apparently the condition "is_child_of" is the solution I am looking for but I am not sure how to use it...

Monk
10-25-2012, 17:30
I tried experimenting with various conditions listed on the CKIIwiki, but they either cause my game to crash or dont have the wanted effect. Any ideas on how to do this? Apparently the condition "is_child_of" is the solution I am looking for but I am not sure how to use it...

I've never messed with traits but a couple of ideas come to mind after doing a few quick code experiments. You want to define that the trait is only giftable at birth which may be why people are popping up in other parts of the world with the trait.

The game randomly generates characters to inhabits courts whenever conquests happen and everyone previously was thrown out. Like in the case of holy wars. All of those characters get randomly assigned traits unless they get stopped by flags. Likewise, without a congenital flag, it's possible the game thinks you're trying to make a general birth gain trait, like Genius or Clubfooted.

Try making your code look like this:



bloodline00 = {
congenital = yes
birth = yes

health = 1
fertility = 0.5
vassal_opinion = 10
}


You've already told the game that 1 it's congenital and 2 the only way to get it is from birth. Leaving 'inheritance chance' in is redundant for what you want to accomplish, i believe.

rickinator9
10-26-2012, 13:40
You've already told the game that 1 it's congenital and 2 the only way to get it is from birth. Leaving 'inheritance chance' in is redundant for what you want to accomplish, i believe.

Inheritance_chance is the 1.07 replacement for the random congenital tag. The guys who get the trait randomly must be the guys who also get generated randomly. Maybe add a potential:


bloodline00 = {
inherit_chance = 100

potential = {
OR = {
father = {
trait = bloodline00
}
mother = {
trait = bloodline00
}
}
}

health = 1
fertility = 0.5
vassal_opinion = 10
}

Of course, you could always hand it out through an event. Events are one of the best ways of handing out traits.

Namorax
10-26-2012, 14:53
Well, it seemed to be simpler to pass the trait on via children... I didnt want to have an event everytime a child gets born, and furthermore I dont know how to do that^^
Rickinator appears to be correct monk since your version had no effect, as in nobody gets that trait except when they I trigger the event.


bloodline00 = {
potential = {
OR = {
father = { trait = bloodline00 }
mother = { trait = bloodline00 }
}
}
inherit_chance = 100

health = 1
fertility = 0.5
vassal_opinion = 10
}

Changed the trait to this version, but now the gamecrashes when I try to start. Removing the "mother/father = "-part allows the game to start properly again. Any ideas why this happens?

PS: You're both right. Apparently the game tries to use the trait for randomly generated (new) characters.

Edit: The Sword of Islam DLC has a trait that gets inherited from father to son (agnatic=yes)... now I just need to find a way to do the same for mother to daughter

Namorax
10-26-2012, 21:14
ok, I'm about to throw the towel here... the only way this worked halfway was to give the trait the agnatic-flag by setting that to "yes".
The only problem is that this completely ignores female children since they wont get the trait at all. The males get the trait and give it to their children. why didnt they include a cognatic flag! >_<

The father/mother-conditional (and a few others) appear to break the game by crashing it on load. After spending the last 8 hours on testing various potentials I have nothing left. All I know is that unless the potential or whatever I use instead is explictly true, nobody will ever get that trait. Tested this with various different rulers of both genders and lots of children.
Unless I write inherit_chance=100 none of my children will inherit the trait. But this causes the game to think that 100% of all children generated deserve that trait.

I still dont understand why potential doesnt accept father/mother as condition. I tried to change my approach and experimented with liege/any_dynasty_member and other words offered by the Scopes-List on the ckii-wiki...
Its Either everyone, males only or nobody... does anybody have another idea on how to achieve this?
I mean, if I try to fire an event whenever a child is born from somebody with that trait... wouldnt I need the same potential-clause as for the trait?

(Btw, I forgot to mention this, but thanks for your fast answers^^)

Monk
10-26-2012, 22:03
ok, I'm about to throw the towel here... the only way this worked halfway was to give the trait the agnatic-flag by setting that to "yes".
The only problem is that this completely ignores female children since they wont get the trait at all. The males get the trait and give it to their children. why didnt they include a cognatic flag! >_<

Ah the Sayyid work around! I was about to suggest that myself if my first suggestion didn't pan out, and it looks like it didn't. Sorry to hear that.


I mean, if I try to fire an event whenever a child is born from somebody with that trait... wouldnt I need the same potential-clause as for the trait?

Not necessarily. You could set the event to check specifically to scan the scope of the parents' traits with something like:



#Child is born of Aurthorian Blood
character_event = {
id = 3000000
desc = EVTDESC3000000
picture = GFX_evt_birth

max_age = 1
trigger = {
OR = {
father_even_if_dead = { trait = bloodline00 }
mother = { trait = bloodline00 }
}
NOT = { trait = bloodline00 }
}

mean_time_to_happen = { days = 1 }

option = {
name = EVTOPTA3000000
trait = bloodline00
}
}

This codes an event to scan a child's parents' traits, even if the father in question is dead, and applies the trait you desire. Not exactly what you might be after, but it might be worth looking into. Rick may know more as he's been in and out of the traits files for a while now.

Honestly I'm surprised what i suggested before didn't work as the code example I gave you worked as late as 1.06b. One of my favorite silly mods used it to great success. They must have done some switches around in the code that broke a lot of stuff in the new patch. Shame ~:(

Sorry I can't be of more help.


edit: I lamented the lack of a "mother even if dead" tag but the event I gave you should cover most of what you need. I revised it a bit and added a mother = tag.

edit2: yeah way to go monk. Give someone an event that doesnt work. Added an OR tag like i should have in the first place to the triggers

rickinator9
10-27-2012, 02:45
#Child is born of Aurthorian Blood
character_event = {
id = 3000000
desc = EVTDESC3000000
picture = GFX_evt_birth

max_age = 1
trigger = {
OR = {
father_even_if_dead = { trait = bloodline00 }
mother = { trait = bloodline00 }
}
NOT = { trait = bloodline00 }
}

mean_time_to_happen = { days = 1 }

option = {
name = EVTOPTA3000000
trait = bloodline00
}
}

Should be:


namespace = blood

#Child is born of Aurthorian Blood
character_event = {
id = blood.1
desc = "blood.1.desc"
picture = GFX_evt_birth

max_age = 1
trigger = {
OR = {
father_even_if_dead = { trait = bloodline00 }
mother = { trait = bloodline00 }
}
NOT = { trait = bloodline00 }
}

mean_time_to_happen = { days = 1 }

option = {
name = "blood.11.option"
add_trait = bloodline00
}
}
I would always advise you to use namespaces. They work great for compatibility with other mods and official PI patches.
'trait =' is a condition which checks if someone has the designated trait. 'add_trait' is a command which adds the designated trait to the character.

Monk
10-27-2012, 03:10
I would always advise you to use namespaces. They work great for compatibility with other mods and official PI patches.

Well, that's your personal preference. 3,000,000 is high enough that paradox wont hit it with their numbering scheme, so the only concern is mod compatability


'trait =' is a condition which checks if someone has the designated trait. 'add_trait' is a command which adds the designated trait to the character.

Correct, my mistake. :inquisitive: not really sure what I was thinking there, coded dozens of trait events for tweaks mod without issue. Ah well. Probably just out of practice.

Namorax
10-27-2012, 10:15
Okay, I added the event and it appear to be working. I'm currently playing a testgame and its the 10th year right now with no complications. Now I need to see how far it spreads^^
Thanks everyone!

Namorax
10-27-2012, 22:53
Ok, it works perfectly. I had to try around with the event at first since it screwed up the whole text for the game^^
But now I hve it working and I will try to experiment with other conditions to deal with minor things that bug me... For example: After a few generations, there will be people in your realm that are distantly related to you. They still have the trait but your relation to them is so distant, they're not even registered as "kinsmen" anymore. I would like to have them stop spreading the bloodline-trait around, with the reasoning that their bloodline is distant enough for the effects to be diluted and vanishing.

Is there a way to check what the inheriting person's degree of relation to you is?

Beskar
10-29-2012, 02:46
I am having a courtier issue at the moment. I have like 80, and every time I get rid of some, some more tend to end up flocking to my court from other places.

Trying to think of an event which will be able to "kill" all members of my immediate court which are not my dynasty, perhaps? Trying to think of how to get the scopes to do something similar to that.

I am guessing culture/religion scopes would be good as well so it isn't overpowered.

(Starting it off simple first. One of the issues is the fact the high courtier rate is killing my children off.)

rickinator9
10-30-2012, 11:57
Although I can't help you right now, I usually sit in the CKII modding IRC at #ckii with rizon as the 'IRC provider'. There will be some other people who can help you there. Also, instead of an event, why not use an decision?

mrguymiah
11-20-2012, 03:29
Could I get some help with this mod I'm working on? I am having a hell of a time getting my new map to work. I am creating a completely new map. I am just trying to create a single county surounded by a sea. I have not changed the pixelxpixel size of any of the images and have added entries into the history folder for the baronies and the county (do I have to create a duchy and kingdom to go along with it?) and created default characters to fill the two leadership positions. The game freezes at "Initialising Maplogic". The game works without the mod, so I believe that rules out it being a cache error.

EDIT:Just realized that I hadn't been doing anything with the default.map. I assume that must be the problem. I can't figure out how to open it, let alone edit it.

Please and thank you for any assistance.

mrguymiah
11-20-2012, 03:53
EDIT: Double posted, I apologize.

rickinator9
11-20-2012, 21:45
Use Notepad++ to open it. Let's see the list of what you need to do with custom mapping:
- Empty positions.txt
- rivers, terrain, topology and trees need to be indexed in their very own color index.
- adjacencies.csv just needs to have:

From;To;Type;Through;Comment
-1;-1;-1;-1;x

mrguymiah
11-20-2012, 22:11
Use Notepad++ to open it. Let's see the list of what you need to do with custom mapping:
- Empty positions.txt
- rivers, terrain, topology and trees need to be indexed in their very own color index.
- adjacencies.csv just needs to have:

From;To;Type;Through;Comment
-1;-1;-1;-1;x

First of all, thank you for your help (and so quickly too!).

My positions.txt was already empty (filled with the info for the new province (which I remembered to flip map before getting the coordinates)). It turns out I forgot to re-index topology after I was done editing. I fixed that. I didn't know that I had to do that with adjacencies.csv, so I fixed that.

Now, my mod loads past "initialising maplogic", but is failing when it gets to "Creating Rivers". I thought this may be due to having no rivers in the map whatsoever, so I placed one. The problem persist. I checked the error log and here is what I get:


[persistent.cpp:40]: Error: "Malformed token: .10, near line: 3673
Malformed token: .25, near line: 3674
" in file: "common/buildings/00_buildings.txt" near line: 3677
[persistent.cpp:40]: Error: "Malformed token: .15, near line: 3689
Malformed token: .25, near line: 3690
" in file: "common/buildings/00_buildings.txt" near line: 3693
[persistent.cpp:40]: Error: "Malformed token: .20, near line: 3705
Malformed token: .50, near line: 3706
" in file: "common/buildings/00_buildings.txt" near line: 3709


I tried disabling rivers in the settings.txt, but that did not fix the error. I am now checking to see what it is talking about in 00_buildings.txt.

EDIT: I fixed the 00_buildings.txt. I hadn't realized that all decimals must have something before the .decimal (in this case a zero). That has been fixed. It is still crashing at creating rivers. error.log is empty, but here is the graphics.log:



[provincetemplate.cpp:237]: Province 0 has invalid origin

rickinator9
11-20-2012, 23:44
Could you upload the map files somewhere for me to see?

mrguymiah
11-20-2012, 23:48
Yeah, one moment, please.

EDIT: Here you go: map files put into a .zip (http://www.mediafire.com/download.php?1f1w2bidwihssyy)

rickinator9
11-21-2012, 20:21
mrguymiah:
Fixed, you didn't have the valid color tables for the indexes.
Ponymod.rar (http://dl.dropbox.com/u/43307151/ponymod.rar)
The european shape is probably the work of the colormaps. You'll have to edit those yourself. You should also raise your provinces a bit through topology.

mrguymiah
11-22-2012, 01:20
So you went into the text files and edited the index? I'll have to remember to do that. Thank you for the assist!

EDIT: Did you try starting a new game with this map? I tried and it failed. I went back and realized that I wasn't overwriting the history files, so I adjusted my .mod. Had to go back and adjust when I realized I had two different names for the castle barony, so I fixed that. Now, I can select the count and hit play, but it crashes when 'adjusting history'. Any clue as to what's wrong? Do I have to replace every file in the 'history' folder to resolve this?

rickinator9
11-22-2012, 12:31
I didn't get that far. My map did that too.

mrguymiah
11-23-2012, 01:46
I've got it! I was googling the problem when I ran across the ramblings of one Dr. Sunshine. This crazy man is creating a post-apocalyptic USA mod and ran into the same problem with his custom map. He thought to check the number for max provinces, the game doesn't like anything lower than the default 1036! I changed that number back and... BOOMB! It works! Though, after 3 days (in game) my screen was flooded with empty scrolls, forcing me to quit. Not to mention that every scripted character (The historical dukes, barons, kings, etc.) were all in my court!

alin.birzu
11-27-2012, 16:57
I'll need to reverse engineer it then and see what the hell they did.

The seamstress was designed to act like the court bishop's inquisition, only you can convert counties and characters to your culture. Sure beats having to wait decades for a county to convert on its own.


EDIT: BINGO! Found in the Avatars.gfx file.

EMFXActorType = {
name = "westerngfx_job_castellan"
actorfile = "gfx\models\Mapindicators\Western_Chancellor.xac"

idle = "gfx\models\Mapindicators\Western_Chancellor_Idle.xsm"
scale = 1.0f
}





I want to ask you if i can change the job_title "chancellar" and the other job titles to another one for example to "MareLogofat". I want to name job titles just for a specific country. Is it possible to do that? But still to keep the "chancellor" name for other countries. I managed to do part of it myself but something was still wrong,with both names "chancellor" and "mareelogofat" being shown simultaneously. Still,i am not a moding expert so this is why i need some help. And if you know how it can be done could you show me the steps that have to be done? Thanks in advance!

mrguymiah
11-27-2012, 17:45
If I understand correctly, you're trying to make everyone but a specific country have the "Chancellor" and that one country have "Mareelogofat"? Then, from what I gather in the example code, you would need to create a new culture group and its corresponding council members. I'm not too sure, though. That is not a lot of code to go on and I have not modded the council members before.

alin.birzu
11-27-2012, 20:23
If I understand correctly, you're trying to make everyone but a specific country have the "Chancellor" and that one country have "Mareelogofat"? Then, from what I gather in the example code, you would need to create a new culture group and its corresponding council members. I'm not too sure, though. That is not a lot of code to go on and I have not modded the council members before.

http://tinypic.com/r/1z2k5ll/6

For now i managed to mod the minor titles. But back at the chancellar thing,wouldn't it be possible to edit the chancellar description to avoid it being shown for a certain country,relligion or culture just as in the music dlc,for example:
song = {
name = "thebyzantineempire.ogg"

chance = {
factor = 2
modifier = {
factor = 0
NOT = { culture_group = byzantine }
}
}
}

I tried this but can not make it work, using something similar to this "NOT = { culture_group = byzantine }". I must miss something.
Now it crossed my mind,it is exactly like for muslims, if you look there instead of "chancellar" they have "grand vizier" but i can not find the that changes chancellar into grand vizier. Have a clue about where i can find it? Perhaps in the DLC?

alin.birzu
11-27-2012, 20:26
http://oi47.tinypic.com/1z2k5ll.jpg

alin.birzu
11-27-2012, 20:29
I found this job_chancellor_arabic;Grand Vizier;Grand Vizir;Großwesir;;Gran Visir;;;;;;;;;x
and another one job_spiritual_judaism_group;Chief Rabbi;Grand Rabbin;Groß-Rabbi;;;;;;;;;;;x;;;
in localisation file.
I will give it a try,but i think this is the answer :)

alin.birzu
11-27-2012, 21:06
I found this job_chancellor_arabic;Grand Vizier;Grand Vizir;Großwesir;;Gran Visir;;;;;;;;;x
and another one job_spiritual_judaism_group;Chief Rabbi;Grand Rabbin;Groß-Rabbi;;;;;;;;;;;x;;;
in localisation file.
I will give it a try,but i think this is the answer :)



I did it man,that was the answer,finally :) i just put these in two separate localisation files:
job_chancellor_south_slavic;Mare Logofat;Mare Logofat;Mare Logofat;Mare Logofat;;;;;;;;;x

and changet the description like this:
job_chancellor_south_slavic_desc;The first boyar from the council that lead the lord cancelary.When both the lord or archbishop where absent he presided the cancelary.;;;;;;;;;;;;;x

Perhaps you also would like to do this. For you to know,thanks anyway!

alin.birzu
11-27-2012, 21:08
http://oi47.tinypic.com/5l2q07.jpg

rickinator9
12-11-2012, 22:08
Some progress on the Diadochi mod.
https://i.imgur.com/I6rzO.jpg

I fixed some errors, a lot of them with the map. I deleted a file called Pdoxmap.lua which was making the map very bright. I fixed the history so stuff would not bug out.

The satrapies are now still independent, as I haven't made the Babylon province yet(where the king/emperors reside). The bad province names in Asia Minor is caused by broken localisation because I am too lazy to edit that for now. I will be using the french language slot for native province names, for example:
- Tarentum -> Taras
- Athens -> Athenai

mrguymiah
01-09-2013, 22:20
If you look at the pictures, you can see the problem. That is the result of putting anything on the topology file. I have no clue what is causing it and though you might.

https://i1085.photobucket.com/albums/j440/Nehemiah_Kenny/ck2_1_zps5569e516.png
https://i1085.photobucket.com/albums/j440/Nehemiah_Kenny/ck2_3_zpsd9357c86.png

To Clarify, I'm trying to make a custom map and this is what happens whenever I try to load the game. It is not rendering the ground and there is river being rendered where the ground should be but below the waterline. I have no idea what is wrong. I disabled rivers in my settings file and no fix. I re-enabled them and they no longer replace land but there is nothing being rendered there still.

mrguymiah
01-10-2013, 01:12
For those who need it, here is the mod's current build http://www.mediafire.com/?qycvq2wqmfjyzbm.

Slvrbuu
01-19-2013, 21:56
I was wondering if anyone can help me. I'm trying to make an event for council members with unique options that will only be available to council members of the player, but the rest can be executed by ai. For this instance I'd like to give the player's council a unique way of completing an event.

Something like:

option = {
name = "test"
trigger = {
liege = {
is_player = yes
}
}
scaled_wealth = -0.5
hidden_tooltip = {
remove_trait = test
liege = { character_event = test.0 days = 365 }
}
}

I know that's not an actual condition but was just an example.

mrguymiah
01-23-2013, 03:37
Updated link: http://www.mediafire.com/?f4x1c8f6nelxii8

As for your problem Slvrbuu, I apologize I have a clue as to where to start with your problem. I understand that you want to have unique options available based on the skill of your council members. Your condition would be a simple skill check, but I don't know what the variable name for your council members skills are. I would check the council member actions (Such as the Chancellor's fabricate claim) and check what they base the success chance on. You'll probably find the variable you need there.

rickinator9
01-26-2013, 02:40
Slvrbuu

I would advise you to go to http://forum.paradoxplaza.com/forum/showthread.php?589686-Modding-Quick-questions&p=14917464#post14917464 . That's a thread on the Paradox Forums which is pretty much made for questions like this.

Commander19
03-26-2013, 16:47
Hey I really want to learn how to Mod CK2. Could someone please teache me how to do it step by step??

rickinator9
03-30-2013, 17:28
Hey I really want to learn how to Mod CK2. Could someone please teache me how to do it step by step??

Depends on what part of CKII you want to mod. I started with events and later moved on to mapping. I now know how to mod most of CKII.

Monk
03-30-2013, 21:05
Depends on what part of CKII you want to mod. I started with events and later moved on to mapping. I now know how to mod most of CKII.

That's pretty much how I did it, minus the mapping. Started with events, moved to history files, landed titles and so on. There's tons of information on the CK2 mod forums, but mostly I've found modding ability comes by necessity. You want to do x, so you learn how to implement it. I wanted to make some event chains so I learned how to code events. I wanted to balance Iberia so I messed with history, tech levels in defines.lua, and buildings. I wanted to force armor on characters in command.. ect. ect.

So yeah, what would you like to mod? :yes:

Ibn-Khaldun
04-22-2013, 05:09
I had an idea for the ERE that once I create the Roman Empire then the Emperor will be able to recruit old legion style armies (some 4-5 mercs units that are only available to the Roman Emperor just like the Varangian Guards) and vassals will get a small recruitment/levy penalty. But is it possible to do this?

Pethom
04-23-2013, 17:26
Hello to everybody from a new member,

I'm using the mod CK2+ when playing Crusader Kings 2. In this mod you can employ a Marshal, a Chancellor, a Priest and a Steward. A priest costs 10 piety and all other cost 20 gold. The bad thing is that their skill is random. So when I pay 20 gold for a Chancellor I maybe get one with the skill of 2 in diplomacy. Paying 20 gold for such a lousy Chancellor is way too expensive.

I have now been thinking about changing the cost of employment to 10 gold but also make the characters I employ better at their work. The random skill in diplomacy, of for example the Chancellor, would be from 10 to the max skill (which is what 20?).

The example from the specialist_decisions.txt from the CK2+ mod has the lua script "random_traits = yes". I guess this part is what I have to edit to give the chancellor a random skill of 10 to the max skill (20?). I probably have to make it "random_traits = no" and even add what trait the new chancellor should have or keep "random_traits = yes" and add something to make it a random between 10 to max (20?). But how do I give the Chancellor a random skill between 10 to the max skill (20?)?

Maybe anyone of you experienced CK2 modders could give me some help with this and tell me what editing there is to be done to make the change I'd like to have?

A small part of the specialist_decisions.txt is in the spoiler.

decisions = {
employ_chancellor = {
potential = {
ai = no
is_ruler = yes
}
allow = {
NOT = { has_character_modifier = employment_timer }
treasury = 20
}
effect = {
treasury = -20
create_random_diplomat = {
random_traits = yes
dynasty = random
female = no
}
add_character_modifier = {
name = employment_timer
duration = 180
hidden = yes
}
}
revoke_allowed = {
always = no
}
ai_will_do = {
factor = 0
}
}

}


I also have a question when it comes to the Tyrant trait and the heir inheriting that trait when the Ruler dies.

I had earlier an issue when my Ruler became a tyrant, caused by banishing two or three Dukes (and relatives) who constantly caused problems. When I hovered over the tyrant symbol it gave the info that tyranny goes away at the rate 5 points every 5 years (1 point every year) and my Ruler had 70 points of tyranny.

The tyrant Ruler (Ruler [T] as in tyrant) was later on removed by other vassals in a revolt where they forced him to abdicate and put his son (Ruler [H] as in heir) on the throne. Ruler [H] inherited the tyrant trait along with all the titles and holdings from Ruler [T]. That meant that Ruler [H] was viewed as a tyrant for 70 years (if he would live that long) for something his dad did. The vassals of Ruler [H] had an opinion of him by -100 percent, caused by his dad being a tyrant and him inheriting that trait, and their opinion of the new Ruler didn't change in the positive way although he didn't rule in a bad way.

If Ruler [T] is a tyrant and gather a stack of tyrant modifier opinions I don't think it's a good solution to let Ruler [H] suffer from that too much. A better solution could be to let the vassals be suspicious to Ruler [H] in the beginning of his rulership (They might kind of think "What if he's just the same as his father?") and during the first years of his rulership he could get different events where the desicions made deside if Ruler [H] is going to stay as a tyrant or lose that trait within maybe three or five years. The timespan three to five years could be the time required for the vassals to understand, caused by the desicions made to the events presented to the player, that ruler [H] isn't like his dad.

Some more of this in the spoiler:
If for example Ruler [T] is a tyrant and his heir becomes the new Ruler an event could pop up for the player with a few choises. This event could maybe be something like: Ruler [T] had the tyrant trait with an opinion of -50 by his vassals. Do you as the new Ruler want to follow the way of Ruler [T]? After that the player has two or three options to chose from.

Option 1 - The heir is approving the way of Ruler [T] and will continue in the same way giving result A (The vassals will have the same opinion of him as they had for Ruler [T].)

Option 2 - The heir will not follow the way of Ruler [T] giving result B (The vassals won't hate him as they hated Ruler [T] and improve their opinion of him quicker if he proves to be a better Ruler. Different events should pop up which would make the vassals' opinion of the new Ruler improve or stay as it is depending on the desicions made by the Ruler)

Option 3 - The new Ruler hasn't decided yet how he will rule giving result C (There is a 40 percent possibility that the vassals might transfer their opinion of Ruler [T] to him, 30 percent possibility that they will gradualy think better of him and 30 percent possibility that they will think better of him in the hope that he's better than Ruler [T]. The vassals' opinion of him will improve by time if he doesn't rule in a bad way - the desicions made by the Ruler in different events will decide the Vassals' opinion of the new Ruler).

I don't know much of the lua script and how it works in CK2. But I think there would have to be tags something like:

is_ruler = yes
has_inherited_trait_tyrant = yes
...

has_banished_vassal = no
has_executed_vassal_unlawfully = no
...

Then there should be some events triggered to pop up for desiding whether or not Ruler [H] deserves to be free from the tyrant trait. If Ruler [H] fulfils the events in a positive way the tyrant trait should be changed to a lower one. It could probably be something like:

remove_trait_tyrant = tyrant10 = {#168
add_trait_tyrant = tyrant8 = {#166
(the numbers of the different tyrant traits are found in the file ck2plus_traits.txt in mod\CK2Plus\common\traits)


I've been thinking a bit about the homosexual trait. We have in Sweden had two kings who were homosexual, maybe one of them was bisexual but prefered men. Both of them had to marry and produce an heir for the sake of the dynasty and the Kingdom. Sometimes I see male and female characters in CK2 who could have become good spouses to my ruler's children and sometimes my ruler gets a child who is homosexual, maybe even the heir. I have also noticed that a character who is homosexual, and doesn't want to get married, sometimes, but seldom, produces children anyway.

It is of course good that a homosexual character sometimes can produce children. But it would be interesting if there was a possibility for the Ruler, through the diplomacy option, to tell a homosexual character that he expects of him/her to produce children for the dynasty. The effect to this could be that the homosexual character should loose trait_homosexual and instead get trait_chaiste and maybe even trait_depressed or maybe trait_stressed or something else to picture the reaction of that character when being forced to live with the ruler's expectation as a Democle's sword over his/her head.

Every event has a picture with a text under it and sometimes different choises for the player. Where do I find these pictures to chose which picture is best to what event?

Alexander the Pretty Good
05-18-2013, 13:06
So I woke up this morning with a vague idea of adding kidnapping to CK2. I'm not sure yet whether it would be more fun as a plot or as an action you can take from the diplomacy screen (or both, ala assassinations). It would sort of be like the imprison mechanic but it would be based on intrigue and you could (theoretically) target people outside your court and vassals.

My questions are - is something like that possible, and would the AI know how to do it?

Pethom
05-31-2013, 17:13
So I work up this morning with a vague idea of adding kidnapping to CK2... is something like that possible, and would the AI know how to do it?I'm pretty sure you have that option in the mod CK2+ or maybe it's in the AGoT mod. Download and check them out.

Magnus360x
06-06-2013, 05:40
hi i'm new to this whole thing. I'm trying to create an event similar to the one posted above where my direct children are the ONLY children to inherit my trait called "Legendary" This i what i got thanks in advance.

character_event = {

id = 4
desc = "The ghost of an ancient soldier bestows his gift upon you."
picture = "GFX_evt_knight_kneeling"
border = GFX_event_normal_frame_religion

max_age = 1
trigger = {
AND = {
is_child_of = ROOT
father_even_if_dead = { trait = Legendary }
}
NOT = { trait = Legendary }
}
mean_time_to_happen = { days = 1 }


option = {
name = "The spirit fuses with your own."
add_trait = Legendary
give_nickname = nick_the_magnificent


}
}

rickinator9
06-11-2013, 03:36
Looks good. Just a little comment on trigger. It's an AND in itself, so the AND you use is unnecessary.

Ibn-Khaldun
07-03-2013, 17:39
Is it possible to change triggers or conditions to the "Offer to Join War" diplomatic option so that I could join wars of my vassal kings? In my Byzantine Empire game I have Georgia as my vassal but their ruler just attacks enemies they can't win! For once I would like to see him succeed.