UniMixins

UniMixins

48.3k Downloads

Campfire Backport and MAtmos,Can't add [ ] to name

ArchiDreamZ opened this issue · 10 comments

commented

Unable to add "[ ]" square brackets to the names of Campfire Backport and MAtmos, once the "[ ]" square brackets are added to their file names, the game will not start.
This problem only occurs after installing UniMixins

fml.txt

commented

Yeah, I'll add a note to the readme.

I also added a warning message in 0.1.7 if incorrect jar order is detected, and it recommends you to add a ! character.

return Arrays.asList("A different version of Mixin (the one inside " + stringOr(mixinTweakerJarName, "unknown") + ") is getting loaded instead of UniMixins's one (inside " + stringOr(mixinCoreJarName, "unknown") + ")!" + (isSuspectedToBeDueToNaming ? " This is probably because because UniMixins's jar name comes later alphabetically. Try renaming it to come first (for example, by adding a '!' character at the beginning of the file name.)" : ""));

commented

In non-English speaking countries, people need to add local text in front of the mod name to let themselves know what the mod is. For example, in China, everyone I have seen will add Chinese characters in front of the name of the mod, and use [ ] or 【】 to enclose it.
So basically all Chinese players will encounter this problem, so I suggest directly in CurseForge Write the problem and solution in the FAQ.

commented

A note here is that this is caused by how Forge works. Even if coremods run very first, they're still run one after the other.
Forge manages the loading order by sorting the file names using Unicode.
So in this case, it doesn't work because Campfire Backport and MAtmos would be run earlier than Unimixins by forge and wouldn't find the Unimixins classes.

Alternatively can't we have the prefix as !_, so Github releases would still load after [ mods but still earlier, and other releases would run as early as possible.

commented

I suggest directly in CurseForge Write the problem and solution in the FAQ.

I did add it to the "Usage" section of the description on all of GitHub, CurseForge and Modrinth.

Alternatively can't we have the prefix as !_, so Github releases would still load after [ mods but still earlier, and other releases would run as early as possible.

I want the name to be the same on all platforms for consistency, and I consider GitHub to be the canonical place to obtain the mod, so having the releases there be inferior wouldn't feel right.

GitHub supports the following non-letter characters that come before [: +-.0@.

. hides the file on Unix platforms, and 0 and @ look very conspicuous, but maybe we could switch to + or -.

commented

Don't add [] to the names then.

commented

But only these two mods will do this, other mods are fine
Can this problem be solved?

commented

Try renaming UniMixins' jar to start with a ! character. The issue here is that by adding the [ character, you're making the file names of these mods come before UniMixins alphabetically.

Characters are sorted like this in Java:

! < [ < _

commented

It worked, if this is the cause of the problem, I think Unimixin should add "!" in front by default instead of "_"

commented

The reason we don't is simple, GitHub unfortunately doesn't allow the ! character in release file names.

commented

I understand, I think it is better to write such important information directly on the CurseForge page