[DEPRECATED VERSION] HoI4 to Stellaris Converter

  • 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.
Status
Not open for further replies.
I think I've found the problem. When the converter puts together a history of the 21st and 22nd centuries, it randomly chooses a bunch of things to happen - and for this save, one of the things it's chosen is the &RANDOM_SMALL_NATION& War. But there are no small nations, there is only the Empire. So it crashes.

I think I've fixed this bug now, though - both the crash-if-no-small-nations issue and the if-world-conquest-it-shouldn't-be-choosing-that-event-anyway issue. Can you please send me your V2-to-HoI4 mod so I can make sure?
 
I think I've found the problem. When the converter puts together a history of the 21st and 22nd centuries, it randomly chooses a bunch of things to happen - and for this save, one of the things it's chosen is the &RANDOM_SMALL_NATION& War. But there are no small nations, there is only the Empire. So it crashes.

I think I've fixed this bug now, though - both the crash-if-no-small-nations issue and the if-world-conquest-it-shouldn't-be-choosing-that-event-anyway issue. Can you please send me your V2-to-HoI4 mod so I can make sure?

Sure thing! Thank you for the quick reply ^.^
 

Attachments

  • CONVERTTHIS.rar
    1,7 MB · Views: 9
Good news - looks like that's now fixed. I'll get that pushed out in the next update (in the next few days, once I fix the other bugs that my ill-fated Kaiserreich test revealed).

In the meantime, I've run your save and mod through the converter, and attached the output to this post.

(With one small difference - the Vic2-to-HoI4 mod didn't have any ship names, because my ship-name-conversion code for the Vic2-to-HoI4 converter hasn't made it into a release yet. So I've just edited the Stellaris mod to use the newly-released Roman name list instead. It seemed appropriate!)
 

Attachments

  • CONVERTEDTHIS.zip
    15,1 MB · Views: 9
Good news - looks like that's now fixed. I'll get that pushed out in the next update (in the next few days, once I fix the other bugs that my ill-fated Kaiserreich test revealed).

In the meantime, I've run your save and mod through the converter, and attached the output to this post.

(With one small difference - the Vic2-to-HoI4 mod didn't have any ship names, because my ship-name-conversion code for the Vic2-to-HoI4 converter hasn't made it into a release yet. So I've just edited the Stellaris mod to use the newly-released Roman name list instead. It seemed appropriate!)

Thank you so much ^.^, I've been fairly excited to try out this converter ever since a friend of mine showed me a post on reddit about it.

Nice touch with the name list to. I'm looking forward to seeing how far this converter goes - I did see that you were considering a Hoi4 to DEFCON to Stellaris converter, which is crazy, but in a good way.

Edit - The only 'gripe' I have (if any at all) is that the ruler's family name is no longer 'Pendragon' (It's a really small gripe, I know, and I've already fixed it in the save file), this is the same family I've kept going, maintaining massive amounts influence in the Empire's politics since 476 (And I've made triple sure that all children are 100% Legitimate! A harem of lesbians made sure of that!)

And, another thing, this one is more of an idea than a gripe, but why not have an option(s) of determining the 'history' of the convert yourself? Lets say, I conquer the entire world, every last little region, and with 'early' space exploration I sent out a colony ship (almost like the regular Stellaris lore with the Commonwealth of Man), or perhaps a couple ships, and they can be competing Corporations, or colonies from competing family members (of the dynasty currently ruling Earth) Maybe having a couple going rouge and going full Democratic, or one Communist. Either way, there's a lot of fun ways you can go about this ^.^
 
Last edited:
Mm, I'd like to get the hereditary-ruler name thing fixed too. The trouble there is that Victoria 2 doesn't care about monarchs (only monarchies), so dynasty information doesn't make it through the EU4-to-Vic2 converter - and any converters after that point just don't know what the old monarchs were called. There are plans to store dynastic information in a file somewhere and then use that to generate monarchs for HoI4 where needed, but I don't think anyone's coded that up yet. Maybe I should...

Also: my original design for the Stellaris converter had a reasonably-detailed PyQt5 ui where you could customise what happened to Earth, which nation got which government/civics, etc. I had quite a bit of it coded up, but then I started trying to make the history generator - and realised generating a coherent 21st century based on whatever things the user had chosen was a much bigger job than I'd thought, and decided I should just concentrate on getting something released instead. I like the idea of randomly adding other Commonwealth-of-Man-style rogue colonies, though!

(Also also: HoI4-to-DEFCON is definitely coming - I've got the HoI3-to-DEFCON converter HoI4ifiied and working fine, I just need to neaten up a few things. I've not started work on the DEFCON-to-Stellaris side of the converter yet, but it shouldn't be too complicated.)
 
New release: version 0.2A.

Download

New features:
- Governments now no longer hardcoded. They're now separated out into files/governments.txt, to make it easier to add new ones for Kaiserreich / Millennium Dawn / other total-conversion mods.

Bugs fixed:
- Unreadable state data will no longer crash the converter.
- Fallback country flags are now being used.
- Nuclear wars will only destroy Earth rather than the whole galaxy.
 

Attachments

  • HoI4ToStellarisConverter_0.2A.zip
    40,8 MB · Views: 41
New release: version 0.3.

DOWNLOAD

New feature: added support for the HoI4 to DEFCON converter. You can now take the results from the end of the DEFCON game, put them into the HoI4-to-Stellaris config file, and the converter will take them into account when generating the new Stellaris empires.
 

Attachments

  • HoI4ToStellarisConverter_0.3.zip
    40,8 MB · Views: 9
Hey There! I really like the idea behind this converter and wanted to try it out for my latest eu4->vic2->hoi4 campaign, but I'm getting an error. Here is the save, the converted mod and the log I'm getting. Thanks for the hard work!
 

Attachments

  • UCA.zip
    8,4 MB · Views: 13
I just tried converting a basic 1936 unmodded game to see if it was a system problem or a mod-specific one and got different errors using the 0.3 and 0.2A versions. With the .3 version the Temp files delete themselves almost immediately and as a result the converter can't find it's own files, with the 0.2A the conversion starts and then I get "KeyError: 'SAU_neutrality_ADJ'" and the converter stops. Here are the two logs, the save is simply a new and unmodded game as Germany in 1936. I've attached the two logs.
 

Attachments

  • Logs.zip
    1,3 KB · Views: 12
I've got the first bug fixed - it looks like an update to the HoI4 converter, or maybe HoI4 itself, had started putting quote marks around the climate-data numbers and my parser wasn't parsing them properly. I'll get that pushed out in the next few days (in the meantime, I've attached the converter output to this forum post).

If I remember right,. the "KeyError: SAU_neutrality_ADJ" was a known bug in 0.2A - I put a fix for it in 0.3. I'm not sure what's going on with your files deleting themselves, though - especially since it wasn't doing that before with your original United-America save. Can you please send me your configuration.txt so I can try doing exactly the same thing at my end?
 

Attachments

  • UA_output.zip
    15,1 MB · Views: 10
I've got the first bug fixed - it looks like an update to the HoI4 converter, or maybe HoI4 itself, had started putting quote marks around the climate-data numbers and my parser wasn't parsing them properly. I'll get that pushed out in the next few days (in the meantime, I've attached the converter output to this forum post).

If I remember right,. the "KeyError: SAU_neutrality_ADJ" was a known bug in 0.2A - I put a fix for it in 0.3. I'm not sure what's going on with your files deleting themselves, though - especially since it wasn't doing that before with your original United-America save. Can you please send me your configuration.txt so I can try doing exactly the same thing at my end?

Wow, thanks a lot! Of course, here is the config file. If you want I can also get you the temp files, I was able to copy them once before they deleted themselves. At first I thought it could be a problem with CCleaner but it persisted when I turned it off, so unless it's my antivirus I'm out of ideas regarding any external sources that could be causing the problem. I also tried to make the converted use the copy, but the numbers at the end of the folder's name change every time. Just in case this could be useful information: I have windows installed on one drive, the user folder is on a different drive, and the game is installed on a third drive.
 

Attachments

  • configuration.txt
    1,4 KB · Views: 19
I've managed to reproduce and fix the temporary-files bug. So here's that new release I was talking about.

New release: version 0.3A.

Download

A few small bugfixes - the converter will no longer be confused by speechmarks in climate data, and should no longer occasionally lose its working directory. Also, added support for the Stellaris 2.1 "Niven" update.
 

Attachments

  • HoI4ToStellarisConverter_0.3A.zip
    40,8 MB · Views: 114
Any plans for updating to 2.2.?
 
Hello, I have an error at the end of the conversion

Reading save data...
Traceback (most recent call last):
File "Converter.py", line 105, in <module>
File "Converter.py", line 20, in __init__
File "config.py", line 60, in Init
File "naive_parser.py", line 205, in __init__
ValueError: invalid literal for int() with base 10: ''
 
Ah yes my favorite ww2 battle. The battle of the Cofeve System. Where the Soviet Union Bravely fought against the Prethoryn Scourge and the Bhenn'Thell Purifiers.
 
  • 1Like
Reactions:
Status
Not open for further replies.