KSP2 is Spamming the Windows Registry Over Weeks/Months Until the Game Will Stop Working Permanently
KSP2 is Spamming the Windows Registry Over Weeks/Months Until the Game Will Stop Working Permanently
KSP2 is Spamming the Windows Registry Over Weeks/Months Until the Game Will Stop Working Permanently
Holy shit. I just had this feeling early on to skip the early access. Seems like I made a good choice.
Did I read that correctly?? 1.6 GB of registry files??
Thats fucking amazing and completely unity's fault. What engine in their right mind saves user preferences in the registry?
Saving user preferences in the local user part of the registry is kind of what the registry is meant to be for (besides others).
It might be bad practice to dump 1.3GB of variable user data into the registry, though. Especially when there's SQL servers and Nuget packages that can deal with that kind of data in a platform-agnostic way.
You'd be surprised to learn then that a lot of software does this shit.
Well thats stupid
It doesn't look like what's filling the registry here is user preferences.
Seems like horrible dev practice to place save data of any kind in the Windows registry lmao. I get that it's designed for storing user data in some respects but the registry is an old and fickle solution to setting global variables important for communication between processes and applications.
If you're storing data that's only ever needed by your own application, especially if it isn't OS-related, you shouldn't mess with the registry. Not only does it not have the performance you'd expect for most circumstances, but the registry has a real performance and stability impact even when outside of your app.
What's worse, imo, is that this data is difficult to access for making backups, utilising cloud synchronization, and cross compatibility of your app.
Unity is a lot more borked than I thought, but KSP devs should probably be careful with what data serialisation APIs they mess with.
As a Unity dev of 6 years, playerPreffs (the unity system that stores data in the registry) are a good place to store small amounts of data in a dictionary style structure quickly without creating your own data system. But they are extremely limited in the types of data they can hold and the control a dev has over them. Whenever I see playerPreffs used I think the dev must-have needed something quick and easy. They may have also created their own registry save system in that case should be an easy fix. (De)Serializing json or even custom binary files in compartmented files in a defined folder like StreamingAssets gives much more flexibility in data types and control. You can see playerPreffs limitations in the documentation below: (https://docs.unity3d.com/ScriptReference/PlayerPrefs.html)
All the Unity game engine self-destruction choices got to them ;)
That was some pretty entertaining reading lol yikes.
thefuck, btw how proton handle the registry on steam deck/desktop linux?, that can happen there?
Wine registry, and yes, but only within your Wine sandbox
So, what's the advantage of using windows registry? I'm mainly using linux, so the concept of registry sounds really strange in my head.
When the developers don't abuse it, it's a central place where all the settings and configuration parameters should be.
There's no main advantage, it's just a different concept.
Linux sysadmin for the past 25 years here that also has to work with Windows servers.
Basically a network/local/user specific configuration database. Playing with it can break apps that expect their config to be in it, or to be of the type expected, even though they shouldn’t.
This about:config on Firefox but system wide. It’s your ~/.config
and /etc/
folders in one database format, also manageable with AD and proper permissions.
If you're using a Linux distribution: are you familiar with gsettings
or some equivalent?
Is It a frontend for dconf? I have to admit I never tinkered with any dconf stuff before as I live mostly in terminal and web browsers. Does dconf share similarities with windows registry?
These bugs keep getting more wild.
Yikes
I'm sure it'll be patched soon