Open toebeann opened 1 year ago
Have been giving this more thought over in #8 while considering compatibility between CC2 and Purple's CC3: https://github.com/toebeann/subnautica-support/issues/8#issuecomment-1949115380
Relevant notes:
- Strip out everything in any line following a
#
symbol (making sure to check for a preceding escape character\
just in case)- Strip out all horizontal whitespace (we don't care about values so it doesn't matter that we're messing up strings)
- Strip out empty lines
- If the file is a valid CC2/CC3 EasyMarkup file, the first line of the remaining text should begin with one of the following keys, followed by a colon (
:
) symbol:
AddedRecipes
AliasRecipes
CustomBioFuels
CustomFabricators
CustomFoods
CustomFragmentCounts
CustomSizes
CustomCraftingTabs
ModifiedRecipes
MovedRecipes
Otherwise, it's definitely not a CC2/CC3 EM file. It still might be an EM file in general, just not for CC2/CC3.- To determine whether a CC2/3 EM file is compatible with PrimeSonic's CC2 (as of CC3 v1.0.0.4):
- if the primary key of the file is not
CustomFoods
, it is inherently compatible with CC2- otherwise, if one of the following keys are not found in the file, it should be compatible with CC2:
OxygenValue
HealthValue
HeatValue
If any of these keys are found, it is only (fully) compatible with MrPurple6411's CC3.
HeatValue
key of CustomFoods
CC3 EM files is only legal in BZ
There seem to be some users turning up to the discord with cc2 plugin packs not working correctly due to the way they were packaged.
It might be worth adding a few more acceptable packaging structures (eg. If cc2 folder is nested within QMods or BepInEx\plugin)
Possibly also if there is no CC2 folder, just WorkingFiles as long as it includes only .txt files.
Maybe investigate the way cc2 .txt files are structured so we can even detect loose .txt files, similar to how we detect bepinex plugins in loose .dlls, rather than relying so much on package structure?