Unix compatible, you heard of it?

This commit is contained in:
dginovker
2019-06-19 09:15:27 -04:00
parent ea51313125
commit c2559bf62f
16 changed files with 306 additions and 45 deletions
@@ -207,7 +207,7 @@ public class Item {
int c;
try {
FileInputStream dataIn = new FileInputStream(new File("./Data/data/stackable.dat"));
FileInputStream dataIn = new FileInputStream(new File("./data/data/stackable.dat"));
while ((c = dataIn.read()) != -1) {
if (c == 0) {
itemStackable[counter] = false;
@@ -225,7 +225,7 @@ public class Item {
counter = 0;
try {
FileInputStream dataIn = new FileInputStream(new File("./Data/data/notes.dat"));
FileInputStream dataIn = new FileInputStream(new File("./data/data/notes.dat"));
while ((c = dataIn.read()) != -1) {
if (c == 0) {
itemIsNote[counter] = true;
@@ -242,7 +242,7 @@ public class Item {
counter = 0;
try {
FileInputStream dataIn = new FileInputStream(new File("./Data/data/equipment.dat"));
FileInputStream dataIn = new FileInputStream(new File("./data/data/equipment.dat"));
while ((c = dataIn.read()) != -1) {
targetSlots[counter++] = c;
}
@@ -44,7 +44,7 @@ public class ItemDefinitions {
*/
public static void read() {
try {
DataInputStream in = new DataInputStream(new FileInputStream("./Data/data/itemdef.gsu"));
DataInputStream in = new DataInputStream(new FileInputStream("./data/data/itemdef.gsu"));
total = in.readShort();
if(definitions == null)
definitions = new ItemDefinitions[total];
@@ -39,8 +39,8 @@ public class NpcHandler {
for (int i = 0; i < maxListedNPCs; i++) {
NpcList[i] = null;
}
loadNPCList("./Data/CFG/npc.cfg");
loadAutoSpawn("./Data/CFG/spawn-config.cfg");
loadNPCList("./data/CFG/npc.cfg");
loadAutoSpawn("./data/CFG/spawn-config.cfg");
}
public static boolean isUndead(int index) {
@@ -27,7 +27,7 @@ public class PlayerSave {
try {
characterfile = new BufferedReader(new FileReader(
"./Data/characters/" + playerName + ".txt"));
"./data/characters/" + playerName + ".txt"));
File1 = true;
} catch (FileNotFoundException fileex1) {
}
@@ -373,7 +373,7 @@ public class PlayerSave {
BufferedWriter characterfile = null;
try {
characterfile = new BufferedWriter(new FileWriter(
"./Data/characters/" + player.playerName + ".txt"));
"./data/characters/" + player.playerName + ".txt"));
/* ACCOUNT */
characterfile.write("[ACCOUNT]", 0, 9);
@@ -114,7 +114,7 @@ public class ShopHandler {
boolean EndOfFile = false;
BufferedReader characterfile = null;
try {
characterfile = new BufferedReader(new FileReader("./Data/CFG/" + FileName));
characterfile = new BufferedReader(new FileReader("./data/CFG/" + FileName));
} catch (FileNotFoundException fileex) {
Misc.println(FileName + ": file not found.");
return false;