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

HOI4 Dev Diary - Custom Gameplay Rules

Hi everyone! Most of the team is now back after summer so it’s time to spin up the ‘ol diary machine again. Today we are going to be talking about something we have been thinking about adding for a really long time: Custom Gameplay Rules.

First off, let me explain why we are doing this - HOI4 is a game people play in a lot of different ways. Single player, multiplayer, achievement runs, casual relaxing and various other. There is also a big split between people who play “historically” vs people who don’t (it’s around 50/50). A lot of stuff that adds fun and a sense of power in singleplayer are not very balanced for organized competitive multiplayer so organizing these games can be challenging, often including long rulesets and policing by the server host. I personally think a big reason competitive multiplayer isn’t as common (about 6% of MP games are competitive) is because it’s so much harder to set them up when they require reading rulesets, which become fragile when the game itself isn’t enforcing them.
When it comes to single player, players often ask for ways to tailor how they play. For example; some will use console commands to switch nations to set them on certain paths to match their long term plans for the scenario they want to play out etc, but it’s not exactly beginner-friendly, and isn’t possible to do in multiplayer either. So looking at all of these things we decided that we needed to support different rulesets and let players affect how the ai did things in more detail.

So, enter Custom Game Rules. This is a new setting you can do before you start your game, and includes the old buff sliders for majors as well:
main.jpg


It’s possible to store and load presets if you have a couple of prefered profiles you run (say single player and multiplayer?). We have tried to make rules as moddable as possible although when they directly impact hard-coded gameplay mechanics we need to make sure we have worked them in first. We’ll go over the modding aspects towards the end!

So what kind of stuff can you do? We haven’t fully finalized it all, but let’s go through what we got. I am sure people will have tons of suggestions in the comments too ;)

All diplomatic actions have the possibility for rules. So we can restrict or ease up how things work. This is particularly good when you want to tie focus trees into it. The new British tree has a lot of interaction with releasable nations, so this also lets us manage that from scripts and avoid exploits and weird situations (such as the player going down the ‘empire’ path, and yet releasing every colony they own).

release.jpg


rule.jpg


Covert actions are also included here, so you can for example restrict coups and such only to AI nations (a common rule in our own MP sessions).
covert.jpg


There are also other bits and pieces like being able to limit fort levels constructable, limiting paratroopers and such we are playing around with. Other things rules we see people use a lot are for example limiting war declares before certain dates etc. I expect we will be presenting a full listing of options later when we stream stuff closer to release.

You can also affect how you want the AI to act. Mostly this means it will be preferring certain choices and switching to alternate plans. If you want to tailor-make your game experience this is a great way of ensuring certain (a)historical outcomes being attempted by the AI no matter your settings.
ai_ger.jpg


For most there are options for ideology while some like Manchukuo are more relevant to its situation:
man.jpg


Some settings, like this particular one, are dependent on DLC, so without Waking the Tiger (which comes with that focus tree) the option simply won't be there. Otherwise the whole custom rules system is part of the free update and is for sure something we will be building on in the future.

Rules will generally turn off achievements, but its possible to set it by rule so if we introduce something we feel is ok in both it will still work.

Modding
So, when we started with this we realized we couldn't support every tiny rule some MP groups were using and instead we’ve tried to make it as easy as possible to mod things in. It’s my hope that some cool ruleset mods will be developed specifically for competitive multiplayer and the like in the modding workshop. Very popular options may even see inclusion in the base game in the future, who knows :) I expect some of the big mods will want to include custom rules as well for their players.

Rule definitions look like this:
mod1.jpg


They can then be checked from triggers from say the tech tree, focus tree, events etc and in other places we have added support for triggers. Example:
mod2.jpg


Diplo actions are a little special. They each get two possible triggers. This way you can turn on or off the standard game checks (like checks against world tension from game code) with the _TRIGGER_OVERRIDES_GAME. For your own rule checks you use the _ENABLE_TRIGGER for the specific action and the scope will contain the target nation as well so you can do nation specific rules.
This is what the triggers for Guarantees look like:
Screenshot_1.jpg


That’s it! Tune in next week to find out more about what we are up to with Man the Guns and the 1.6 ‘Ironclad’ update.
 
As somebody who regularly tag-switches to other nations to railroad focus trees, I cannot thank Paradox enough for making this. This is perhaps the most pleasant surprise in a dev diary I've had so far.
 
It'd be pleasant if changing only one nation's behaviour kept achievements on. Most achievement hunters like myself will roll a dozen games until they find the "ideal" early-game situation. For example praying Japan doesn't choose Purge The Kodoha Faction (an easy re-roll after the first day) or waiting to see the outcome of the Spanish Civil War (a horribly annoying re-roll which can last into 1938).

We're still going to be spamming new saves waiting for one critical choice so hey you could at least save us the trouble
 
Any chance of an option to buff one or other side in the Spanish Civil War?

(This not at all induced by having to rerun multiple hands-off games to test balance because the Nationalists went and lost it)
Just feed the Nats with rifles thru console. Works every time. Usually takes between 15-20k.
 
Would it be possible for the boost party popularity rule to be able to pick multiple rules:
-only ever one country a time
-No player countries
-No major powers including China

It's the rules we play with but people often break the first one.
 
hmmm ... so we guide the AI to the rails we want ? but wouldn be more beautiful to 'teach the AI' to react on its own according to players choices instead of pre set what will happen ? i dont even know if that possible in terms of coding ... nevertheless i can wait to test the new Rules ...
The AI does react to what the player does. It is just less random than we want it to be.
 
This will be a huge improvement!

Is it possible to restricts countries from going down various paths? I'd like an ahistorical game without the unrealistic things like Kaiserreich and communist Japan but also without the full-on railroading of the current historical mode either so that e.g. Hitler will stay in power but he can attack the Allies, the USSR, or just trying to devour smaller countries in Europe without igniting a world war, and you can't know what he will do.
 
Just to clarify: is there a setting to allow nations go a truly random path, where any one of the settings is chsoen by the game at the start? I'd like to see a chance of Nazi Germany going sane and restoring the Kaiser without guarenteeing it.
 
Could there also be a function to hide/mark as obsolete templates we don't want to remove or use right now but might have a use for in the future?
This is part of why mods which expand the palette of counter icons are so popular. IMO, there should never be two templates using the identical icon. I also cannot abide those generic green icons instead of proper NATO symbology.
 
You know what would be nice to go with this? Mod presets with MP? We sort of get around this by having collections on Steam, but its annoying to uninstall everything and to install just your friends collection... So once you have a mod collection set... I would be nice to save it as a present and then you can switch back from your single player to modded friends version to vanilla without having to uncheck every mod.
 
You know what would be nice to go with this? Mod presets with MP? We sort of get around this by having collections on Steam, but its annoying to uninstall everything and to install just your friends collection... So once you have a mod collection set... I would be nice to save it as a present and then you can switch back from your single player to modded friends version to vanilla without having to uncheck every mod.
This. Not just with MP, either; I have like four-five overhaul mods that I keep lists for to remember which is compatible with what mod and which isn't, and I have to go through the list checking and unchecking mods as I scroll everytime I want to switch between them. If we had mod presets this would be a simple matter of switching to my "Ironman Achivement" mod preset from my "Kaiserreich" mod preset.
 
Can the developers make the AI make strong divisions, or at least divisions that make sense historically, and work on the production AI logic so it prioritises what is needed at the front.
 
You know what would be nice to go with this? Mod presets.
FTFY :p

Mod presets are badly needed not just for MP, but also for when you want to switch between one supermod+all of its support mods to another supermod with all of its compatible mods. Making lists in Notepad is a bit cumbersome.
 
You know what would be nice to go with this? Mod presets.
FTFY :p

Mod presets are badly needed not just for MP, but also for when you want to switch between one supermod+all of its support mods to another supermod with all of its compatible mods. Making lists in Notepad is a bit cumbersome.
 
This is going to make MP games SO MUCH more fun, easy to host and fair! Thank you a million times over! If anyone needed proof that the devs are listening (at least sometimes) this is it!
 
probably someone already suggested this but, can you add the posibility to restrict division building in MP? like restricting the possibility of 40 combat width divisions?