Merge branch 'master' of github.com:nossr50/vminecraft-plugin

This commit is contained in:
cerevisiae 2010-11-28 21:00:08 -06:00
commit 297c308d1a
3 changed files with 12 additions and 1 deletions

View File

@ -87,4 +87,5 @@ public class vminecraftListener extends PluginListener {
}
return false;
}
}

View File

@ -22,6 +22,8 @@ public class vminecraftPlugin extends Plugin {
//Here we add the hook we're going to use. In this case it's the arm swing event.
etc.getLoader().addListener(PluginLoader.Hook.CHAT, listener, this, PluginListener.Priority.MEDIUM);
etc.getLoader().addListener(PluginLoader.Hook.COMMAND, listener, this, PluginListener.Priority.HIGH);
etc.getLoader().addListener(PluginLoader.Hook.IGNITE, listener, this, PluginListener.Priority.HIGH);
etc.getLoader().addListener(PluginLoader.Hook.EXPLODE, listener, this, PluginListener.Priority.HIGH);
if(etc.getInstance().isHealthEnabled()){
etc.getLoader().addListener(PluginLoader.Hook.HEALTH_CHANGE, listener, this, PluginListener.Priority.MEDIUM);
}

View File

@ -12,7 +12,7 @@ public class vminecraftSettings {
protected static final Logger log = Logger.getLogger("Minecraft");
private static volatile vminecraftSettings instance;
//Invulnerability List
//The feature settings
static boolean toggle = true,
@ -31,6 +31,8 @@ public class vminecraftSettings {
globalmessages = false,
cmdSay = false,
cmdWho = false,
stopFire = false,
stopTnt = false,
cmdEzModo = false;
//An array of players currently in ezmodo
@ -78,6 +80,8 @@ public class vminecraftSettings {
writer.write("cmdEzModo=true\r\n");
writer.write("ezModo=\r\n");
writer.write("ezHealth=30\r\n");
writer.write("stopFire=false");
writer.write("stopTnt=false");
writer.write("rules=Rules@#1: No griefing@#2: No griefing\r\n");
} catch (Exception e) {
log.log(Level.SEVERE, "Exception while creating " + location, e);
@ -117,6 +121,8 @@ public class vminecraftSettings {
globalmessages = properties.getBoolean("globalmessages",true);
cmdSay = properties.getBoolean("cmdSay",true);
cmdEzModo = properties.getBoolean("cmdEzModo",true);
stopFire = properties.getBoolean("stopFire",true);
stopTnt = properties.getBoolean("stopTNT",true);
rules = properties.getString("rules", "").split("@");
String[] tempEz = properties.getString("ezModo").split(",");
@ -159,6 +165,8 @@ public class vminecraftSettings {
public boolean cmdMasstp() {return cmdMasstp;}
public boolean cmdEzModo() {return cmdEzModo;}
public boolean cmdWho() {return cmdWho;}
public boolean stopFire() {return stopFire;}
public boolean stopTnt() {return stopTnt;}
//EzModo functions
public boolean isEzModo(String playerName) {return ezModo.contains(playerName);}