removed non used IMC thingy

This commit is contained in:
Tobias Wohlfarth 2015-12-09 20:29:29 +01:00
parent a66ce000a3
commit 65af1cadaf
3 changed files with 0 additions and 64 deletions

View file

@ -55,10 +55,6 @@ public class ModTweaker2 {
@EventHandler
public void preInit(FMLPreInitializationEvent event) {
logger.info("Starting PreInitialization for " + ModProps.modid);
baseIMCFolder = new File("imcScripts");
if (!baseIMCFolder.exists()) {
baseIMCFolder.mkdir();
}
}
@SidedProxy(clientSide = "modtweaker2.proxy.ClientProxy", serverSide = "modtweaker2.proxy.CommonProxy")
@ -101,9 +97,6 @@ public class ModTweaker2 {
}
});
MineTweakerImplementationAPI.setScriptProvider(new ScriptProviderDirectory(baseIMCFolder));
MineTweakerImplementationAPI.reload();
File scripts = new File("scripts");
if (!scripts.exists()) {
scripts.mkdir();

View file

@ -1,9 +0,0 @@
package modtweaker2.mods.imc;
import java.util.ArrayList;
public class IMC {
public static ArrayList<ArrayList<String>> IMCmessages = new ArrayList<ArrayList<String>>();
}

View file

@ -1,48 +0,0 @@
package modtweaker2.mods.imc.handler;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FilenameFilter;
import java.util.Scanner;
import cpw.mods.fml.common.event.FMLInterModComms;
public class Message {
public static String destination;
public File[] files;
public Scanner fileReader;
public Message(String destination) {
this.destination = destination;
files = new File(destination).listFiles(new FilenameFilter() {
@Override
public boolean accept(File dir, String name) {
if (name.toLowerCase().endsWith(".imc")) {
return true;
}
return false;
}
});
try {
for (File file : files) {
this.fileReader = new Scanner(file);
while (fileReader.hasNextLine()) {
String command = fileReader.nextLine().trim();
if (command.toLowerCase().startsWith("sendimc(") && command.substring(command.length() - 1).equals(";")) {
command = command.substring("sendimc(".length()).replace(command.substring(command.length() - 1), "").replace(command.substring(command.length() - 1), "").replaceAll("\"", "");
String[] input = command.split(",");
FMLInterModComms.sendMessage(input[0], input[1], input[2]);
}
}
}
} catch (FileNotFoundException e) {
e.printStackTrace();
}
}
}