Procházet zdrojové kódy

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

cerevisiae před 15 roky
rodič
revize
297c308d1a
3 změnil soubory, kde provedl 12 přidání a 1 odebrání
  1. 1 0
      vminecraftListener.java
  2. 2 0
      vminecraftPlugin.java
  3. 9 1
      vminecraftSettings.java

+ 1 - 0
vminecraftListener.java

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

+ 2 - 0
vminecraftPlugin.java

@@ -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.
         //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.CHAT, listener, this, PluginListener.Priority.MEDIUM);
         etc.getLoader().addListener(PluginLoader.Hook.COMMAND, listener, this, PluginListener.Priority.HIGH);
         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()){
         if(etc.getInstance().isHealthEnabled()){
         	etc.getLoader().addListener(PluginLoader.Hook.HEALTH_CHANGE, listener, this, PluginListener.Priority.MEDIUM);
         	etc.getLoader().addListener(PluginLoader.Hook.HEALTH_CHANGE, listener, this, PluginListener.Priority.MEDIUM);
         }
         }

+ 9 - 1
vminecraftSettings.java

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