• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Crusader Kings III Dev Diary #55 - Modding Improvements

Good afternoon, all

I’m here today with a short dev diary on some upcoming improvements to moddability. We’re not quite ready yet to make any announcements about upcoming features and so on, but we thought you might be interested in hearing about some modding improvements we've been working on.

In an upcoming patch which I will from now on call 1.3.X (due to the exact version number being unknown at this time), we’ve spent a bit of time on making the game more moddable based on requests we’ve had from the modding community. In particular we would like to thank the Modding Co-op for coming up with a curated list of requested functionality. The curation of this list made it easy for us to get a good overview of what functionality the community would like, and limited to those requests that’d benefit a lot of modders rather than just a handful. As the amount of time we could spend on modding improvements this time around was rather limited, having an already curated list to pick from was great.
From that list we picked some of the simpler requests; things that’d require relatively minimal code and would only affect mods. We will likely implement more from this list in the future, though our list for 1.3.X is unlikely to expand.

In addition to implementing some functionality based on these requests, we’ve also had some conversations with modders, and looked at some common pain points. We can’t address most of them right now, but one we noticed is that a number of mods use the DummyMale and DummyFemale characters for a lot of things they weren’t meant for. This was a result of lacking functionality, which we have now introduced in 1.3.X.
With the need for this dummy-character removed, we will be deprecating it. That means that it’ll continue to work 1.3.X which introduces the replacement functionality, but that they will be largely removed in 1.4 to ensure that script and code are more maintainable in the long-term.

Another bit of functionality that we think modders will be interested in is that of same-sex concubinage. Proper support for
it will come alongside other modding improvements in 1.3.X. Before 1.3 the gender restrictions for concubinage were possible to work around (but could cause bugs), which is no longer possible in 1.3. In 1.3.X we support it more fully, eliminating odd edge-case bugs and the like.
Further, we plan to support same-sex marriage for mods in 1.4. Due to larger technical risks surrounding it, it was not feasible to include that in 1.3.X; we need more time to test it to ensure that this support does not introduce bugs in the vanilla game. We're really looking forward to being able to support more diverse experiences with this mod support.

Mods add so much to the experience of our games, and moddability has been something we’ve considered throughout CK3’s development. As a former CK2 modder myself, it’s great to see all the things the modding community is producing.

Finally, here’s all the modding improvements we plan to release in 1.3.X:
- User Modding: Add CloseGameView data function so mods can close specific in game views.
- User Modding: Add GetTraitFromGroup and GetTraitGroupLevel data functions on Character.
- User modding: make_concubine now supports same-sex concubinage
- User Modding: Add GetTraitGroup( 'tag' ) and Trait.GetGroup data functions to get trait groups.
- User Modding: Add HasTrait and HasTraitFromGroup data functions to Character.
- User modding: Added data functions GetTraitsWithFlag and GetTraitsWithoutFlag
- User modding: Added datamodel GetTraits on TraitGroup
- User modding: Added effect deactivate_holy_site
- User modding: Added effect remove_dynasty_perk
- User modding: Added effect remove_innovation = innovation_key
- User modding: Added effect set_army_location
- User modding: Added effects clear_traits and copy_traits
- User modding: Added effects set_age and change_age
- User modding: Added list builder x_culture_global
- User modding: Added trigger has_innovation_flag
- User modding: Added trigger perks_in_<lifestyle>, to query how many perks exist in a given lifestyle (rather than how many a specific character has)
- User modding: spawn_army will now only spawn levies if scripted to do so
- User modding: Add GetGlobalVariable and GetGlobalList data functions for getting data saved from script.
- User modding: Add MakeScopeValue, MakescopeFlag, and MakeScopeBool to create scope objects out of primitive types directly since they are not automatically creatable via the MakeScope member on complex types like Character.MakeScope.
- User modding: Add ScriptValue data function to scope objects which will evaluate a script value just with that scope object as root.
- User modding: Made the Localize data function allow the key it references to also call other data functions in it like SelectLocalization does.
- User modding: Add AddList data function for GuiScope, it is to add_to_list what AddScope is to save_scope_as.

That’s all for today! I’m excited to see what the modding community will do with these added pieces of functionality.
 
  • 92Like
  • 29
  • 25
  • 9
  • 6Love
  • 1Haha
Reactions:
Looking at last week's announcement I had great expectations for this one. Sadly it was not to be.

But great for modders no doubt.

And I am glad we're getting another 1.3 patch. Thats great and unexpected.
 
  • 51
  • 6Like
  • 5
Reactions:
It is good to see the same sex modding options coming in future updates.

I will still like to ask that these options be added to the base game as a religious tenet that could be selected when you reform your faith or create a new one (as others have pointed out some of the options available when you reform your faith can lead to highly ahistorical outcomes anyway). I am aware that same sex marriage would, under the game rules, lead to a game over so perhaps same sex marriage would only be allowable with concubinage/polygamy?

Still, glad to see the options so far.
 
  • 35
  • 12
  • 4Like
Reactions:
For all the extra materials mods provide to give unique and alternative gaming experiences from that of the base game, I think its awesome PDX is supporting that. Excellent work, I think? As I don't mod myself, I am unsure what I am looking at, but it must be great news to someone out there.
 
  • 11
  • 4Like
Reactions:
Added effect remove_innovation = innovation_key
Very nice
Added list builder x_culture_global
Aaaaah, I've asked for it since day 1, cool to see it being added!
spawn_army will now only spawn levies if scripted to do so
Very nice!
Added trigger has_innovation_flag
Very nice, anything that removes direct innovation checks is good
 
  • 8Like
  • 3
  • 1
Reactions:
It is good to see the same sex modding options coming in future updates.

I will still like to ask that these options be added to the base game as a religious tenet that could be selected when you reform your faith or create a new one (as others have pointed out some of the options available when you reform your faith can lead to highly ahistorical outcomes anyway). I am aware that same sex marriage would, under the game rules, lead to a game over so perhaps same sex marriage would only be allowable with concubinage/polygamy?

Still, glad to see the options so far.

While alt-history is an important aspect of Crusader Kings, I feel like same-sex marriage is a bit too ahistorical. After all, same-sex marriage wasn't legalized anywhere in the world until the year 2000 (even if there are occasional instances of same-sex unions, mostly from the 1970s onwards). That said, I would not be opposed to same-sex concubinage in the base game, as that would be a more 'official' relationship in a faith that is polyamorous and accepting of same-sex relationships.

And of course, I'm very glad to see same-sex marriage for modding as an option on the horizon, more modding options is always better! (and despite my argument above, I won't rule out that I may download a mod that implements it at some point in the future)
 
  • 31
  • 25
  • 4Like
  • 1Haha
Reactions:
I wonder what was initially planned for this DD one week ago (because no sane person with describe this as "goodies for everyone"). Still, I'm happy that the modders got new toys. Really waiting for 1.3.X (and the inevitable 1.3.X.Y hotfix :p).
 
  • 17
  • 3Like
Reactions:
It's good to see improvements being made to modding.
 
  • 17
Reactions:
Love the attention for modding. I'm a very selective user of mods myself, but do appreciate all the work that goes into them.

That being said, this of course seems very much like a last minute DD or part of a larger intended update (1.3.X) that simply wasn't ready. As a head of productowners myself (alas not in gaming but financial industry) I do know a thing or two about managing expectations and would always try and refrain from any predicitons (if you are not 95% sure of delivery). But you don't need me telling you that. I'm sure something came up. Something almost always does.

I would like to say (not complain, just note) that I would be very interested in any news concerning the expansion. As many here on the forum I bought the Royal Edition and am still eagerly awaiting any news on what it is I bought. Again, not as a complaint, simply to inform you this would be the most desired topic to receive information on from my end.

Good luck and godspeed !
 
  • 16
  • 1Like
  • 1Haha
Reactions:
There's only 5 dev diaries until the PDXCon... I wonder what you've prepared for us ;)
I think they actually won't show any content til the DLC reveal. It seems likely we will get a patch til PDXCon, which the next dev diaries will be about, and maybe the expansion right after, with devdiaries of the work behind it stretching into summer "Northern Lords" Style or ... expansion reveal at PDXcon -> Dev Diaries explaining mechanics -> Release around June
 
  • 8
  • 1
  • 1
Reactions:
Last edited:
  • 3Like
  • 3Haha
  • 2
  • 1
Reactions:
While alt-history is an important aspect of Crusader Kings, I feel like same-sex marriage is a bit too ahistorical. After all, same-sex marriage wasn't legalized anywhere in the world until the year 2000 (even if there are occasional instances of same-sex unions, mostly from the 1970s onwards). That said, I would not be opposed to same-sex concubinage in the base game, as that would be a more 'official' relationship in a faith that is polyamorous and accepting of same-sex relationships.

And of course, I'm very glad to see same-sex marriage for modding as an option on the horizon, more modding options is always better! (and despite my argument above, I won't rule out that I may download a mod that implements it at some point in the future)
I get the concern on it being too ahistorical, but I would counter this is also the franchise that decided an invasion by advanced Aztecs from the west was acceptable. In the base options for the game it also allows players to make nearly everbody gay as well, which is not only ahistorical but apresent.

I don't think it's going too much against the grain to allow players the fantasy of taking their faith down a gentler, more tolerant path than they otherwise did. It would be nice to be able to make that choice without having to rely on a mod. After all, if you happen to be playing a gay or bisexual monarch who COULD reform the faith of his nation to be more tolerant, why shouldn't she or he?
 
  • 39
  • 15
  • 1Like
  • 1
Reactions:
Can you please please please make hotkey modding work? By that I mean, changing the shortcuts.shortcuts file. It simply does not work at this moment. When adding a new shortcut to that file, copying that into a mod folder, it will simply not accept the changes. Nothing changes. Only when I directly write the changes into the actual shortcuts.shortcuts file in the game directory will it accept these changes.

Something is not working with the shortcuts file, when putting it into a mod directory. Pleeeeeease look into that. I don't want to cannibalize the screenshot hotkey for my console access mod anymore.
 
  • 5Like
  • 4
Reactions:
I think they actually won't show any content til the DLC reveal. It seems likely we will get a patch til PDXCon, which the next dev diaries will be about, and maybe the expansion right after, with devdiaries of the work behind it stretching into summer "Northern Lords" Style or ... expansion reveal at PDXcon -> Dev Diaries explaining mechanics -> Release around June
Yeah, that's definitely a possibility. Maybe one or two DD about the patch, including the patchnotes, and then a little blank period. But I don't think they would choose a "Northern Lords style", since the expansion will probably have much more content, so I'll go with your second option, dev diaries explaining mechanics and release around June.
 
  • 6
  • 2Like
Reactions:
I get the concern on it being too ahistorical, but I would counter this is also the franchise that decided an invasion by advanced Aztecs from the west was acceptable.

And it got a lot of criticism for that.

I don't think it's going too much against the grain to allow players the fantasy of taking their faith down a gentler, more tolerant path than they otherwise did. It would be nice to be able to make that choice without having to rely on a mod. After all, if you happen to be playing a gay or bisexual monarch who COULD reform the faith of his nation to be more tolerant, why shouldn't she or he?

I'm not opposed to the fantasy (and in fact will probably want to pursue it myself at some point), but no, they could not reform their faith like that. A monarch is only in charge so long as people listen to them. Even the current faith reform system is already a little too 'easy', in my opinion (there should be a limit of changes you can make when reforming, imo, necessitating multiple reforms if you want to completely change everything around), and I think most, perhaps even all, of the current faith aspects have basis in at least one historical culture, which wouldn't be the case with same-sex marriage. (I'd also make the argument that if there are any aspects that do not have basis in any historical culture, they should be removed from the base game and left to mods)
 
  • 27
  • 9Like
  • 7
  • 1Haha
  • 1
Reactions: