mirror of https://github.com/kami-blue/client
close #453
This commit is contained in:
parent
8e1dd00a65
commit
a8ede8925d
|
@ -53,8 +53,6 @@ public class KamiGUI extends GUI {
|
|||
|
||||
public static ColourHolder primaryColour = new ColourHolder(29, 29, 29);
|
||||
|
||||
//public static OperatingSystemMXBean bean = (com.sun.management.OperatingSystemMXBean) ManagementFactory.getOperatingSystemMXBean();
|
||||
|
||||
public KamiGUI() {
|
||||
super(new KamiTheme());
|
||||
theme = getTheme();
|
||||
|
|
|
@ -0,0 +1,36 @@
|
|||
package me.zeroeightsix.kami.util;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
* @author S-B99
|
||||
* Created by S-B99 on 18/02/20
|
||||
*/
|
||||
public class LogUtil {
|
||||
private static String COORDS_FILE_NAME = "KAMIBlueCoords.txt";
|
||||
private static final File coordsFileName = new File(COORDS_FILE_NAME);
|
||||
|
||||
public static void writePlayerCoords(String locationName) {
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
writeTo((int) mc.player.posX, (int) mc.player.posY, (int) mc.player.posZ, locationName);
|
||||
}
|
||||
|
||||
public static void writeTo(int x, int y, int z, String locationName) {
|
||||
try {
|
||||
FileWriter fw = new FileWriter(COORDS_FILE_NAME);
|
||||
fw.write(formatter(x, y, z, locationName));
|
||||
fw.close();
|
||||
System.out.println("Successfully wrote to the file.");
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
private static String formatter(int x, int y, int z, String locationName) {
|
||||
return x + ", " + y + ", " + z + ", " + locationName + "\n";
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue