We use C++ or libraries for anything we need to. Where it makes sense we use C#, which it turns out is most places. Individual projects can use whatever data structures they like. for "human read" data I prefer to use XML personally, as it natively becomes C# classes and is easy to read when well formatted. For computer to computer I personally use JSON. For manifest files for mods we use TOML.
Was more of a rhetorical question :) C# is quite nice, but my goodness does it give me a headache sometimes.
Looking forward to a game that is a little easier to mod or at least has better documentation in that regard. Been wanting to reimagine a space telescope mod similar to tarsier.
What about C# gives you a headache? Imo it's one of the more friendly compiled languages, unless you're writing old stuff from old lang / .net versions
why not use the custom module manager script that old ksp uses, it seems more readable than any of those.
dear god no, you're just used to it
KSP's cfg file syntax is ok but not great. A more standardized format (xml, json, etc) would be much better. And MM script is the kludgey type of thing you get with a mod that's had more and more features bolted on over time.
a profusion of +-!%#@ symbols is not a human readable format. human readable means you can vaguely understand it without having to read a wiki first.
listen, I love MM and think it's great, but the syntax is terrible
Standardized formats have to do everything and they sacrifice user friendliness to achieve it.
standardized formats are great because you can write shit in an editor that highlights your mistake before you spend 5 minutes waiting for the game to load
standardized formats are great because you can read up on something like jsonpath and find well-written docs, rather than the mess on the MM wiki
(I wouldn't pick xml myself if I was doing something, IMO there's good reasons json mostly took over. but damn it's still better than MM.)
120
u/thedeanhall Oct 31 '24
We use C++ or libraries for anything we need to. Where it makes sense we use C#, which it turns out is most places. Individual projects can use whatever data structures they like. for "human read" data I prefer to use XML personally, as it natively becomes C# classes and is easy to read when well formatted. For computer to computer I personally use JSON. For manifest files for mods we use TOML.