Crash fix + drill balance

This commit is contained in:
Anuken 2019-06-19 21:41:49 -04:00
parent 47b1e700ea
commit 8e95be0ac2
4 changed files with 20 additions and 18 deletions

View File

@ -331,7 +331,7 @@ zone.resources = Resources Detected:
add = Add...
boss.health = Boss Health
connectfail = [crimson]Failed to connect to server:\n\n[accent]{0}
connectfail = [crimson]Connection error:\n\n[accent]{0}
error.unreachable = Server unreachable.\nIs the address spelled correctly?
error.invalidaddress = Invalid address.
error.timedout = Timed out!\nMake sure the host has port forwarding set up, and that the address is correct!

View File

@ -1125,7 +1125,7 @@ public class Blocks implements ContentList{
}};
pneumaticDrill = new Drill("pneumatic-drill"){{
requirements(Category.production, ItemStack.with(Items.copper, 60, Items.graphite, 50));
requirements(Category.production, ItemStack.with(Items.copper, 35, Items.graphite, 15));
tier = 3;
drillTime = 480;
size = 2;
@ -1134,7 +1134,7 @@ public class Blocks implements ContentList{
}};
laserDrill = new Drill("laser-drill"){{
requirements(Category.production, ItemStack.with(Items.copper, 70, Items.graphite, 90, Items.silicon, 60, Items.titanium, 50));
requirements(Category.production, ItemStack.with(Items.copper, 70, Items.graphite, 60, Items.silicon, 60, Items.titanium, 40));
drillTime = 280;
size = 3;
hasPower = true;
@ -1147,8 +1147,8 @@ public class Blocks implements ContentList{
}};
blastDrill = new Drill("blast-drill"){{
requirements(Category.production, ItemStack.with(Items.copper, 130, Items.silicon, 120, Items.titanium, 100, Items.thorium, 100));
drillTime = 200;
requirements(Category.production, ItemStack.with(Items.copper, 130, Items.silicon, 120, Items.titanium, 100, Items.thorium, 150));
drillTime = 220;
size = 4;
drawRim = true;
hasPower = true;

View File

@ -50,6 +50,17 @@ public class CrashSender{
}
}
try{
File file = new File(OS.getAppDataDirectoryString(Vars.appName), "crashes/crash-report-" + DateTimeFormatter.ofPattern("MM_dd_yyyy_HH_mm_ss").format(LocalDateTime.now()) + ".txt");
new File(OS.getAppDataDirectoryString(Vars.appName)).mkdir();
new BufferedOutputStream(new FileOutputStream(file), Streams.DEFAULT_BUFFER_SIZE).write(parseException(exception).getBytes());
Files.createDirectories(Paths.get(OS.getAppDataDirectoryString(Vars.appName), "crashes"));
writeListener.accept(file);
}catch(Throwable ignored){
Log.err("Failed to save local crash report.");
}
try{
//check crash report setting
if(!Core.settings.getBool("crashreport", true)){
@ -64,17 +75,6 @@ public class CrashSender{
return;
}
try{
File file = new File(OS.getAppDataDirectoryString(Vars.appName), "crashes/crash-report-" + DateTimeFormatter.ofPattern("MM_dd_yyyy_HH_mm_ss").format(LocalDateTime.now()) + ".txt");
new File(OS.getAppDataDirectoryString(Vars.appName)).mkdir();
new BufferedOutputStream(new FileOutputStream(file), Streams.DEFAULT_BUFFER_SIZE).write(parseException(exception).getBytes());
Files.createDirectories(Paths.get(OS.getAppDataDirectoryString(Vars.appName), "crashes"));
writeListener.accept(file);
}catch(Throwable ignored){
Log.err("Failed to save local crash report.");
}
boolean netActive = false, netServer = false;
//attempt to close connections, if applicable

View File

@ -385,7 +385,7 @@ public class HudFragment extends Fragment{
//paused table
parent.fill(t -> {
t.top().visible(() -> state.is(State.paused) && !Net.active());
t.top().visible(() -> state.isPaused());
t.table("button", top -> top.add("$paused").pad(6f));
});
@ -551,8 +551,10 @@ public class HudFragment extends Fragment{
}
shown = !shown;
if(flip != null){
flip.getParent().act(Core.graphics.getDeltaTime());
}
}
private void addWaveTable(TextButton table){
StringBuilder ibuild = new StringBuilder();