Format Code, Fixed 2 NPE's

This commit is contained in:
Driftay
2019-12-19 14:23:41 -05:00
parent fec07b6fac
commit 368a605d31
23 changed files with 54 additions and 57 deletions

View File

@@ -70,8 +70,8 @@ public class FLocation implements Serializable {
String worldName = string.substring(start, index);
start = index + 1;
index = string.indexOf(",", start);
int x = Integer.valueOf(string.substring(start, index));
int y = Integer.valueOf(string.substring(index + 1, string.length() - 1));
int x = Integer.parseInt(string.substring(start, index));
int y = Integer.parseInt(string.substring(index + 1, string.length() - 1));
return new FLocation(worldName, x, y);
}