mirror of
https://github.com/HMCL-dev/HMCL.git
synced 2025-09-19 00:36:10 -04:00
fix: recongnizing vanilla as patched
This commit is contained in:
parent
b154871207
commit
a162828f0a
@ -154,12 +154,11 @@ public class HMCLGameRepository extends DefaultGameRepository {
|
|||||||
if (id == null || !isLoaded())
|
if (id == null || !isLoaded())
|
||||||
return newImage("/assets/img/grass.png");
|
return newImage("/assets/img/grass.png");
|
||||||
|
|
||||||
Version version = getVersion(id);
|
Version version = getVersion(id).resolve(this);
|
||||||
File iconFile = getVersionIconFile(id);
|
File iconFile = getVersionIconFile(id);
|
||||||
if (iconFile.exists())
|
if (iconFile.exists())
|
||||||
return new Image("file:" + iconFile.getAbsolutePath());
|
return new Image("file:" + iconFile.getAbsolutePath());
|
||||||
else if (!version.getPatches().isEmpty() ||
|
else if (version.getMainClass() != null &&
|
||||||
version.getMainClass() != null &&
|
|
||||||
("net.minecraft.launchwrapper.Launch".equals(version.getMainClass())
|
("net.minecraft.launchwrapper.Launch".equals(version.getMainClass())
|
||||||
|| version.getMainClass().startsWith("net.fabricmc")
|
|| version.getMainClass().startsWith("net.fabricmc")
|
||||||
|| "cpw.mods.modlauncher.Launcher".equals(version.getMainClass())))
|
|| "cpw.mods.modlauncher.Launcher".equals(version.getMainClass())))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user