Minor Cleanup
This commit is contained in:
parent
69d29c3b31
commit
0ab47fdd19
@ -457,7 +457,7 @@ public class Main {
|
||||
}
|
||||
|
||||
//TODO: make this optional
|
||||
boolean useChunks = false;
|
||||
final boolean useChunks = false;
|
||||
|
||||
if (useChunks) { // use Chunks or Regions
|
||||
xRange = (int) (Math.ceil(((double) xRange) / ((double) 16))) * 16; //say xRange was entered as 1000. this changes it to be 1008, a multiple of 16. (the size of a chunk)
|
||||
|
@ -2,6 +2,17 @@ package morlok8k.MinecraftLandGenerator;
|
||||
|
||||
public class Out {
|
||||
|
||||
/**
|
||||
* Outputs a formatted string to System.err as a line.
|
||||
*
|
||||
* @param str
|
||||
* String to display and format
|
||||
* @author Morlok8k
|
||||
*/
|
||||
public static void err(final String str) {
|
||||
System.err.println(var.MLGe + str);
|
||||
}
|
||||
|
||||
/**
|
||||
* Outputs a formatted string to System.out as a line.
|
||||
*
|
||||
@ -46,15 +57,4 @@ public class Out {
|
||||
System.out.println("[Server] " + str);
|
||||
}
|
||||
|
||||
/**
|
||||
* Outputs a formatted string to System.err as a line.
|
||||
*
|
||||
* @param str
|
||||
* String to display and format
|
||||
* @author Morlok8k
|
||||
*/
|
||||
public static void err(final String str) {
|
||||
System.err.println(var.MLGe + str);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ public class Readme_and_HelpInfo {
|
||||
String showHelpSTR = "";
|
||||
String ReadMeText = "";
|
||||
String VersionInfo = "";
|
||||
String n = var.newLine;
|
||||
final String n = var.newLine;
|
||||
|
||||
//@formatter:off
|
||||
ReadMeText = PROG_NAME + " version " + VERSION + n
|
||||
|
@ -295,8 +295,7 @@ public class Update {
|
||||
|
||||
if (pos != -1) {
|
||||
if (line.substring(0, pos).equals(var.MLG_Current_Hash)) {
|
||||
var.MLG_Last_Modified_Long =
|
||||
new Long(line.substring(pos + 1, end));
|
||||
var.MLG_Last_Modified_Long = new Long(line.substring(pos + 1, end));
|
||||
var.MLG_Last_Modified_Date = new Date(var.MLG_Last_Modified_Long);
|
||||
|
||||
final Long highestModTime =
|
||||
@ -401,8 +400,7 @@ public class Update {
|
||||
e1.printStackTrace();
|
||||
|
||||
try {
|
||||
Misc.copyFile(new File(var.MLG_JarFile), new File(var.MLG_JarFile
|
||||
+ ".old"));
|
||||
Misc.copyFile(new File(var.MLG_JarFile), new File(var.MLG_JarFile + ".old"));
|
||||
final File fileDelete = new File(var.MLG_JarFile);
|
||||
fileDelete.delete();
|
||||
} catch (final Exception e2) {
|
||||
@ -414,8 +412,7 @@ public class Update {
|
||||
|
||||
}
|
||||
|
||||
final boolean fileSuccess =
|
||||
DownloadFile.downloadFile(var.github_MLG_jar_URL, true);
|
||||
final boolean fileSuccess = DownloadFile.downloadFile(var.github_MLG_jar_URL, true);
|
||||
if (fileSuccess) {
|
||||
Out.out(var.MLG_JarFile + " downloaded.");
|
||||
return;
|
||||
|
Reference in New Issue
Block a user