refac: убрана лишняя рефлексия
This commit is contained in:
@@ -1,24 +1,12 @@
|
|||||||
import java.io.File;
|
|
||||||
import java.lang.reflect.Field;
|
|
||||||
|
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
|
||||||
public class Start
|
public class Start
|
||||||
{
|
{
|
||||||
public static void main(String[] args)
|
public static void main(String[] args)
|
||||||
{
|
{
|
||||||
try
|
Minecraft.minecraftDir = new File(".");
|
||||||
{
|
|
||||||
Field f = Minecraft.class.getDeclaredField("minecraftDir");
|
|
||||||
Field.setAccessible(new Field[] { f }, true);
|
|
||||||
f.set(null, new File("."));
|
|
||||||
}
|
|
||||||
catch (Exception e)
|
|
||||||
{
|
|
||||||
e.printStackTrace();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
Minecraft.main(args);
|
Minecraft.main(args);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -227,7 +227,7 @@ public abstract class Minecraft implements Runnable
|
|||||||
private TextureLavaFX textureLavaFX;
|
private TextureLavaFX textureLavaFX;
|
||||||
|
|
||||||
/** The working dir (OS specific) for minecraft */
|
/** The working dir (OS specific) for minecraft */
|
||||||
private static File minecraftDir = null;
|
public static File minecraftDir = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set to true to keep the game loop running. Set to false by shutdown() to allow the game loop to exit cleanly.
|
* Set to true to keep the game loop running. Set to false by shutdown() to allow the game loop to exit cleanly.
|
||||||
|
|||||||
Reference in New Issue
Block a user