summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore4
-rw-r--r--BuildAll/nbproject/build-impl.xml453
-rw-r--r--BuildAll/nbproject/genfiles.properties4
-rw-r--r--Essentials/src/com/earth2me/essentials/Essentials.java31
-rw-r--r--Essentials/src/com/earth2me/essentials/EssentialsConf.java5
-rw-r--r--Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java109
-rw-r--r--Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java37
-rw-r--r--Essentials/src/com/earth2me/essentials/EssentialsPluginListener.java6
-rw-r--r--Essentials/src/com/earth2me/essentials/ISettings.java4
-rw-r--r--Essentials/src/com/earth2me/essentials/IUser.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/Kit.java18
-rw-r--r--Essentials/src/com/earth2me/essentials/Mob.java17
-rw-r--r--Essentials/src/com/earth2me/essentials/OfflinePlayer.java12
-rw-r--r--Essentials/src/com/earth2me/essentials/Settings.java50
-rw-r--r--Essentials/src/com/earth2me/essentials/SpawnMob.java255
-rw-r--r--Essentials/src/com/earth2me/essentials/TNTExplodeListener.java4
-rw-r--r--Essentials/src/com/earth2me/essentials/Teleport.java75
-rw-r--r--Essentials/src/com/earth2me/essentials/Trade.java3
-rw-r--r--Essentials/src/com/earth2me/essentials/User.java23
-rw-r--r--Essentials/src/com/earth2me/essentials/UserData.java36
-rw-r--r--Essentials/src/com/earth2me/essentials/Util.java24
-rw-r--r--Essentials/src/com/earth2me/essentials/Warps.java10
-rw-r--r--Essentials/src/com/earth2me/essentials/api/Economy.java13
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandafk.java9
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandantioch.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandbalance.java1
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandban.java10
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandessentials.java3
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandexp.java10
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandfly.java27
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java40
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandhome.java11
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandjump.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandkick.java20
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandkill.java10
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandkittycannon.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandmail.java55
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandmore.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandping.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandsell.java20
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandsethome.java12
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandsetwarp.java9
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandspawnmob.java270
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandsudo.java6
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtp.java50
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtppos.java21
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java57
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandwarp.java3
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/EssentialsCommand.java6
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/PlayerNotFoundException.java11
-rw-r--r--Essentials/src/com/earth2me/essentials/craftbukkit/FakeWorld.java36
-rw-r--r--Essentials/src/com/earth2me/essentials/craftbukkit/SetExpFix.java8
-rw-r--r--Essentials/src/com/earth2me/essentials/metrics/Metrics.java170
-rw-r--r--Essentials/src/com/earth2me/essentials/perm/BPermissions2Handler.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/signs/SignPlayerListener.java5
-rw-r--r--Essentials/src/com/earth2me/essentials/signs/SignProtection.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/signs/SignSpawnmob.java12
-rw-r--r--Essentials/src/config.yml48
-rw-r--r--Essentials/src/items.csv440
-rw-r--r--Essentials/src/messages.properties18
-rw-r--r--Essentials/src/messages_cs.properties8
-rw-r--r--Essentials/src/messages_da.properties8
-rw-r--r--Essentials/src/messages_de.properties8
-rw-r--r--Essentials/src/messages_en.properties18
-rw-r--r--Essentials/src/messages_es.properties76
-rw-r--r--Essentials/src/messages_fi.properties8
-rw-r--r--Essentials/src/messages_fr.properties222
-rw-r--r--Essentials/src/messages_it.properties8
-rw-r--r--Essentials/src/messages_nl.properties8
-rw-r--r--Essentials/src/messages_pl.properties8
-rw-r--r--Essentials/src/messages_pt.properties8
-rw-r--r--Essentials/src/messages_se.properties8
-rw-r--r--Essentials/src/plugin.yml38
-rw-r--r--Essentials/test/com/earth2me/essentials/FakeServer.java48
-rw-r--r--EssentialsAntiBuild/nbproject/build-impl.xml453
-rw-r--r--EssentialsAntiBuild/nbproject/genfiles.properties4
-rw-r--r--EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java14
-rw-r--r--EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java5
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtect.java26
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java112
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/ProtectConfig.java5
-rw-r--r--EssentialsProtect/src/com/earth2me/essentials/protect/log4j.properties4
-rw-r--r--EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawnPlayerListener.java1
-rw-r--r--EssentialsXMPP/src/com/earth2me/essentials/xmpp/XMPPManager.java4
-rw-r--r--lib/craftbukkit.jarbin11705598 -> 12039356 bytes
85 files changed, 2761 insertions, 948 deletions
diff --git a/.gitignore b/.gitignore
index 524ed1334..9251ca7e6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -42,4 +42,6 @@
/EssentialsGroupManager/.externalToolBuilders
/EssentialsAntiBuild/nbproject/private/
/EssentialsAntiBuild/dist/
-/EssentialsAntiBuild/build/ \ No newline at end of file
+/EssentialsAntiBuild/build/
+/jars
+/out \ No newline at end of file
diff --git a/BuildAll/nbproject/build-impl.xml b/BuildAll/nbproject/build-impl.xml
index d52f998c1..89e33e7cd 100644
--- a/BuildAll/nbproject/build-impl.xml
+++ b/BuildAll/nbproject/build-impl.xml
@@ -12,9 +12,9 @@ is divided into following sections:
- execution
- debugging
- javadoc
- - junit compilation
- - junit execution
- - junit debugging
+ - test compilation
+ - test execution
+ - test debugging
- applet
- cleanup
@@ -181,6 +181,7 @@ is divided into following sections:
</and>
</condition>
<property name="run.jvmargs" value=""/>
+ <property name="run.jvmargs.ide" value=""/>
<property name="javac.compilerargs" value=""/>
<property name="work.dir" value="${basedir}"/>
<condition property="no.deps">
@@ -225,6 +226,27 @@ is divided into following sections:
<property name="jar.index.metainf" value="${jar.index}"/>
<property name="copylibs.rebase" value="true"/>
<available file="${meta.inf.dir}/persistence.xml" property="has.persistence.xml"/>
+ <condition property="junit.available">
+ <or>
+ <available classname="org.junit.Test" classpath="${run.test.classpath}"/>
+ <available classname="junit.framework.Test" classpath="${run.test.classpath}"/>
+ </or>
+ </condition>
+ <condition property="testng.available">
+ <available classname="org.testng.annotations.Test" classpath="${run.test.classpath}"/>
+ </condition>
+ <condition property="junit+testng.available">
+ <and>
+ <istrue value="${junit.available}"/>
+ <istrue value="${testng.available}"/>
+ </and>
+ </condition>
+ <condition else="testng" property="testng.mode" value="mixed">
+ <istrue value="${junit+testng.available}"/>
+ </condition>
+ <condition else="" property="testng.debug.mode" value="-mixed">
+ <istrue value="${junit+testng.available}"/>
+ </condition>
</target>
<target name="-post-init">
<!-- Empty placeholder for easier customization. -->
@@ -357,11 +379,52 @@ is divided into following sections:
</sequential>
</macrodef>
</target>
- <target name="-init-macrodef-junit">
+ <target if="${junit.available}" name="-init-macrodef-junit-init">
+ <condition else="false" property="nb.junit.batch" value="true">
+ <and>
+ <istrue value="${junit.available}"/>
+ <not>
+ <isset property="test.method"/>
+ </not>
+ </and>
+ </condition>
+ <condition else="false" property="nb.junit.single" value="true">
+ <and>
+ <istrue value="${junit.available}"/>
+ <isset property="test.method"/>
+ </and>
+ </condition>
+ </target>
+ <target if="${nb.junit.single}" name="-init-macrodef-junit-single" unless="${nb.junit.batch}">
+ <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
<attribute default="${includes}" name="includes"/>
<attribute default="${excludes}" name="excludes"/>
<attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
<sequential>
<property name="junit.forkmode" value="perTest"/>
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
@@ -370,32 +433,270 @@ is divided into following sections:
<filename name="@{testincludes}"/>
</fileset>
</batchtest>
- <classpath>
- <path path="${run.test.classpath}"/>
- </classpath>
<syspropertyset>
<propertyref prefix="test-sys-prop."/>
<mapper from="test-sys-prop.*" to="*" type="glob"/>
</syspropertyset>
<formatter type="brief" usefile="false"/>
<formatter type="xml"/>
- <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
<jvmarg value="-ea"/>
- <jvmarg line="${run.jvmargs}"/>
+ <customize/>
</junit>
</sequential>
</macrodef>
</target>
- <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile, -profile-init-check" name="profile-init"/>
- <target name="-profile-pre-init">
+ <target depends="-init-macrodef-junit-init,-init-macrodef-junit-single, -init-macrodef-junit-batch" if="${junit.available}" name="-init-macrodef-junit"/>
+ <target if="${testng.available}" name="-init-macrodef-testng">
+ <macrodef name="testng" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <condition else="" property="testng.methods.arg" value="@{testincludes}.@{testmethods}">
+ <isset property="test.method"/>
+ </condition>
+ <union id="test.set">
+ <fileset dir="${test.src.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
+ <filename name="@{testincludes}"/>
+ </fileset>
+ </union>
+ <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
+ <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="BuildAll" testname="TestNG tests" workingDir="${work.dir}">
+ <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
+ <propertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </propertyset>
+ <customize/>
+ </testng>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-test-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <echo>No tests executed.</echo>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit" if="${junit.available}" name="-init-macrodef-junit-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:junit excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng" if="${testng.available}" name="-init-macrodef-testng-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:testng excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:testng>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-test-impl,-init-macrodef-junit-impl,-init-macrodef-testng-impl" name="-init-macrodef-test">
+ <macrodef name="test" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <sequential>
+ <j2seproject3:test-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
+ </customize>
+ </j2seproject3:test-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${junit.available}" name="-init-macrodef-junit-debug" unless="${nb.junit.batch}">
+ <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">
+ <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <batchtest todir="${build.test.results.dir}">
+ <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
+ <filename name="@{testincludes}"/>
+ </fileset>
+ </batchtest>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit-debug,-init-macrodef-junit-debug-batch" if="${junit.available}" name="-init-macrodef-junit-debug-impl">
+ <macrodef name="test-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:junit-debug excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:junit-debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${testng.available}" name="-init-macrodef-testng-debug">
+ <macrodef name="testng-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <element name="customize2" optional="true"/>
+ <sequential>
+ <condition else="-testclass @{testClass}" property="test.class.or.method" value="-methods @{testClass}.@{testMethod}">
+ <isset property="test.method"/>
+ </condition>
+ <condition else="-suitename BuildAll -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">
+ <matches pattern=".*\.xml" string="@{testClass}"/>
+ </condition>
+ <delete dir="${build.test.results.dir}" quiet="true"/>
+ <mkdir dir="${build.test.results.dir}"/>
+ <j2seproject3:debug classname="org.testng.TestNG" classpath="${debug.test.classpath}">
+ <customize>
+ <customize2/>
+ <jvmarg value="-ea"/>
+ <arg line="${testng.debug.mode}"/>
+ <arg line="-d ${build.test.results.dir}"/>
+ <arg line="-listener org.testng.reporters.VerboseReporter"/>
+ <arg line="${testng.cmd.args}"/>
+ </customize>
+ </j2seproject3:debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng-debug" if="${testng.available}" name="-init-macrodef-testng-debug-impl">
+ <macrodef name="testng-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <element implicit="true" name="customize2" optional="true"/>
+ <sequential>
+ <j2seproject3:testng-debug testClass="@{testClass}" testMethod="@{testMethod}">
+ <customize2/>
+ </j2seproject3:testng-debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit-debug-impl" if="${junit.available}" name="-init-macrodef-test-debug-junit">
+ <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <sequential>
+ <j2seproject3:test-debug-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
+ </customize>
+ </j2seproject3:test-debug-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng-debug-impl" if="${testng.available}" name="-init-macrodef-test-debug-testng">
+ <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <sequential>
+ <j2seproject3:testng-debug-impl testClass="@{testClass}" testMethod="@{testMethod}">
+ <customize2>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ </customize2>
+ </j2seproject3:testng-debug-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-test-debug-junit,-init-macrodef-test-debug-testng" name="-init-macrodef-test-debug"/>
+ <!--
+ pre NB7.2 profiling section; consider it deprecated
+ -->
+ <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile, -profile-init-check" if="profiler.info.jvmargs.agent" name="profile-init"/>
+ <target if="profiler.info.jvmargs.agent" name="-profile-pre-init">
<!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. -->
</target>
- <target name="-profile-post-init">
+ <target if="profiler.info.jvmargs.agent" name="-profile-post-init">
<!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. -->
</target>
- <target name="-profile-init-macrodef-profile">
+ <target if="profiler.info.jvmargs.agent" name="-profile-init-macrodef-profile">
<macrodef name="resolve">
<attribute name="name"/>
<attribute name="value"/>
@@ -427,10 +728,13 @@ is divided into following sections:
</sequential>
</macrodef>
</target>
- <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile" name="-profile-init-check">
+ <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile" if="profiler.info.jvmargs.agent" name="-profile-init-check">
<fail unless="profiler.info.jvm">Must set JVM to use for profiling in profiler.info.jvm</fail>
<fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail>
</target>
+ <!--
+ end of pre NB7.2 profiling section
+ -->
<target depends="-init-debug-args" name="-init-macrodef-nbjpda">
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
<attribute default="${main.class}" name="name"/>
@@ -488,6 +792,7 @@ is divided into following sections:
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
<jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
<classpath>
<path path="@{classpath}"/>
</classpath>
@@ -504,6 +809,7 @@ is divided into following sections:
<macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
<attribute default="${main.class}" name="classname"/>
<attribute default="${run.classpath}" name="classpath"/>
+ <attribute default="jvm" name="jvm"/>
<element name="customize" optional="true"/>
<sequential>
<java classname="@{classname}" dir="${work.dir}" fork="true">
@@ -511,6 +817,7 @@ is divided into following sections:
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
<jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
<classpath>
<path path="@{classpath}"/>
</classpath>
@@ -537,6 +844,9 @@ is divided into following sections:
<path path="${run.classpath.without.build.classes.dir}"/>
<chainedmapper>
<flattenmapper/>
+ <filtermapper>
+ <replacestring from=" " to="%20"/>
+ </filtermapper>
<globmapper from="*" to="lib/*"/>
</chainedmapper>
</pathconvert>
@@ -582,7 +892,7 @@ is divided into following sections:
<target depends="-init-ap-cmdline-properties,-init-ap-cmdline-supported" name="-init-ap-cmdline">
<property name="ap.cmd.line.internal" value=""/>
</target>
- <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/>
+ <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-test,-init-macrodef-test-debug,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/>
<!--
===================
COMPILATION SECTION
@@ -861,7 +1171,11 @@ is divided into following sections:
PROFILING SECTION
=================
-->
- <target depends="profile-init,compile" description="Profile a project in the IDE." if="netbeans.home" name="profile">
+ <!--
+ pre NB7.2 profiler integration
+ -->
+ <target depends="profile-init,compile" description="Profile a project in the IDE." if="profiler.info.jvmargs.agent" name="-profile-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -869,8 +1183,9 @@ is divided into following sections:
</nbprofiledirect>
<profile/>
</target>
- <target depends="profile-init,compile-single" description="Profile a selected class in the IDE." if="netbeans.home" name="profile-single">
+ <target depends="profile-init,compile-single" description="Profile a selected class in the IDE." if="profiler.info.jvmargs.agent" name="-profile-single-pre72">
<fail unless="profile.class">Must select one file in the IDE or set profile.class</fail>
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -878,12 +1193,8 @@ is divided into following sections:
</nbprofiledirect>
<profile classname="${profile.class}"/>
</target>
- <!--
- =========================
- APPLET PROFILING SECTION
- =========================
- -->
- <target depends="profile-init,compile-single" if="netbeans.home" name="profile-applet">
+ <target depends="profile-init,compile-single" if="profiler.info.jvmargs.agent" name="-profile-applet-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -895,12 +1206,8 @@ is divided into following sections:
</customize>
</profile>
</target>
- <!--
- =========================
- TESTS PROFILING SECTION
- =========================
- -->
- <target depends="profile-init,compile-test-single" if="netbeans.home" name="profile-test-single">
+ <target depends="profile-init,compile-test-single" if="profiler.info.jvmargs.agent" name="-profile-test-single-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.test.classpath}"/>
@@ -923,6 +1230,42 @@ is divided into following sections:
</junit>
</target>
<!--
+ end of pre NB72 profiling section
+ -->
+ <target if="netbeans.home" name="-profile-check">
+ <condition property="profiler.configured">
+ <or>
+ <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-agentpath:"/>
+ <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-javaagent:"/>
+ </or>
+ </condition>
+ </target>
+ <target depends="-profile-check,-profile-pre72" description="Profile a project in the IDE." if="profiler.configured" name="profile" unless="profiler.info.jvmargs.agent">
+ <startprofiler/>
+ <antcall target="run"/>
+ </target>
+ <target depends="-profile-check,-profile-single-pre72" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-single" unless="profiler.info.jvmargs.agent">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <startprofiler/>
+ <antcall target="run-single"/>
+ </target>
+ <target depends="-profile-test-single-pre72" description="Profile a selected test in the IDE." name="profile-test-single"/>
+ <target depends="-profile-check" description="Profile a selected test in the IDE." if="profiler.configured" name="profile-test" unless="profiler.info.jvmargs">
+ <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
+ <startprofiler/>
+ <antcall target="test-single"/>
+ </target>
+ <target depends="-profile-check" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-test-with-main">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <startprofiler/>
+ <antcal target="run-test-with-main"/>
+ </target>
+ <target depends="-profile-check,-profile-applet-pre72" if="profiler.configured" name="profile-applet" unless="profiler.info.jvmargs.agent">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <startprofiler/>
+ <antcall target="run-applet"/>
+ </target>
+ <!--
===============
JAVADOC SECTION
===============
@@ -965,7 +1308,7 @@ is divided into following sections:
<target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
<!--
=========================
- JUNIT COMPILATION SECTION
+ TEST COMPILATION SECTION
=========================
-->
<target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
@@ -1008,14 +1351,14 @@ is divided into following sections:
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
<!--
=======================
- JUNIT EXECUTION SECTION
+ TEST EXECUTION SECTION
=======================
-->
<target depends="init" if="have.tests" name="-pre-test-run">
<mkdir dir="${build.test.results.dir}"/>
</target>
<target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
- <j2seproject3:junit testincludes="**/*Test.java"/>
+ <j2seproject3:test testincludes="**/*Test.java"/>
</target>
<target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
@@ -1028,39 +1371,40 @@ is divided into following sections:
</target>
<target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
- <j2seproject3:junit excludes="" includes="${test.includes}"/>
+ <j2seproject3:test excludes="" includes="${test.includes}" testincludes="${test.includes}"/>
</target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
</target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single-method">
+ <fail unless="test.class">Must select some files in the IDE or set test.class</fail>
+ <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
+ <j2seproject3:test excludes="" includes="${javac.includes}" testincludes="${test.class}" testmethods="${test.method}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method" if="have.tests" name="-post-test-run-single-method">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method,-post-test-run-single-method" description="Run single unit test." name="test-single-method"/>
<!--
=======================
- JUNIT DEBUGGING SECTION
+ TEST DEBUGGING SECTION
=======================
-->
- <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test">
<fail unless="test.class">Must select one file in the IDE or set test.class</fail>
- <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
- <delete file="${test.report.file}"/>
- <mkdir dir="${build.test.results.dir}"/>
- <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
- <customize>
- <syspropertyset>
- <propertyref prefix="test-sys-prop."/>
- <mapper from="test-sys-prop.*" to="*" type="glob"/>
- </syspropertyset>
- <arg value="${test.class}"/>
- <arg value="showoutput=true"/>
- <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
- <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
- </customize>
- </j2seproject3:debug>
+ <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testincludes="${javac.includes}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test-method">
+ <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
+ <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
+ <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testMethod="${test.method}" testincludes="${test.class}" testmethods="${test.method}"/>
</target>
<target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
<j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
</target>
<target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
+ <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test-method" name="debug-test-method"/>
<target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
<j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
</target>
@@ -1188,9 +1532,12 @@ is divided into following sections:
<target name="-check-call-dep">
<property file="${call.built.properties}" prefix="already.built."/>
<condition property="should.call.dep">
- <not>
- <isset property="already.built.${call.subproject}"/>
- </not>
+ <and>
+ <not>
+ <isset property="already.built.${call.subproject}"/>
+ </not>
+ <available file="${call.script}"/>
+ </and>
</condition>
</target>
<target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">
diff --git a/BuildAll/nbproject/genfiles.properties b/BuildAll/nbproject/genfiles.properties
index de7702440..cf660eaf5 100644
--- a/BuildAll/nbproject/genfiles.properties
+++ b/BuildAll/nbproject/genfiles.properties
@@ -4,5 +4,5 @@ build.xml.stylesheet.CRC32=28e38971@1.50.3.46
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
nbproject/build-impl.xml.data.CRC32=b4df970c
-nbproject/build-impl.xml.script.CRC32=1fd6d3cc
-nbproject/build-impl.xml.stylesheet.CRC32=fcddb364@1.50.3.46
+nbproject/build-impl.xml.script.CRC32=8905537e
+nbproject/build-impl.xml.stylesheet.CRC32=6ddba6b6@1.53.1.46
diff --git a/Essentials/src/com/earth2me/essentials/Essentials.java b/Essentials/src/com/earth2me/essentials/Essentials.java
index e0f5706ca..9ba2c696a 100644
--- a/Essentials/src/com/earth2me/essentials/Essentials.java
+++ b/Essentials/src/com/earth2me/essentials/Essentials.java
@@ -65,7 +65,7 @@ import org.yaml.snakeyaml.error.YAMLException;
public class Essentials extends JavaPlugin implements IEssentials
{
- public static final int BUKKIT_VERSION = 2352;
+ public static final int BUKKIT_VERSION = 2455;
private static final Logger LOGGER = Logger.getLogger("Minecraft");
private transient ISettings settings;
private final transient TNTExplodeListener tntListener = new TNTExplodeListener(this);
@@ -467,15 +467,21 @@ public class Essentials extends JavaPlugin implements IEssentials
}
if (base instanceof String)
{
- final User user = userMap.getUser((String)base);
- if (user != null && user.getBase() instanceof OfflinePlayer)
- {
- ((OfflinePlayer)user.getBase()).setName((String)base);
- }
- return user;
+ return getOfflineUser((String)base);
}
return null;
}
+
+ @Override
+ public User getOfflineUser(final String name)
+ {
+ final User user = userMap.getUser(name);
+ if (user != null && user.getBase() instanceof OfflinePlayer)
+ {
+ ((OfflinePlayer)user.getBase()).setName(name);
+ }
+ return user;
+ }
private <T extends Player> User getUser(final T base)
{
@@ -509,17 +515,6 @@ public class Essentials extends JavaPlugin implements IEssentials
}
@Override
- public User getOfflineUser(final String name)
- {
- final User user = userMap.getUser(name);
- if (user != null && user.getBase() instanceof OfflinePlayer)
- {
- ((OfflinePlayer)user.getBase()).setName(name);
- }
- return user;
- }
-
- @Override
public World getWorld(final String name)
{
if (name.matches("[0-9]+"))
diff --git a/Essentials/src/com/earth2me/essentials/EssentialsConf.java b/Essentials/src/com/earth2me/essentials/EssentialsConf.java
index d6414fb05..70e683da4 100644
--- a/Essentials/src/com/earth2me/essentials/EssentialsConf.java
+++ b/Essentials/src/com/earth2me/essentials/EssentialsConf.java
@@ -344,6 +344,11 @@ public class EssentialsConf extends YamlConfiguration
}
}
+ public void saveWithError() throws IOException
+ {
+ save(configFile);
+ }
+
@Override
public synchronized void save(final File file) throws IOException
{
diff --git a/Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java b/Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java
index 0077d988c..e93c61952 100644
--- a/Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java
+++ b/Essentials/src/com/earth2me/essentials/EssentialsEntityListener.java
@@ -5,10 +5,7 @@ import java.util.List;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.Material;
-import org.bukkit.entity.Ageable;
-import org.bukkit.entity.Entity;
-import org.bukkit.entity.LivingEntity;
-import org.bukkit.entity.Player;
+import org.bukkit.entity.*;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
@@ -27,6 +24,7 @@ public class EssentialsEntityListener implements Listener
this.ess = ess;
}
+ // This method does something undocumented reguarding certain bucket types #EasterEgg
@EventHandler(priority = EventPriority.LOW)
public void onEntityDamage(final EntityDamageByEntityEvent event)
{
@@ -36,46 +34,18 @@ public class EssentialsEntityListener implements Listener
{
final User defender = ess.getUser(eDefend);
final User attacker = ess.getUser(eAttack);
-
- if (ess.getSettings().getLoginAttackDelay() > 0 && !attacker.isAuthorized("essentials.pvpdelay.exempt")
- && (System.currentTimeMillis() < (attacker.getLastLogin() + ess.getSettings().getLoginAttackDelay())))
- {
- event.setCancelled(true);
- }
-
- if (attacker.hasInvulnerabilityAfterTeleport() || defender.hasInvulnerabilityAfterTeleport())
- {
- event.setCancelled(true);
- }
-
- if (attacker.isGodModeEnabled() && !attacker.isAuthorized("essentials.god.pvp"))
+ onPlayerVsPlayerDamage(event, defender, attacker);
+ onPlayerVsPlayerPowertool(event, defender, attacker);
+ }
+ else if (eDefend instanceof Player && eAttack instanceof Projectile)
+ {
+ Entity shooter = ((Projectile)event.getDamager()).getShooter();
+ if (shooter instanceof Player)
{
- event.setCancelled(true);
- }
-
- attacker.updateActivity(true);
- final List<String> commandList = attacker.getPowertool(attacker.getItemInHand());
- if (commandList != null && !commandList.isEmpty())
- {
- for (final String command : commandList)
- {
- if (command != null && !command.isEmpty())
- {
- ess.scheduleSyncDelayedTask(
- new Runnable()
- {
- @Override
- public void run()
- {
- attacker.getServer().dispatchCommand(attacker.getBase(), command.replaceAll("\\{player\\}", defender.getName()));
- LOGGER.log(Level.INFO, String.format("[PT] %s issued server command: /%s", attacker.getName(), command));
- }
- });
-
- event.setCancelled(true);
- return;
- }
- }
+ final User defender = ess.getUser(eDefend);
+ final User attacker = ess.getUser(shooter);
+ onPlayerVsPlayerDamage(event, defender, attacker);
+ onPlayerVsPlayerPowertool(event, defender, attacker);
}
}
else if (eAttack instanceof Player)
@@ -97,6 +67,59 @@ public class EssentialsEntityListener implements Listener
}
}
+ private void onPlayerVsPlayerDamage(final EntityDamageByEntityEvent event, final User defender, final User attacker)
+ {
+ if (ess.getSettings().getLoginAttackDelay() > 0 && !attacker.isAuthorized("essentials.pvpdelay.exempt")
+ && (System.currentTimeMillis() < (attacker.getLastLogin() + ess.getSettings().getLoginAttackDelay())))
+ {
+ event.setCancelled(true);
+ }
+
+ if (attacker.hasInvulnerabilityAfterTeleport() || defender.hasInvulnerabilityAfterTeleport())
+ {
+ event.setCancelled(true);
+ }
+
+ if (attacker.isGodModeEnabled() && !attacker.isAuthorized("essentials.god.pvp"))
+ {
+ event.setCancelled(true);
+ }
+
+ if (attacker.isHidden() && !attacker.isAuthorized("essentials.vanish.pvp"))
+ {
+ event.setCancelled(true);
+ }
+
+ attacker.updateActivity(true);
+ }
+
+ private void onPlayerVsPlayerPowertool(final EntityDamageByEntityEvent event, final User defender, final User attacker)
+ {
+ final List<String> commandList = attacker.getPowertool(attacker.getItemInHand());
+ if (commandList != null && !commandList.isEmpty())
+ {
+ for (final String command : commandList)
+ {
+ if (command != null && !command.isEmpty())
+ {
+ ess.scheduleSyncDelayedTask(
+ new Runnable()
+ {
+ @Override
+ public void run()
+ {
+ attacker.getServer().dispatchCommand(attacker.getBase(), command.replaceAll("\\{player\\}", defender.getName()));
+ LOGGER.log(Level.INFO, String.format("[PT] %s issued server command: /%s", attacker.getName(), command));
+ }
+ });
+
+ event.setCancelled(true);
+ return;
+ }
+ }
+ }
+ }
+
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
public void onEntityDamage(final EntityDamageEvent event)
{
diff --git a/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java b/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
index 8ef218a67..56098832e 100644
--- a/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
+++ b/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
@@ -23,8 +23,8 @@ import org.bukkit.event.Listener;
import org.bukkit.event.inventory.InventoryClickEvent;
import org.bukkit.event.inventory.InventoryCloseEvent;
import org.bukkit.event.inventory.InventoryType;
-import org.bukkit.event.player.PlayerLoginEvent.Result;
import org.bukkit.event.player.*;
+import org.bukkit.event.player.PlayerLoginEvent.Result;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
import org.bukkit.inventory.InventoryHolder;
import org.bukkit.inventory.ItemStack;
@@ -166,7 +166,8 @@ public class EssentialsPlayerListener implements Listener
for (String p : ess.getVanishedPlayers())
{
Player toVanish = ess.getUser(p).getBase();
- if (toVanish.isOnline()) {
+ if (toVanish.isOnline())
+ {
user.hidePlayer(toVanish);
}
}
@@ -174,7 +175,14 @@ public class EssentialsPlayerListener implements Listener
if (user.isAuthorized("essentials.sleepingignored"))
{
- user.setSleepingIgnored(true);
+ ess.scheduleSyncDelayedTask(new Runnable()
+ {
+ @Override
+ public void run()
+ {
+ user.setSleepingIgnored(true);
+ }
+ });
}
if (!ess.getSettings().isCommandDisabled("motd") && user.isAuthorized("essentials.motd"))
@@ -204,7 +212,11 @@ public class EssentialsPlayerListener implements Listener
final List<String> mail = user.getMails();
if (mail.isEmpty())
{
- user.sendMessage(_("noNewMail"));
+ final String msg = _("noNewMail");
+ if (!msg.isEmpty())
+ {
+ user.sendMessage(msg);
+ }
}
else
{
@@ -213,6 +225,7 @@ public class EssentialsPlayerListener implements Listener
}
}
+ // Makes the compass item ingame always point to the first essentials home. #EasterEgg
private void updateCompass(final User user)
{
Location loc = user.getHome(user.getLocation());
@@ -351,9 +364,10 @@ public class EssentialsPlayerListener implements Listener
public void onPlayerChangedWorldHack(final PlayerChangedWorldEvent event)
{
final Player user = event.getPlayer();
- if (user.getGameMode() != GameMode.CREATIVE) {
- user.setAllowFlight(false);
- }
+ if (user.getGameMode() != GameMode.CREATIVE)
+ {
+ user.setAllowFlight(false);
+ }
user.setFlySpeed(0.1f);
user.setWalkSpeed(0.2f);
}
@@ -403,6 +417,7 @@ public class EssentialsPlayerListener implements Listener
if (event.getItem() != null && event.getItem().getTypeId() != AIR)
{
final User user = ess.getUser(event.getPlayer());
+ user.updateActivity(true);
if (user.hasPowerTools() && user.arePowerToolsEnabled() && usePowertools(user, event.getItem().getTypeId()))
{
event.setCancelled(true);
@@ -414,6 +429,7 @@ public class EssentialsPlayerListener implements Listener
}
}
+ // This method allows the /jump lock feature to work, allows teleporting while flying #EasterEgg
private void useFlyClickJump(final User user)
{
try
@@ -538,4 +554,11 @@ public class EssentialsPlayerListener implements Listener
user.setEnderSee(false);
}
}
+
+ @EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
+ public void onPlayerFishEvent(final PlayerFishEvent event)
+ {
+ final User user = ess.getUser(event.getPlayer());
+ user.updateActivity(true);
+ }
} \ No newline at end of file
diff --git a/Essentials/src/com/earth2me/essentials/EssentialsPluginListener.java b/Essentials/src/com/earth2me/essentials/EssentialsPluginListener.java
index 2ec8538ca..56cabf6cb 100644
--- a/Essentials/src/com/earth2me/essentials/EssentialsPluginListener.java
+++ b/Essentials/src/com/earth2me/essentials/EssentialsPluginListener.java
@@ -20,6 +20,9 @@ public class EssentialsPluginListener implements Listener, IConf
@EventHandler(priority = EventPriority.MONITOR)
public void onPluginEnable(final PluginEnableEvent event)
{
+ if (event.getPlugin().getName().equals("EssentialsChat")) {
+ ess.getSettings().setEssentialsChatActive(true);
+ }
ess.getPermissionsHandler().checkPermissions();
ess.getAlternativeCommandsHandler().addPlugin(event.getPlugin());
if (!ess.getPaymentMethod().hasMethod() && ess.getPaymentMethod().setMethod(ess.getServer().getPluginManager()))
@@ -31,6 +34,9 @@ public class EssentialsPluginListener implements Listener, IConf
@EventHandler(priority = EventPriority.MONITOR)
public void onPluginDisable(final PluginDisableEvent event)
{
+ if (event.getPlugin().getName().equals("EssentialsChat")) {
+ ess.getSettings().setEssentialsChatActive(false);
+ }
ess.getPermissionsHandler().checkPermissions();
ess.getAlternativeCommandsHandler().removePlugin(event.getPlugin());
// Check to see if the plugin thats being disabled is the one we are using
diff --git a/Essentials/src/com/earth2me/essentials/ISettings.java b/Essentials/src/com/earth2me/essentials/ISettings.java
index d8c421fde..fb0073c8a 100644
--- a/Essentials/src/com/earth2me/essentials/ISettings.java
+++ b/Essentials/src/com/earth2me/essentials/ISettings.java
@@ -179,4 +179,8 @@ public interface ISettings extends IConf
double getMaxFlySpeed();
double getMaxWalkSpeed();
+
+ public int getMailsPerMinute();
+
+ public void setEssentialsChatActive(boolean b);
}
diff --git a/Essentials/src/com/earth2me/essentials/IUser.java b/Essentials/src/com/earth2me/essentials/IUser.java
index 8c0d6212f..43f9d7210 100644
--- a/Essentials/src/com/earth2me/essentials/IUser.java
+++ b/Essentials/src/com/earth2me/essentials/IUser.java
@@ -42,4 +42,6 @@ public interface IUser extends Player
Teleport getTeleport();
void setJail(String jail);
+
+ boolean isIgnoreExempt();
}
diff --git a/Essentials/src/com/earth2me/essentials/Kit.java b/Essentials/src/com/earth2me/essentials/Kit.java
index d0a3b5d7e..89965e589 100644
--- a/Essentials/src/com/earth2me/essentials/Kit.java
+++ b/Essentials/src/com/earth2me/essentials/Kit.java
@@ -37,7 +37,7 @@ public class Kit
}
- public static void checkTime(final User user, final String kitName, final Map<String, Object> els) throws NoChargeException
+ public static void checkTime(final User user, final String kitName, final Map<String, Object> els) throws Exception
{
if (user.isAuthorized("essentials.kit.exemptdelay")) {
return;
@@ -46,7 +46,7 @@ public class Kit
final Calendar time = new GregorianCalendar();
// Take the current time, and remove the delay from it.
- final double delay = els.containsKey("delay") ? ((Number)els.get("delay")).doubleValue() : 0L;
+ final double delay = els.containsKey("delay") ? ((Number)els.get("delay")).doubleValue() : 0.0d;
final Calendar earliestTime = new GregorianCalendar();
earliestTime.add(Calendar.SECOND, -(int)delay);
earliestTime.add(Calendar.MILLISECOND, -(int)((delay * 1000.0) % 1000.0));
@@ -56,7 +56,7 @@ public class Kit
// When was the last kit used?
final long lastTime = user.getKitTimestamp(kitName);
- if (lastTime < earliestLong)
+ if (lastTime < earliestLong || lastTime == 0L)
{
user.setKitTimestamp(kitName, time.getTimeInMillis());
}
@@ -66,6 +66,11 @@ public class Kit
// If this happens, let's give the user the benifit of the doubt.
user.setKitTimestamp(kitName, time.getTimeInMillis());
}
+ else if (earliestLong < 0L)
+ {
+ user.sendMessage(_("kitOnce"));
+ throw new NoChargeException();
+ }
else
{
time.setTimeInMillis(lastTime);
@@ -102,6 +107,13 @@ public class Kit
boolean spew = false;
for (String d : items)
{
+ if (d.startsWith(ess.getSettings().getCurrencySymbol()))
+ {
+ Double value = Double.parseDouble(d.substring(ess.getSettings().getCurrencySymbol().length()).trim());
+ Trade t = new Trade(value, ess);
+ t.pay(user);
+ continue;
+ }
final String[] parts = d.split(" ");
final String[] item = parts[0].split("[:+',;.]", 2);
final int id = Material.getMaterial(Integer.parseInt(item[0])).getId();
diff --git a/Essentials/src/com/earth2me/essentials/Mob.java b/Essentials/src/com/earth2me/essentials/Mob.java
index 6cef12a7c..fccef1b24 100644
--- a/Essentials/src/com/earth2me/essentials/Mob.java
+++ b/Essentials/src/com/earth2me/essentials/Mob.java
@@ -6,11 +6,14 @@ import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.Location;
import org.bukkit.Server;
+import org.bukkit.World;
import org.bukkit.entity.EntityType;
import org.bukkit.entity.LivingEntity;
import org.bukkit.entity.Player;
+// Suffixes can be appended on the end of a mob name to make it plural
+// Entities without a suffix, will default to 's'
public enum Mob
{
CHICKEN("Chicken", Enemies.FRIENDLY, EntityType.CHICKEN),
@@ -37,7 +40,10 @@ public enum Mob
MAGMACUBE("MagmaCube", Enemies.ENEMY, EntityType.MAGMA_CUBE),
SNOWMAN("Snowman", Enemies.FRIENDLY, "", EntityType.SNOWMAN),
OCELOT("Ocelot", Enemies.NEUTRAL, EntityType.OCELOT),
- IRONGOLEM("IronGolem", Enemies.NEUTRAL, EntityType.IRON_GOLEM);
+ IRONGOLEM("IronGolem", Enemies.NEUTRAL, EntityType.IRON_GOLEM),
+ WITHER("Wither", Enemies.ENEMY, EntityType.WITHER),
+ BAT("Bat", Enemies.FRIENDLY, EntityType.BAT),
+ WITCH("Witch", Enemies.ENEMY, EntityType.WITCH);
public static final Logger logger = Logger.getLogger("Minecraft");
@@ -68,14 +74,19 @@ public enum Mob
hashMap.put(mob.name.toLowerCase(Locale.ENGLISH), mob);
}
}
-
+
public static Set<String> getMobList() {
return Collections.unmodifiableSet(hashMap.keySet());
}
public LivingEntity spawn(final Player player, final Server server, final Location loc) throws MobException
{
- final LivingEntity entity = player.getWorld().spawn(loc, (Class<? extends LivingEntity>)this.bukkitType.getEntityClass());
+ return spawn(player.getWorld(), server, loc);
+ }
+
+ public LivingEntity spawn(final World world, final Server server, final Location loc) throws MobException
+ {
+ final LivingEntity entity = world.spawn(loc, (Class<? extends LivingEntity>)this.bukkitType.getEntityClass());
if (entity == null)
{
logger.log(Level.WARNING, _("unableToSpawnMob"));
diff --git a/Essentials/src/com/earth2me/essentials/OfflinePlayer.java b/Essentials/src/com/earth2me/essentials/OfflinePlayer.java
index e861056ad..571873384 100644
--- a/Essentials/src/com/earth2me/essentials/OfflinePlayer.java
+++ b/Essentials/src/com/earth2me/essentials/OfflinePlayer.java
@@ -842,6 +842,12 @@ public class OfflinePlayer implements Player
}
@Override
+ public void setBedSpawnLocation(Location lctn, boolean force)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
public void playEffect(EntityEffect ee)
{
throw new UnsupportedOperationException("Not supported yet.");
@@ -1105,4 +1111,10 @@ public class OfflinePlayer implements Player
{
throw new UnsupportedOperationException("Not supported yet.");
}
+
+ @Override
+ public void giveExpLevels(int i)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
}
diff --git a/Essentials/src/com/earth2me/essentials/Settings.java b/Essentials/src/com/earth2me/essentials/Settings.java
index fff129d52..416602c4d 100644
--- a/Essentials/src/com/earth2me/essentials/Settings.java
+++ b/Essentials/src/com/earth2me/essentials/Settings.java
@@ -12,6 +12,7 @@ import java.util.*;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.ChatColor;
+import org.bukkit.command.PluginCommand;
import org.bukkit.configuration.ConfigurationSection;
import org.bukkit.configuration.MemoryConfiguration;
import org.bukkit.event.EventPriority;
@@ -189,6 +190,11 @@ public class Settings implements ISettings
final ConfigurationSection newSection = new MemoryConfiguration();
for (String command : section.getKeys(false))
{
+ PluginCommand cmd = ess.getServer().getPluginCommand(command);
+ if (cmd == null || !cmd.getPlugin().equals(ess))
+ {
+ ess.getLogger().warning("Invalid command cost. '" + command + "' is not a command handled by Essentials.");
+ }
if (section.isDouble(command))
{
newSection.set(command.toLowerCase(Locale.ENGLISH), section.getDouble(command));
@@ -197,6 +203,24 @@ public class Settings implements ISettings
{
newSection.set(command.toLowerCase(Locale.ENGLISH), (double)section.getInt(command));
}
+ else if (section.isString(command))
+ {
+ String costString = section.getString(command);
+ try
+ {
+ double cost = Double.parseDouble(costString.trim().replace(getCurrencySymbol(), "").replaceAll("\\W", ""));
+ newSection.set(command.toLowerCase(Locale.ENGLISH), cost);
+ }
+ catch (NumberFormatException ex)
+ {
+ ess.getLogger().warning("Invalid command cost for: " + command + " (" + costString + ")");
+ }
+
+ }
+ else
+ {
+ ess.getLogger().warning("Invalid command cost for: " + command);
+ }
}
return newSection;
}
@@ -439,6 +463,7 @@ public class Settings implements ISettings
chatRadius = _getChatRadius();
commandCosts = _getCommandCosts();
warnOnBuildDisallow = _warnOnBuildDisallow();
+ mailsPerMinute = _getMailsPerMinute();
}
private List<Integer> itemSpawnBl = new ArrayList<Integer>();
@@ -557,6 +582,8 @@ public class Settings implements ISettings
return config.getString("locale", "");
}
+ //This method should always only return one character due to the implementation of the calling methods
+ //If you need to use a string currency, for example "coins", use the translation key 'currency'.
@Override
public String getCurrencySymbol()
{
@@ -695,6 +722,7 @@ public class Settings implements ISettings
}
private boolean prefixsuffixconfigured = false;
private boolean addprefixsuffix = false;
+ private boolean essentialsChatActive = false;
private boolean _addPrefixSuffix()
{
@@ -707,9 +735,15 @@ public class Settings implements ISettings
}
@Override
+ public void setEssentialsChatActive(boolean essentialsChatActive)
+ {
+ this.essentialsChatActive = essentialsChatActive;
+ }
+
+ @Override
public boolean addPrefixSuffix()
{
- return prefixsuffixconfigured ? addprefixsuffix : ess.getServer().getPluginManager().isPluginEnabled("EssentialsChat");
+ return prefixsuffixconfigured ? addprefixsuffix : essentialsChatActive;
}
private boolean disablePrefix = false;
@@ -928,10 +962,24 @@ public class Settings implements ISettings
return maxSpeed > 1.0 ? 1.0 : Math.abs(maxSpeed);
}
+ //This option does not exist in the config.yml because it wasn't yet implemented in bukkit
+ //The code was commented out in the /speed command
@Override
public double getMaxWalkSpeed()
{
double maxSpeed = config.getDouble("max-walk-speed", 0.8);
return maxSpeed > 1.0 ? 1.0 : Math.abs(maxSpeed);
}
+ private int mailsPerMinute;
+
+ private int _getMailsPerMinute()
+ {
+ return config.getInt("mails-per-minute", 1000);
+ }
+
+ @Override
+ public int getMailsPerMinute()
+ {
+ return mailsPerMinute;
+ }
}
diff --git a/Essentials/src/com/earth2me/essentials/SpawnMob.java b/Essentials/src/com/earth2me/essentials/SpawnMob.java
new file mode 100644
index 000000000..8ea5c9492
--- /dev/null
+++ b/Essentials/src/com/earth2me/essentials/SpawnMob.java
@@ -0,0 +1,255 @@
+package com.earth2me.essentials;
+
+import static com.earth2me.essentials.I18n._;
+import com.earth2me.essentials.Mob.MobException;
+import java.util.HashSet;
+import java.util.Locale;
+import java.util.Random;
+import java.util.Set;
+import org.bukkit.DyeColor;
+import org.bukkit.Location;
+import org.bukkit.Server;
+import org.bukkit.block.Block;
+import org.bukkit.command.CommandSender;
+import org.bukkit.entity.*;
+import org.bukkit.material.Colorable;
+
+
+public class SpawnMob
+{
+ public static String mobList(final User user)
+ {
+ final Set<String> mobList = Mob.getMobList();
+ final Set<String> availableList = new HashSet<String>();
+ for (String mob : mobList)
+ {
+ if (user.isAuthorized("essentials.spawnmob." + mob.toLowerCase()))
+ {
+ availableList.add(mob);
+ }
+ }
+ if (availableList.isEmpty())
+ {
+ availableList.add(_("none"));
+ }
+ return Util.joinList(availableList);
+ }
+
+ public static String[] mobData(final String mobString)
+ {
+ String[] returnString = new String[4];
+
+ final String[] parts = mobString.split(",");
+ String[] mobParts = parts[0].split(":");
+
+ returnString[0] = mobParts[0];
+ if (mobParts.length == 2)
+ {
+ returnString[1] = mobParts[1];
+ }
+
+ if (parts.length > 1)
+ {
+ String[] mountParts = parts[1].split(":");
+ returnString[2] = mountParts[0];
+ if (mountParts.length == 2)
+ {
+ returnString[3] = mountParts[1];
+ }
+ }
+
+ return returnString;
+ }
+
+ // This method spawns a mob where the user is looking, owned by user
+ public static void spawnmob(final IEssentials ess, final Server server, final User user, final String[] Data, int mobCount) throws Exception
+ {
+ final Block block = Util.getTarget(user).getBlock();
+ if (block == null)
+ {
+ throw new Exception(_("unableToSpawnMob"));
+ }
+ spawnmob(ess, server, user, user, block.getLocation(), Data, mobCount);
+ }
+
+ // This method spawns a mob at loc, owned by noone
+ public static void spawnmob(final IEssentials ess, final Server server, final CommandSender sender, final Location loc, final String[] Data, int mobCount) throws Exception
+ {
+ spawnmob(ess, server, sender, null, loc, Data, mobCount);
+ }
+
+ // This method spawns a mob at target, owned by target
+ public static void spawnmob(final IEssentials ess, final Server server, final CommandSender sender, final User target, final String[] Data, int mobCount) throws Exception
+ {
+ spawnmob(ess, server, sender, target, target.getLocation(), Data, mobCount);
+ }
+
+ // This method spawns a mob at loc, owned by target
+ public static void spawnmob(final IEssentials ess, final Server server, final CommandSender sender, final User target, final Location loc, final String[] Data, int mobCount) throws Exception
+ {
+ final Location sloc = Util.getSafeDestination(loc);
+ final String mobType = Data[0];
+ final String mobData = Data[1];
+ final String mountType = Data[2];
+ final String mountData = Data[3];
+
+ Mob mob = Mob.fromName(mobType);
+ Mob mobMount = null;
+
+ checkSpawnable(ess, sender, mob);
+
+ if (mountType != null)
+ {
+ mobMount = Mob.fromName(mountType);
+ checkSpawnable(ess, sender, mobMount);
+ }
+
+ int serverLimit = ess.getSettings().getSpawnMobLimit();
+ if (mobCount > serverLimit)
+ {
+ mobCount = serverLimit;
+ sender.sendMessage(_("mobSpawnLimit"));
+ }
+
+ try
+ {
+ for (int i = 0; i < mobCount; i++)
+ {
+ spawnMob(ess, server, sender, target, sloc, mob, mobData, mobMount, mountData);
+ }
+ sender.sendMessage(mobCount + " " + mob.name.toLowerCase(Locale.ENGLISH) + mob.suffix + " " + _("spawned"));
+ }
+ catch (MobException e1)
+ {
+ throw new Exception(_("unableToSpawnMob"), e1);
+ }
+ catch (NumberFormatException e2)
+ {
+ throw new Exception(_("numberRequired"), e2);
+ }
+ catch (NullPointerException np)
+ {
+ throw new Exception(_("soloMob"), np);
+ }
+ }
+
+ private static void spawnMob(final IEssentials ess, final Server server, final CommandSender sender, final User target, final Location sloc, Mob mob, String mobData, Mob mobMount, String mountData) throws Exception
+ {
+ Entity spawnedMob = mob.spawn(sloc.getWorld(), server, sloc);
+ Entity spawnedMount = null;
+
+ if (mobMount != null)
+ {
+ spawnedMount = mobMount.spawn(sloc.getWorld(), server, sloc);
+ spawnedMob.setPassenger(spawnedMount);
+ }
+ if (mobData != null)
+ {
+ changeMobData(mob.getType(), spawnedMob, mobData, target);
+ }
+ if (spawnedMount != null && mountData != null)
+ {
+ changeMobData(mobMount.getType(), spawnedMount, mountData, target);
+ }
+ }
+
+ private static void checkSpawnable(IEssentials ess, CommandSender sender, Mob mob) throws Exception
+ {
+ if (mob == null)
+ {
+ throw new Exception(_("invalidMob"));
+ }
+
+ if (ess.getSettings().getProtectPreventSpawn(mob.getType().toString().toLowerCase(Locale.ENGLISH)))
+ {
+ throw new Exception(_("disabledToSpawnMob"));
+ }
+
+ if (sender instanceof User && !((User)sender).isAuthorized("essentials.spawnmob." + mob.name.toLowerCase()))
+ {
+ throw new Exception(_("noPermToSpawnMob"));
+ }
+ }
+
+ private static void changeMobData(final EntityType type, final Entity spawned, String data, final User target) throws Exception
+ {
+ data = data.toLowerCase(Locale.ENGLISH);
+
+ if (spawned instanceof Slime)
+ {
+ try
+ {
+ ((Slime)spawned).setSize(Integer.parseInt(data));
+ }
+ catch (Exception e)
+ {
+ throw new Exception(_("slimeMalformedSize"), e);
+ }
+ }
+ if (spawned instanceof Ageable && data.contains("baby"))
+ {
+ ((Ageable)spawned).setBaby();
+ return;
+ }
+ if (spawned instanceof Colorable)
+ {
+ final String color = data.toUpperCase(Locale.ENGLISH).replace("BABY", "");
+ try
+ {
+ if (color.equals("RANDOM"))
+ {
+ final Random rand = new Random();
+ ((Colorable)spawned).setColor(DyeColor.values()[rand.nextInt(DyeColor.values().length)]);
+ }
+ else
+ {
+ ((Colorable)spawned).setColor(DyeColor.valueOf(color));
+ }
+ }
+ catch (Exception e)
+ {
+ throw new Exception(_("sheepMalformedColor"), e);
+ }
+ }
+ if (spawned instanceof Tameable && data.contains("tamed") && target != null)
+ {
+ final Tameable tameable = ((Tameable)spawned);
+ tameable.setTamed(true);
+ tameable.setOwner(target.getBase());
+ }
+ if (type == EntityType.WOLF
+ && data.contains("angry"))
+ {
+ ((Wolf)spawned).setAngry(true);
+ }
+ if (type == EntityType.CREEPER && data.contains("powered"))
+ {
+ ((Creeper)spawned).setPowered(true);
+ }
+ if (type == EntityType.OCELOT)
+ {
+ if (data.contains("siamese"))
+ {
+ ((Ocelot)spawned).setCatType(Ocelot.Type.SIAMESE_CAT);
+ }
+ else if (data.contains("red"))
+ {
+ ((Ocelot)spawned).setCatType(Ocelot.Type.RED_CAT);
+ }
+ else if (data.contains("black"))
+ {
+ ((Ocelot)spawned).setCatType(Ocelot.Type.BLACK_CAT);
+ }
+ }
+ if (type == EntityType.VILLAGER)
+ {
+ for (Villager.Profession prof : Villager.Profession.values())
+ {
+ if (data.contains(prof.toString().toLowerCase(Locale.ENGLISH)))
+ {
+ ((Villager)spawned).setProfession(prof);
+ }
+ }
+ }
+ }
+}
diff --git a/Essentials/src/com/earth2me/essentials/TNTExplodeListener.java b/Essentials/src/com/earth2me/essentials/TNTExplodeListener.java
index 4187f835d..79cdfa7b4 100644
--- a/Essentials/src/com/earth2me/essentials/TNTExplodeListener.java
+++ b/Essentials/src/com/earth2me/essentials/TNTExplodeListener.java
@@ -24,13 +24,13 @@ public class TNTExplodeListener implements Listener, Runnable
if (!enabled)
{
enabled = true;
- timer = ess.scheduleSyncDelayedTask(this, 1000);
+ timer = ess.scheduleSyncDelayedTask(this, 200);
return;
}
if (timer != -1)
{
ess.getScheduler().cancelTask(timer);
- timer = ess.scheduleSyncDelayedTask(this, 1000);
+ timer = ess.scheduleSyncDelayedTask(this, 200);
}
}
diff --git a/Essentials/src/com/earth2me/essentials/Teleport.java b/Essentials/src/com/earth2me/essentials/Teleport.java
index 6a666a199..241a8328d 100644
--- a/Essentials/src/com/earth2me/essentials/Teleport.java
+++ b/Essentials/src/com/earth2me/essentials/Teleport.java
@@ -2,10 +2,12 @@ package com.earth2me.essentials;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.api.ITeleport;
+import com.earth2me.essentials.commands.NoChargeException;
import java.util.Calendar;
import java.util.GregorianCalendar;
import java.util.logging.Logger;
import org.bukkit.Location;
+import org.bukkit.Material;
import org.bukkit.entity.Player;
import org.bukkit.event.player.PlayerRespawnEvent;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
@@ -47,7 +49,7 @@ public class Teleport implements Runnable, ITeleport
private IUser teleportUser;
private int teleTimer = -1;
private long started; // time this task was initiated
- private long delay; // how long to delay the teleport
+ private long tpdelay; // how long to delay the teleport
private int health;
// note that I initially stored a clone of the location for reference, but...
// when comparing locations, I got incorrect mismatches (rounding errors, looked like)
@@ -56,6 +58,7 @@ public class Teleport implements Runnable, ITeleport
private long initY;
private long initZ;
private Target teleportTarget;
+ private boolean respawn;
private Trade chargeFor;
private final IEssentials ess;
private static final Logger logger = Logger.getLogger("Minecraft");
@@ -63,13 +66,13 @@ public class Teleport implements Runnable, ITeleport
private void initTimer(long delay, Target target, Trade chargeFor, TeleportCause cause)
{
- initTimer(delay, user, target, chargeFor, cause);
+ initTimer(delay, user, target, chargeFor, cause, false);
}
- private void initTimer(long delay, IUser teleportUser, Target target, Trade chargeFor, TeleportCause cause)
+ private void initTimer(long delay, IUser teleportUser, Target target, Trade chargeFor, TeleportCause cause, boolean respawn)
{
this.started = System.currentTimeMillis();
- this.delay = delay;
+ this.tpdelay = delay;
this.health = teleportUser.getHealth();
this.initX = Math.round(teleportUser.getLocation().getX() * MOVE_CONSTANT);
this.initY = Math.round(teleportUser.getLocation().getY() * MOVE_CONSTANT);
@@ -78,6 +81,7 @@ public class Teleport implements Runnable, ITeleport
this.teleportTarget = target;
this.chargeFor = chargeFor;
this.cause = cause;
+ this.respawn = respawn;
}
@Override
@@ -107,7 +111,7 @@ public class Teleport implements Runnable, ITeleport
}
health = teleportUser.getHealth(); // in case user healed, then later gets injured
long now = System.currentTimeMillis();
- if (now > started + delay)
+ if (now > started + tpdelay)
{
try
{
@@ -115,8 +119,12 @@ public class Teleport implements Runnable, ITeleport
teleportUser.sendMessage(_("teleportationCommencing"));
try
{
-
- teleportUser.getTeleport().now(teleportTarget, cause);
+ if (respawn) {
+ teleportUser.getTeleport().respawn(cause);
+ }
+ else {
+ teleportUser.getTeleport().now(teleportTarget, cause);
+ }
cancel(false);
if (chargeFor != null)
{
@@ -241,7 +249,7 @@ public class Teleport implements Runnable, ITeleport
{
teleport(loc, chargeFor, TeleportCause.PLUGIN);
}
-
+
public void teleport(Location loc, Trade chargeFor, TeleportCause cause) throws Exception
{
teleport(new Target(loc), chargeFor, cause);
@@ -273,7 +281,7 @@ public class Teleport implements Runnable, ITeleport
}
cancel(false);
- warnUser(user);
+ warnUser(user, delay);
initTimer((long)(delay * 1000.0), target, chargeFor, cause);
teleTimer = ess.scheduleSyncRepeatingTask(this, 10, 10);
@@ -283,7 +291,6 @@ public class Teleport implements Runnable, ITeleport
public void teleportToMe(User otherUser, Trade chargeFor, TeleportCause cause) throws Exception
{
Target target = new Target(user);
-
double delay = ess.getSettings().getTeleportDelay();
if (chargeFor != null)
@@ -303,13 +310,12 @@ public class Teleport implements Runnable, ITeleport
}
cancel(false);
- warnUser(otherUser);
- initTimer((long)(delay * 1000.0), otherUser, target, chargeFor, cause);
-
+ warnUser(otherUser, delay);
+ initTimer((long)(delay * 1000.0), otherUser, target, chargeFor, cause, false);
teleTimer = ess.scheduleSyncRepeatingTask(this, 10, 10);
}
- private void warnUser(final IUser user)
+ private void warnUser(final IUser user, final double delay)
{
Calendar c = new GregorianCalendar();
c.add(Calendar.SECOND, (int)delay);
@@ -320,19 +326,50 @@ public class Teleport implements Runnable, ITeleport
//The respawn function is a wrapper used to handle tp fallback, on /jail and /home
public void respawn(final Trade chargeFor, TeleportCause cause) throws Exception
{
+ double delay = ess.getSettings().getTeleportDelay();
+ if (chargeFor != null)
+ {
+ chargeFor.isAffordableFor(user);
+ }
+ cooldown(true);
+ if (delay <= 0 || user.isAuthorized("essentials.teleport.timer.bypass"))
+ {
+ cooldown(false);
+ respawn(cause);
+ if (chargeFor != null)
+ {
+ chargeFor.charge(user);
+ }
+ return;
+ }
+
+ cancel(false);
+ initTimer((long)(delay * 1000.0), user, null, chargeFor, cause, true);
+ teleTimer = ess.scheduleSyncRepeatingTask(this, 10, 10);
+ }
+
+ public void respawn(TeleportCause cause) throws Exception
+ {
final Player player = user.getBase();
- final Location bed = player.getBedSpawnLocation();
- final PlayerRespawnEvent pre = new PlayerRespawnEvent(player, bed == null ? player.getWorld().getSpawnLocation() : bed, bed != null);
- ess.getServer().getPluginManager().callEvent(pre);
- teleport(new Target(pre.getRespawnLocation()), chargeFor, cause);
+ Location bed = player.getBedSpawnLocation();
+ if (bed != null && bed.getBlock().getType() != Material.BED_BLOCK)
+ {
+ now(new Target(bed), cause);
+ }
+ else
+ {
+ final PlayerRespawnEvent pre = new PlayerRespawnEvent(player, player.getWorld().getSpawnLocation(), false);
+ ess.getServer().getPluginManager().callEvent(pre);
+ now(new Target(pre.getRespawnLocation()), cause);
+ }
}
//The warp function is a wrapper used to teleport a player to a /warp
public void warp(String warp, Trade chargeFor, TeleportCause cause) throws Exception
{
Location loc = ess.getWarps().getWarp(warp);
- teleport(new Target(loc), chargeFor, cause);
user.sendMessage(_("warpingTo", warp));
+ teleport(new Target(loc), chargeFor, cause);
}
//The back function is a wrapper used to teleport a player /back to their previous location.
diff --git a/Essentials/src/com/earth2me/essentials/Trade.java b/Essentials/src/com/earth2me/essentials/Trade.java
index ff37a5d28..420525e63 100644
--- a/Essentials/src/com/earth2me/essentials/Trade.java
+++ b/Essentials/src/com/earth2me/essentials/Trade.java
@@ -234,6 +234,9 @@ public class Trade
public static void log(String type, String subtype, String event, String sender, Trade charge, String receiver, Trade pay, Location loc, IEssentials ess)
{
+ //isEcoLogUpdateEnabled() - This refers to log entries with no location, ie API updates #EasterEgg
+ //isEcoLogEnabled() - This refers to log entries with with location, ie /pay /sell and eco signs.
+
if ((loc == null && !ess.getSettings().isEcoLogUpdateEnabled())
|| (loc != null && !ess.getSettings().isEcoLogEnabled()))
{
diff --git a/Essentials/src/com/earth2me/essentials/User.java b/Essentials/src/com/earth2me/essentials/User.java
index 01284d4b8..5de4b7609 100644
--- a/Essentials/src/com/earth2me/essentials/User.java
+++ b/Essentials/src/com/earth2me/essentials/User.java
@@ -70,8 +70,8 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
}
return result;
}
-
- private boolean isAuthorizedCheck(final String node)
+
+ private boolean isAuthorizedCheck(final String node)
{
if (base instanceof OfflinePlayer)
@@ -306,6 +306,7 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
if (ess.getSettings().addPrefixSuffix())
{
+ //These two extra toggles are not documented, because they are mostly redundant #EasterEgg
if (!ess.getSettings().disablePrefix())
{
final String ptext = ess.getPermissionsHandler().getPrefix(base).replace('&', '§');
@@ -537,7 +538,11 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
if (broadcast && !isHidden())
{
setDisplayNick();
- ess.broadcastMessage(this, _("userIsNotAway", getDisplayName()));
+ final String msg = _("userIsNotAway", getDisplayName());
+ if (!msg.isEmpty())
+ {
+ ess.broadcastMessage(this, msg);
+ }
}
}
lastActivity = System.currentTimeMillis();
@@ -570,7 +575,11 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
if (!isHidden())
{
setDisplayNick();
- ess.broadcastMessage(this, _("userIsAway", getDisplayName()));
+ final String msg = _("userIsAway", getDisplayName());
+ if (!msg.isEmpty())
+ {
+ ess.broadcastMessage(this, msg);
+ }
}
}
}
@@ -728,4 +737,10 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
{
this.rightClickJump = rightClickJump;
}
+
+ @Override
+ public boolean isIgnoreExempt()
+ {
+ return this.isAuthorized("essentials.chat.ignoreexempt");
+ }
}
diff --git a/Essentials/src/com/earth2me/essentials/UserData.java b/Essentials/src/com/earth2me/essentials/UserData.java
index e9b84e656..94b1631f5 100644
--- a/Essentials/src/com/earth2me/essentials/UserData.java
+++ b/Essentials/src/com/earth2me/essentials/UserData.java
@@ -49,23 +49,23 @@ public abstract class UserData extends PlayerExtension implements IConf
lastHealTimestamp = _getLastHealTimestamp();
jail = _getJail();
mails = _getMails();
- teleportEnabled = getTeleportEnabled();
- ignoredPlayers = getIgnoredPlayers();
+ teleportEnabled = _getTeleportEnabled();
godmode = _getGodModeEnabled();
- muted = getMuted();
+ muted = _getMuted();
muteTimeout = _getMuteTimeout();
- jailed = getJailed();
+ jailed = _getJailed();
jailTimeout = _getJailTimeout();
lastLogin = _getLastLogin();
lastLogout = _getLastLogout();
lastLoginAddress = _getLastLoginAddress();
- afk = getAfk();
+ afk = _getAfk();
geolocation = _getGeoLocation();
isSocialSpyEnabled = _isSocialSpyEnabled();
isNPC = _isNPC();
arePowerToolsEnabled = _arePowerToolsEnabled();
kitTimestamps = _getKitTimestamps();
nickname = _getNickname();
+ setIgnoredPlayers(_getIgnoredPlayers());
}
private double money;
@@ -161,7 +161,7 @@ public abstract class UserData extends PlayerExtension implements IConf
public void setHome(String name, Location loc)
{
//Invalid names will corrupt the yaml
- name = Util.sanitizeFileName(name);
+ name = Util.safeString(name);
homes.put(name, loc);
config.setProperty("homes." + name, loc);
config.save();
@@ -172,7 +172,7 @@ public abstract class UserData extends PlayerExtension implements IConf
String search = getHomeName(name);
if (!homes.containsKey(search))
{
- search = Util.sanitizeFileName(search);
+ search = Util.safeString(search);
}
if (homes.containsKey(search))
{
@@ -415,7 +415,7 @@ public abstract class UserData extends PlayerExtension implements IConf
}
private boolean teleportEnabled;
- private boolean getTeleportEnabled()
+ private boolean _getTeleportEnabled()
{
return config.getBoolean("teleportenabled", true);
}
@@ -447,7 +447,7 @@ public abstract class UserData extends PlayerExtension implements IConf
}
private List<String> ignoredPlayers;
- public List<String> getIgnoredPlayers()
+ public List<String> _getIgnoredPlayers()
{
return Collections.synchronizedList(config.getStringList("ignore"));
}
@@ -480,7 +480,7 @@ public abstract class UserData extends PlayerExtension implements IConf
public boolean isIgnoredPlayer(IUser user)
{
- return (ignoredPlayers.contains(user.getName().toLowerCase(Locale.ENGLISH)) && !user.isAuthorized("essentials.chat.ignoreexempt"));
+ return (ignoredPlayers.contains(user.getName().toLowerCase(Locale.ENGLISH)) && !user.isIgnoreExempt());
}
public void setIgnoredPlayer(IUser user, boolean set)
@@ -515,10 +515,15 @@ public abstract class UserData extends PlayerExtension implements IConf
}
private boolean muted;
- public boolean getMuted()
+ public boolean _getMuted()
{
return config.getBoolean("muted", false);
}
+
+ public boolean getMuted()
+ {
+ return muted;
+ }
public boolean isMuted()
{
@@ -551,7 +556,7 @@ public abstract class UserData extends PlayerExtension implements IConf
}
private boolean jailed;
- private boolean getJailed()
+ private boolean _getJailed()
{
return config.getBoolean("jailed", false);
}
@@ -635,7 +640,10 @@ public abstract class UserData extends PlayerExtension implements IConf
public void setLastLogin(long time)
{
_setLastLogin(time);
- _setLastLoginAddress(base.getAddress().getAddress().getHostAddress());
+ if (base.getAddress() != null && base.getAddress().getAddress() != null)
+ {
+ _setLastLoginAddress(base.getAddress().getAddress().getHostAddress());
+ }
config.save();
}
private long lastLogout;
@@ -675,7 +683,7 @@ public abstract class UserData extends PlayerExtension implements IConf
}
private boolean afk;
- private boolean getAfk()
+ private boolean _getAfk()
{
return config.getBoolean("afk", false);
}
diff --git a/Essentials/src/com/earth2me/essentials/Util.java b/Essentials/src/com/earth2me/essentials/Util.java
index 34e5c6420..12f5c9da6 100644
--- a/Essentials/src/com/earth2me/essentials/Util.java
+++ b/Essentials/src/com/earth2me/essentials/Util.java
@@ -23,16 +23,20 @@ public class Util
private final static Logger logger = Logger.getLogger("Minecraft");
private final static Pattern INVALIDFILECHARS = Pattern.compile("[^a-z0-9]");
private final static Pattern INVALIDCHARS = Pattern.compile("[^\t\n\r\u0020-\u007E\u0085\u00A0-\uD7FF\uE000-\uFFFC]");
- private final static Pattern BADFILENAMES = Pattern.compile("^(CON|PRN|AUX|NUL|COM[1-9]|LPT[1-9])(\\.(.+))?$", Pattern.CASE_INSENSITIVE | Pattern.UNICODE_CASE | Pattern.COMMENTS);
+ //Used to clean file names before saving to disk
public static String sanitizeFileName(final String name)
{
- String newName = INVALIDFILECHARS.matcher(name.toLowerCase(Locale.ENGLISH)).replaceAll("_");
- if(BADFILENAMES.matcher(newName).matches())
- newName = "_" + newName;
- return newName;
+ return safeString(name);
}
+ //Used to clean strings/names before saving as filenames/permissions
+ public static String safeString(final String string)
+ {
+ return INVALIDFILECHARS.matcher(string.toLowerCase(Locale.ENGLISH)).replaceAll("_");
+ }
+
+ //Less restrictive string sanitizing, when not used as perm or filename
public static String sanitizeString(final String string)
{
return INVALIDCHARS.matcher(string).replaceAll("");
@@ -601,6 +605,7 @@ public class Util
}
private static transient final Pattern URL_PATTERN = Pattern.compile("((?:(?:https?)://)?[\\w-_\\.]{2,})\\.([a-z]{2,3}(?:/\\S+)?)");
private static transient final Pattern VANILLA_PATTERN = Pattern.compile("\u00A7+[0-9A-FK-ORa-fk-or]");
+ private static transient final Pattern LOGCOLOR_PATTERN = Pattern.compile("\\x1B\\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]");
private static transient final Pattern REPLACE_PATTERN = Pattern.compile("&([0-9a-fk-or])");
private static transient final Pattern VANILLA_COLOR_PATTERN = Pattern.compile("\u00A7+[0-9A-Fa-f]");
private static transient final Pattern VANILLA_MAGIC_PATTERN = Pattern.compile("\u00A7+[Kk]");
@@ -618,6 +623,15 @@ public class Util
return VANILLA_PATTERN.matcher(input).replaceAll("");
}
+ public static String stripLogColorFormat(final String input)
+ {
+ if (input == null)
+ {
+ return null;
+ }
+ return LOGCOLOR_PATTERN.matcher(input).replaceAll("");
+ }
+
public static String replaceFormat(final String input)
{
if (input == null)
diff --git a/Essentials/src/com/earth2me/essentials/Warps.java b/Essentials/src/com/earth2me/essentials/Warps.java
index ece987aba..6c3448f4e 100644
--- a/Essentials/src/com/earth2me/essentials/Warps.java
+++ b/Essentials/src/com/earth2me/essentials/Warps.java
@@ -3,6 +3,7 @@ package com.earth2me.essentials;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.commands.WarpNotFoundException;
import java.io.File;
+import java.io.IOException;
import java.util.*;
import java.util.logging.Level;
import java.util.logging.Logger;
@@ -70,7 +71,14 @@ public class Warps implements IConf
}
conf.setProperty(null, loc);
conf.setProperty("name", name);
- conf.save();
+ try
+ {
+ conf.saveWithError();
+ }
+ catch (IOException ex)
+ {
+ throw new IOException(_("invalidWarpName"));
+ }
}
public void delWarp(String name) throws Exception
diff --git a/Essentials/src/com/earth2me/essentials/api/Economy.java b/Essentials/src/com/earth2me/essentials/api/Economy.java
index 6ed1829b3..579afd4d1 100644
--- a/Essentials/src/com/earth2me/essentials/api/Economy.java
+++ b/Essentials/src/com/earth2me/essentials/api/Economy.java
@@ -8,7 +8,6 @@ import com.earth2me.essentials.Util;
import java.io.File;
import java.util.logging.Level;
import java.util.logging.Logger;
-import org.bukkit.entity.Player;
/**
@@ -72,17 +71,7 @@ public final class Economy
{
throw new RuntimeException(noCallBeforeLoad);
}
- User user;
- Player player = ess.getServer().getPlayer(name);
- if (player != null)
- {
- user = ess.getUser(player);
- }
- else
- {
- user = ess.getOfflineUser(name);
- }
- return user;
+ return ess.getUser(name);
}
/**
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandafk.java b/Essentials/src/com/earth2me/essentials/commands/Commandafk.java
index c71883571..6a5d6dc26 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandafk.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandafk.java
@@ -32,12 +32,13 @@ public class Commandafk extends EssentialsCommand
private void toggleAfk(User user)
{
user.setDisplayNick();
+ String msg = "";
if (!user.toggleAfk())
{
//user.sendMessage(_("markedAsNotAway"));
if (!user.isHidden())
{
- ess.broadcastMessage(user, _("userIsNotAway", user.getDisplayName()));
+ msg = _("userIsNotAway", user.getDisplayName());
}
user.updateActivity(false);
}
@@ -46,8 +47,12 @@ public class Commandafk extends EssentialsCommand
//user.sendMessage(_("markedAsAway"));
if (!user.isHidden())
{
- ess.broadcastMessage(user, _("userIsAway", user.getDisplayName()));
+ msg = _("userIsAway", user.getDisplayName());
}
}
+ if (!msg.isEmpty())
+ {
+ ess.broadcastMessage(user, msg);
+ }
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java b/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
index 968d0012c..79ef1f969 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
@@ -6,7 +6,7 @@ import org.bukkit.Location;
import org.bukkit.Server;
import org.bukkit.entity.TNTPrimed;
-
+// This command has a in theme message that only shows if you supply a parameter #EasterEgg
public class Commandantioch extends EssentialsCommand
{
public Commandantioch()
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandbalance.java b/Essentials/src/com/earth2me/essentials/commands/Commandbalance.java
index 15c3c9088..e4aebd197 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandbalance.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandbalance.java
@@ -27,6 +27,7 @@ public class Commandbalance extends EssentialsCommand
@Override
public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
+ //TODO: Remove 'other' perm
final double bal = (args.length < 1
|| !(user.isAuthorized("essentials.balance.others")
|| user.isAuthorized("essentials.balance.other"))
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandban.java b/Essentials/src/com/earth2me/essentials/commands/Commandban.java
index cf6ea53df..3c31469e3 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandban.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandban.java
@@ -20,6 +20,7 @@ public class Commandban extends EssentialsCommand
@Override
public void run(final Server server, final CommandSender sender, final String commandLabel, final String[] args) throws Exception
{
+ boolean nomatch = false;
if (args.length < 1)
{
throw new NotEnoughArgumentsException();
@@ -31,6 +32,7 @@ public class Commandban extends EssentialsCommand
}
catch (NoSuchFieldException e)
{
+ nomatch = true;
user = ess.getUser(new OfflinePlayer(args[0], ess));
}
if (!user.isOnline())
@@ -65,13 +67,17 @@ public class Commandban extends EssentialsCommand
user.setBanReason(banReason);
user.setBanned(true);
user.kickPlayer(banReason);
-
+
server.getLogger().log(Level.INFO, _("playerBanned", senderName, user.getName(), banReason));
+
+ if (nomatch) {
+ sender.sendMessage(_("userUnknown", user.getName()));
+ }
for (Player onlinePlayer : server.getOnlinePlayers())
{
final User player = ess.getUser(onlinePlayer);
- if (player.isAuthorized("essentials.ban.notify"))
+ if (onlinePlayer == sender || player.isAuthorized("essentials.ban.notify"))
{
onlinePlayer.sendMessage(_("playerBanned", senderName, user.getName(), banReason));
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandessentials.java b/Essentials/src/com/earth2me/essentials/commands/Commandessentials.java
index fe33aebd7..8598a31e9 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandessentials.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandessentials.java
@@ -14,7 +14,7 @@ import org.bukkit.command.CommandSender;
import org.bukkit.command.ConsoleCommandSender;
import org.bukkit.entity.Player;
-
+// This command has 4 undocumented behaviours #EasterEgg
public class Commandessentials extends EssentialsCommand
{
public Commandessentials()
@@ -55,6 +55,7 @@ public class Commandessentials extends EssentialsCommand
}
}
+ //If you do not supply an argument this command will list 'overridden' commands.
private void run_disabled(final Server server, final CommandSender sender, final String commandLabel, final String[] args) throws Exception
{
sender.sendMessage("Essentials " + ess.getDescription().getVersion());
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandexp.java b/Essentials/src/com/earth2me/essentials/commands/Commandexp.java
index f3dac79e2..5d3658470 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandexp.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandexp.java
@@ -125,13 +125,13 @@ public class Commandexp extends EssentialsCommand
sender.sendMessage(_("exp", target.getDisplayName(), SetExpFix.getTotalExperience(target), target.getLevel(), SetExpFix.getExpUntilNextLevel(target)));
}
- private void setExp(final CommandSender sender, final User target, String strAmount, final boolean give)
+ private void setExp(final CommandSender sender, final User target, String strAmount, final boolean give) throws NotEnoughArgumentsException
{
Long amount;
strAmount = strAmount.toLowerCase(Locale.ENGLISH);
- if (strAmount.startsWith("l"))
+ if (strAmount.startsWith("l") || strAmount.endsWith("l"))
{
- strAmount = strAmount.substring(1);
+ strAmount = strAmount.replaceAll("l","");
int neededLevel = Integer.parseInt(strAmount);
if (give)
{
@@ -142,6 +142,10 @@ public class Commandexp extends EssentialsCommand
}
else {
amount = Long.parseLong(strAmount);
+ if (amount < 0 || amount > Integer.MAX_VALUE)
+ {
+ throw new NotEnoughArgumentsException();
+ }
}
if (give)
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandfly.java b/Essentials/src/com/earth2me/essentials/commands/Commandfly.java
index 86347d3e9..a299770b1 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandfly.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandfly.java
@@ -28,15 +28,34 @@ public class Commandfly extends EssentialsCommand
@Override
protected void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
- if (args.length > 0 && args[0].trim().length() > 2 && user.isAuthorized("essentials.fly.others"))
+ if (args.length == 1)
+ {
+ if (args[0].equalsIgnoreCase("on") || args[0].startsWith("ena") || args[0].equalsIgnoreCase("1"))
+ {
+ user.setAllowFlight(true);
+ }
+ else if (args[0].equalsIgnoreCase("off") || args[0].startsWith("dis") || args[0].equalsIgnoreCase("0"))
+ {
+ user.setAllowFlight(false);
+ }
+ else if (user.isAuthorized("essentials.fly.others"))
+ {
+ flyOtherPlayers(server, user, args);
+ return;
+ }
+ }
+ else if (args.length == 2 && user.isAuthorized("essentials.fly.others"))
{
flyOtherPlayers(server, user, args);
return;
}
- user.setAllowFlight(!user.getAllowFlight());
- if (!user.getAllowFlight())
+ else
{
- user.setFlying(false);
+ user.setAllowFlight(!user.getAllowFlight());
+ if (!user.getAllowFlight())
+ {
+ user.setFlying(false);
+ }
}
user.sendMessage(_("flyMode", _(user.getAllowFlight() ? "enabled" : "disabled"), user.getDisplayName()));
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java
index 85aeaa673..5b9b854cb 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java
@@ -19,12 +19,22 @@ public class Commandgamemode extends EssentialsCommand
@Override
protected void run(final Server server, final CommandSender sender, final String commandLabel, final String[] args) throws Exception
{
- if (args.length < 2)
+ GameMode gameMode;
+ if (args.length == 0)
{
throw new NotEnoughArgumentsException();
}
- GameMode gameMode = matchGameMode(args[0].toLowerCase(Locale.ENGLISH));
- gamemodeOtherPlayers(server, sender, gameMode, args[1]);
+ else if (args.length == 1)
+ {
+ gameMode = matchGameMode(commandLabel);
+ gamemodeOtherPlayers(server, sender, gameMode, args[0]);
+ }
+ else if (args.length == 2)
+ {
+ gameMode = matchGameMode(args[0].toLowerCase(Locale.ENGLISH));
+ gamemodeOtherPlayers(server, sender, gameMode, args[1]);
+ }
+
}
@Override
@@ -43,16 +53,23 @@ public class Commandgamemode extends EssentialsCommand
}
else
{
- try {
+ try
+ {
gameMode = matchGameMode(args[0].toLowerCase(Locale.ENGLISH));
}
- catch (NotEnoughArgumentsException e) {
- gameMode = matchGameMode(commandLabel);
- gamemodeOtherPlayers(server, user, gameMode, args[0]);
- return;
+ catch (NotEnoughArgumentsException e)
+ {
+ if (user.isAuthorized("essentials.gamemode.others"))
+ {
+ gameMode = matchGameMode(commandLabel);
+ gamemodeOtherPlayers(server, user, gameMode, args[0]);
+ return;
+ }
+ throw new NotEnoughArgumentsException();
}
}
- if (gameMode == null) {
+ if (gameMode == null)
+ {
gameMode = user.getGameMode() == GameMode.SURVIVAL ? GameMode.CREATIVE : user.getGameMode() == GameMode.CREATIVE ? GameMode.ADVENTURE : GameMode.SURVIVAL;
}
user.setGameMode(gameMode);
@@ -104,11 +121,12 @@ public class Commandgamemode extends EssentialsCommand
mode = GameMode.ADVENTURE;
}
else if (modeString.equalsIgnoreCase("gmt") || modeString.equalsIgnoreCase("egmt")
- || modeString.contains("toggle") || modeString.contains("cycle") || modeString.equalsIgnoreCase("t"))
+ || modeString.contains("toggle") || modeString.contains("cycle") || modeString.equalsIgnoreCase("t"))
{
mode = null;
}
- else {
+ else
+ {
throw new NotEnoughArgumentsException();
}
return mode;
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java
index 546bfc85d..293dbfb6d 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java
@@ -23,7 +23,6 @@ public class Commandhome extends EssentialsCommand
public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
final Trade charge = new Trade(this.getName(), ess);
- charge.isAffordableFor(user);
User player = user;
String homeName = "";
String[] nameParts;
@@ -45,7 +44,7 @@ public class Commandhome extends EssentialsCommand
}
try
{
- if ("bed".equalsIgnoreCase(homeName))
+ if ("bed".equalsIgnoreCase(homeName) && user.isAuthorized("essentials.home.bed"))
{
final Location bed = player.getBedSpawnLocation();
if (bed != null && bed.getBlock().getType() == Material.BED_BLOCK)
@@ -66,13 +65,7 @@ public class Commandhome extends EssentialsCommand
final List<String> homes = player.getHomes();
if (homes.isEmpty() && player.equals(user))
{
- if (bed != null)
- {
- user.getTeleport().teleport(bed, charge, TeleportCause.COMMAND);
- throw new NoChargeException();
- }
user.getTeleport().respawn(charge, TeleportCause.COMMAND);
-
}
else if (homes.isEmpty())
{
@@ -84,7 +77,7 @@ public class Commandhome extends EssentialsCommand
}
else
{
- if (bed != null)
+ if (bed != null && user.isAuthorized("essentials.home.bed"))
{
homes.add("bed");
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandjump.java b/Essentials/src/com/earth2me/essentials/commands/Commandjump.java
index ba7182628..073c20dce 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandjump.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandjump.java
@@ -8,7 +8,7 @@ import org.bukkit.Location;
import org.bukkit.Server;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
-
+// This method contains an undocumented sub command #EasterEgg
public class Commandjump extends EssentialsCommand
{
public Commandjump()
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandkick.java b/Essentials/src/com/earth2me/essentials/commands/Commandkick.java
index 287a3cc62..c05c66ad0 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandkick.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandkick.java
@@ -24,23 +24,29 @@ public class Commandkick extends EssentialsCommand
throw new NotEnoughArgumentsException();
}
- final User user = getPlayer(server, args, 0);
- if (sender instanceof Player && user.isAuthorized("essentials.kick.exempt"))
- {
- throw new Exception(_("kickExempt"));
+ final User target = getPlayer(server, args, 0, true);
+ if (sender instanceof Player) {
+ User user = ess.getUser(sender);
+ if (target.isHidden() && !user.isAuthorized("essentials.list.hidden")) {
+ throw new PlayerNotFoundException();
+ }
+ if (target.isAuthorized("essentials.kick.exempt"))
+ {
+ throw new Exception(_("kickExempt"));
+ }
}
final String kickReason = args.length > 1 ? getFinalArg(args, 1) : _("kickDefault");
- user.kickPlayer(kickReason);
+ target.kickPlayer(kickReason);
final String senderName = sender instanceof Player ? ((Player)sender).getDisplayName() : Console.NAME;
- server.getLogger().log(Level.INFO, _("playerKicked", senderName, user.getName(), kickReason));
+ server.getLogger().log(Level.INFO, _("playerKicked", senderName, target.getName(), kickReason));
for (Player onlinePlayer : server.getOnlinePlayers())
{
User player = ess.getUser(onlinePlayer);
if (player.isAuthorized("essentials.kick.notify"))
{
- onlinePlayer.sendMessage(_("playerKicked", senderName, user.getName(), kickReason));
+ onlinePlayer.sendMessage(_("playerKicked", senderName, target.getName(), kickReason));
}
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandkill.java b/Essentials/src/com/earth2me/essentials/commands/Commandkill.java
index a2e58227b..a83b0d490 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandkill.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandkill.java
@@ -21,7 +21,7 @@ public class Commandkill extends EssentialsCommand
{
throw new NotEnoughArgumentsException();
}
-
+
//TODO: TL this
if (args[0].trim().length() < 2)
{
@@ -32,12 +32,18 @@ public class Commandkill extends EssentialsCommand
{
final EntityDamageEvent ede = new EntityDamageEvent(matchPlayer, sender instanceof Player && ((Player)sender).getName().equals(matchPlayer.getName()) ? EntityDamageEvent.DamageCause.SUICIDE : EntityDamageEvent.DamageCause.CUSTOM, Short.MAX_VALUE);
server.getPluginManager().callEvent(ede);
- if (ede.isCancelled() && !sender.hasPermission("essentials.kill.force"))
+ if (ede.isCancelled() && sender instanceof Player && !ess.getUser(sender).isAuthorized("essentials.kill.force"))
{
continue;
}
matchPlayer.damage(Short.MAX_VALUE);
+
+ if (matchPlayer.getHealth() > 0)
+ {
+ matchPlayer.setHealth(0);
+ }
+
sender.sendMessage(_("kill", matchPlayer.getDisplayName()));
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandkittycannon.java b/Essentials/src/com/earth2me/essentials/commands/Commandkittycannon.java
index 9db608235..a94f09cdb 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandkittycannon.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandkittycannon.java
@@ -7,7 +7,7 @@ import org.bukkit.Location;
import org.bukkit.Server;
import org.bukkit.entity.Ocelot;
-
+// This command is not documented on the wiki #EasterEgg
public class Commandkittycannon extends EssentialsCommand
{
private static Random random = new Random();
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandmail.java b/Essentials/src/com/earth2me/essentials/commands/Commandmail.java
index 60306c272..049673036 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandmail.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandmail.java
@@ -6,11 +6,13 @@ import com.earth2me.essentials.Util;
import java.util.List;
import org.bukkit.Server;
import org.bukkit.command.CommandSender;
-import org.bukkit.entity.Player;
public class Commandmail extends EssentialsCommand
{
+ private static int mailsPerMinute = 0;
+ private static long timestamp = 0;
+
public Commandmail()
{
super("mail");
@@ -42,24 +44,29 @@ public class Commandmail extends EssentialsCommand
throw new Exception(_("noPerm", "essentials.mail.send"));
}
- Player player = server.getPlayer(args[1]);
- User u;
- if (player != null)
- {
- u = ess.getUser(player);
- }
- else
- {
- u = ess.getOfflineUser(args[1]);
- }
+ User u = ess.getUser(args[1]);
if (u == null)
{
throw new Exception(_("playerNeverOnServer", args[1]));
}
if (!u.isIgnoredPlayer(user))
{
- final String mail = Util.sanitizeString(Util.stripFormat(getFinalArg(args, 2)));
- u.addMail(user.getName() + ": " + mail);
+ final String mail = user.getName() + ": " + Util.sanitizeString(Util.stripFormat(getFinalArg(args, 2)));
+ if (mail.length() > 1000)
+ {
+ throw new Exception("Mail message too long. Try to keep it below 1000");
+ }
+ if (Math.abs(System.currentTimeMillis() - timestamp) > 60000)
+ {
+ timestamp = System.currentTimeMillis();
+ mailsPerMinute = 0;
+ }
+ mailsPerMinute++;
+ if (mailsPerMinute > ess.getSettings().getMailsPerMinute())
+ {
+ throw new Exception("Too many mails have been send within the last minute. Maximum: " + ess.getSettings().getMailsPerMinute());
+ }
+ u.addMail(mail);
}
user.sendMessage(_("mailSent"));
return;
@@ -96,16 +103,7 @@ public class Commandmail extends EssentialsCommand
}
else if (args.length >= 3 && "send".equalsIgnoreCase(args[0]))
{
- Player player = server.getPlayer(args[1]);
- User u;
- if (player != null)
- {
- u = ess.getUser(player);
- }
- else
- {
- u = ess.getOfflineUser(args[1]);
- }
+ User u = ess.getUser(args[1]);
if (u == null)
{
throw new Exception(_("playerNeverOnServer", args[1]));
@@ -121,16 +119,7 @@ public class Commandmail extends EssentialsCommand
else if (args.length >= 2)
{
//allow sending from console without "send" argument, since it's the only thing the console can do
- Player player = server.getPlayer(args[0]);
- User u;
- if (player != null)
- {
- u = ess.getUser(player);
- }
- else
- {
- u = ess.getOfflineUser(args[0]);
- }
+ User u = ess.getUser(args[0]);
if (u == null)
{
throw new Exception(_("playerNeverOnServer", args[0]));
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandmore.java b/Essentials/src/com/earth2me/essentials/commands/Commandmore.java
index 3fce3110c..e50e21e45 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandmore.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandmore.java
@@ -25,7 +25,7 @@ public class Commandmore extends EssentialsCommand
if (stack.getAmount() >= ((user.isAuthorized("essentials.oversizedstacks"))
? ess.getSettings().getOversizedStackSize() : stack.getMaxStackSize()))
{
- throw new NoChargeException();
+ throw new Exception(_("fullStack"));
}
final String itemname = stack.getType().toString().toLowerCase(Locale.ENGLISH).replace("_", "");
if (ess.getSettings().permissionBasedItemSpawn()
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandping.java b/Essentials/src/com/earth2me/essentials/commands/Commandping.java
index 43aa18d5f..0b1df5bf5 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandping.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandping.java
@@ -5,7 +5,7 @@ import com.earth2me.essentials.Util;
import org.bukkit.Server;
import org.bukkit.command.CommandSender;
-
+// This command can be used to echo messages to the users screen, mostly useless but also an #EasterEgg
public class Commandping extends EssentialsCommand
{
public Commandping()
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandsell.java b/Essentials/src/com/earth2me/essentials/commands/Commandsell.java
index 566d1b42e..904990e39 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandsell.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandsell.java
@@ -22,6 +22,8 @@ public class Commandsell extends EssentialsCommand
@Override
public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
+ double totalWorth = 0.0;
+ String type = "";
if (args.length < 1)
{
throw new NotEnoughArgumentsException();
@@ -41,12 +43,16 @@ public class Commandsell extends EssentialsCommand
}
try
{
- sellItem(user, stack, args, true);
+ totalWorth += sellItem(user, stack, args, true);
}
catch (Exception e)
{
}
}
+ if (totalWorth > 0)
+ {
+ user.sendMessage(_("totalWorthAll", type, Util.displayCurrency(totalWorth, ess)));
+ }
return;
}
else if (args[0].equalsIgnoreCase("blocks"))
@@ -59,12 +65,16 @@ public class Commandsell extends EssentialsCommand
}
try
{
- sellItem(user, stack, args, true);
+ totalWorth += sellItem(user, stack, args, true);
}
catch (Exception e)
{
}
}
+ if (totalWorth > 0)
+ {
+ user.sendMessage(_("totalWorthBlocks", type, Util.displayCurrency(totalWorth, ess)));
+ }
return;
}
if (is == null)
@@ -74,7 +84,7 @@ public class Commandsell extends EssentialsCommand
sellItem(user, is, args, false);
}
- private void sellItem(User user, ItemStack is, String[] args, boolean isBulkSell) throws Exception
+ private double sellItem(User user, ItemStack is, String[] args, boolean isBulkSell) throws Exception
{
if (is == null || is.getType() == Material.AIR)
{
@@ -149,7 +159,7 @@ public class Commandsell extends EssentialsCommand
}
else
{
- return;
+ return worth * amount;
}
}
@@ -162,6 +172,6 @@ public class Commandsell extends EssentialsCommand
user.giveMoney(worth * amount);
user.sendMessage(_("itemSold", Util.displayCurrency(worth * amount, ess), amount, is.getType().toString().toLowerCase(Locale.ENGLISH), Util.displayCurrency(worth, ess)));
logger.log(Level.INFO, _("itemSoldConsole", user.getDisplayName(), is.getType().toString().toLowerCase(Locale.ENGLISH), Util.displayCurrency(worth * amount, ess), amount, Util.displayCurrency(worth, ess)));
-
+ return worth * amount;
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandsethome.java b/Essentials/src/com/earth2me/essentials/commands/Commandsethome.java
index c97761f8d..1e27e7e3b 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandsethome.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandsethome.java
@@ -4,7 +4,6 @@ import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.User;
import com.earth2me.essentials.Util;
import java.util.Locale;
-import java.util.regex.Pattern;
import org.bukkit.Location;
import org.bukkit.Server;
@@ -40,14 +39,10 @@ public class Commandsethome extends EssentialsCommand
{
if (user.isAuthorized("essentials.sethome.others"))
{
- usersHome = ess.getUser(ess.getServer().getPlayer(args[0]));
+ usersHome = ess.getUser(args[0]);
if (usersHome == null)
{
- usersHome = ess.getOfflineUser(args[0]);
- }
- if (usersHome == null)
- {
- throw new Exception(_("playerNotFound"));
+ throw new NoSuchFieldException(_("playerNotFound"));
}
name = args[1].toLowerCase(Locale.ENGLISH);
}
@@ -59,8 +54,7 @@ public class Commandsethome extends EssentialsCommand
}
if ("bed".equals(name) || Util.isInt(name))
{
- user.sendMessage(_("invalidHomeName"));
- throw new NoChargeException();
+ throw new NoSuchFieldException(_("invalidHomeName"));
}
usersHome.setHome(name, location);
user.sendMessage(_("homeSet", user.getLocation().getWorld().getName(), user.getLocation().getBlockX(), user.getLocation().getBlockY(), user.getLocation().getBlockZ()));
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandsetwarp.java b/Essentials/src/com/earth2me/essentials/commands/Commandsetwarp.java
index 42da62b85..2469f6ec1 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandsetwarp.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandsetwarp.java
@@ -22,9 +22,10 @@ public class Commandsetwarp extends EssentialsCommand
{
throw new NotEnoughArgumentsException();
}
-
- if (args[0].matches("[0-9]+")) {
- throw new NotEnoughArgumentsException();
+
+ if (Util.isInt(args[0]))
+ {
+ throw new NoSuchFieldException(_("invalidWarpName"));
}
final Location loc = user.getLocation();
@@ -39,7 +40,7 @@ public class Commandsetwarp extends EssentialsCommand
{
}
- if (warpLoc == null || user.isAuthorized("essentials.warp.overwrite." + Util.sanitizeFileName(args[0])))
+ if (warpLoc == null || user.isAuthorized("essentials.warp.overwrite." + Util.safeString(args[0])))
{
warps.setWarp(args[0], loc);
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandspawnmob.java b/Essentials/src/com/earth2me/essentials/commands/Commandspawnmob.java
index 489a4ba91..5c43898a8 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandspawnmob.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandspawnmob.java
@@ -2,20 +2,11 @@ package com.earth2me.essentials.commands;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.Mob;
-import com.earth2me.essentials.Mob.MobException;
+import com.earth2me.essentials.SpawnMob;
import com.earth2me.essentials.User;
import com.earth2me.essentials.Util;
-import java.util.HashSet;
-import java.util.Locale;
-import java.util.Random;
-import java.util.Set;
-import org.bukkit.DyeColor;
-import org.bukkit.Location;
import org.bukkit.Server;
-import org.bukkit.block.Block;
-import org.bukkit.entity.Villager.Profession;
-import org.bukkit.entity.*;
-import org.bukkit.material.Colorable;
+import org.bukkit.command.CommandSender;
public class Commandspawnmob extends EssentialsCommand
@@ -30,256 +21,41 @@ public class Commandspawnmob extends EssentialsCommand
{
if (args.length < 1)
{
- final Set<String> mobList = Mob.getMobList();
- final Set<String> availableList = new HashSet<String>();
- for (String mob : mobList)
- {
- if (user.isAuthorized("essentials.spawnmob." + mob.toLowerCase()))
- {
- availableList.add(mob);
- }
- }
- if (availableList.isEmpty())
- {
- availableList.add(_("none"));
- }
- throw new NotEnoughArgumentsException(_("mobsAvailable", Util.joinList(availableList)));
+ final String mobList = SpawnMob.mobList(user);
+ throw new NotEnoughArgumentsException(_("mobsAvailable", mobList));
}
+ String[] mobData = SpawnMob.mobData(args[0]);
- final String[] mountparts = args[0].split(",");
- String[] parts = mountparts[0].split(":");
- String mobType = parts[0];
- String mobData = null;
- if (parts.length == 2)
- {
- mobData = parts[1];
- }
- String mountType = null;
- String mountData = null;
- if (mountparts.length > 1)
- {
- parts = mountparts[1].split(":");
- mountType = parts[0];
- if (parts.length == 2)
- {
- mountData = parts[1];
- }
- }
-
-
- Entity spawnedMob = null;
- Mob mob = null;
- Entity spawnedMount = null;
- Mob mobMount = null;
-
- mob = Mob.fromName(mobType);
- if (mob == null)
- {
- throw new Exception(_("invalidMob"));
- }
-
- if (ess.getSettings().getProtectPreventSpawn(mob.getType().toString().toLowerCase(Locale.ENGLISH)))
- {
- throw new Exception(_("disabledToSpawnMob"));
- }
- if (!user.isAuthorized("essentials.spawnmob." + mob.name.toLowerCase()))
+ int mobCount = 1;
+ if (args.length >= 2)
{
- throw new Exception(_("noPermToSpawnMob"));
+ mobCount = Integer.parseInt(args[1]);
}
- final Block block = Util.getTarget(user).getBlock();
- if (block == null)
- {
- throw new Exception(_("unableToSpawnMob"));
- }
- User otherUser = null;
if (args.length >= 3)
{
- otherUser = getPlayer(ess.getServer(), args, 2);
- }
- final Location loc = (otherUser == null) ? block.getLocation() : otherUser.getLocation();
- final Location sloc = Util.getSafeDestination(loc);
- try
- {
- spawnedMob = mob.spawn(user, server, sloc);
- }
- catch (MobException e)
- {
- throw new Exception(_("unableToSpawnMob"), e);
- }
-
- if (mountType != null)
- {
- mobMount = Mob.fromName(mountType);
- if (mobMount == null)
- {
- user.sendMessage(_("invalidMob"));
- return;
- }
-
- if (ess.getSettings().getProtectPreventSpawn(mobMount.getType().toString().toLowerCase(Locale.ENGLISH)))
- {
- throw new Exception(_("disabledToSpawnMob"));
- }
- if (!user.isAuthorized("essentials.spawnmob." + mobMount.name.toLowerCase()))
- {
- throw new Exception(_("noPermToSpawnMob"));
- }
- try
- {
- spawnedMount = mobMount.spawn(user, server, loc);
- }
- catch (MobException e)
- {
- throw new Exception(_("unableToSpawnMob"), e);
- }
- spawnedMob.setPassenger(spawnedMount);
- }
- if (mobData != null)
- {
- changeMobData(mob.getType(), spawnedMob, mobData, user);
- }
- if (spawnedMount != null && mountData != null)
- {
- changeMobData(mobMount.getType(), spawnedMount, mountData, user);
+ final User target = getPlayer(ess.getServer(), args, 2);
+ SpawnMob.spawnmob(ess, server, user, target, mobData, mobCount);
+ return;
}
- if (args.length >= 2)
- {
- int mobCount = Integer.parseInt(args[1]);
- int serverLimit = ess.getSettings().getSpawnMobLimit();
- if (mobCount > serverLimit)
- {
- mobCount = serverLimit;
- user.sendMessage(_("mobSpawnLimit"));
- }
- try
- {
- for (int i = 1; i < mobCount; i++)
- {
- spawnedMob = mob.spawn(user, server, loc);
- if (mobMount != null)
- {
- try
- {
- spawnedMount = mobMount.spawn(user, server, loc);
- }
- catch (MobException e)
- {
- throw new Exception(_("unableToSpawnMob"), e);
- }
- spawnedMob.setPassenger(spawnedMount);
- }
- if (mobData != null)
- {
- changeMobData(mob.getType(), spawnedMob, mobData, user);
- }
- if (spawnedMount != null && mountData != null)
- {
- changeMobData(mobMount.getType(), spawnedMount, mountData, user);
- }
- }
- user.sendMessage(mobCount + " " + mob.name.toLowerCase(Locale.ENGLISH) + mob.suffix + " " + _("spawned"));
- }
- catch (MobException e1)
- {
- throw new Exception(_("unableToSpawnMob"), e1);
- }
- catch (NumberFormatException e2)
- {
- throw new Exception(_("numberRequired"), e2);
- }
- catch (NullPointerException np)
- {
- throw new Exception(_("soloMob"), np);
- }
- }
- else
- {
- user.sendMessage(mob.name + " " + _("spawned"));
- }
+ SpawnMob.spawnmob(ess, server, user, mobData, mobCount);
}
- private void changeMobData(final EntityType type, final Entity spawned, String data, final User user) throws Exception
+ @Override
+ public void run(final Server server, final CommandSender sender, final String commandLabel, final String[] args) throws Exception
{
- data = data.toLowerCase(Locale.ENGLISH);
-
- if (spawned instanceof Slime)
- {
- try
- {
- ((Slime)spawned).setSize(Integer.parseInt(data));
- }
- catch (Exception e)
- {
- throw new Exception(_("slimeMalformedSize"), e);
- }
- }
- if (spawned instanceof Ageable && data.contains("baby"))
- {
- ((Ageable)spawned).setBaby();
- return;
- }
- if (spawned instanceof Colorable)
- {
- final String color = data.toUpperCase(Locale.ENGLISH).replace("BABY", "");
- try
- {
- if (color.equals("RANDOM"))
- {
- final Random rand = new Random();
- ((Colorable)spawned).setColor(DyeColor.values()[rand.nextInt(DyeColor.values().length)]);
- }
- else
- {
- ((Colorable)spawned).setColor(DyeColor.valueOf(color));
- }
- }
- catch (Exception e)
- {
- throw new Exception(_("sheepMalformedColor"), e);
- }
- }
- if (spawned instanceof Tameable && data.contains("tamed"))
- {
- final Tameable tameable = ((Tameable)spawned);
- tameable.setTamed(true);
- tameable.setOwner(user.getBase());
- }
- if (type == EntityType.WOLF
- && data.contains("angry"))
- {
- ((Wolf)spawned).setAngry(true);
- }
- if (type == EntityType.CREEPER && data.contains("powered"))
+ if (args.length < 3)
{
- ((Creeper)spawned).setPowered(true);
- }
- if (type == EntityType.OCELOT)
- {
- if (data.contains("siamese"))
- {
- ((Ocelot)spawned).setCatType(Ocelot.Type.SIAMESE_CAT);
- }
- else if (data.contains("red"))
- {
- ((Ocelot)spawned).setCatType(Ocelot.Type.RED_CAT);
- }
- else if (data.contains("black"))
- {
- ((Ocelot)spawned).setCatType(Ocelot.Type.BLACK_CAT);
- }
- }
- if (type == EntityType.VILLAGER)
- {
- for (Profession prof : Villager.Profession.values())
- {
- if (data.contains(prof.toString().toLowerCase(Locale.ENGLISH)))
- {
- ((Villager)spawned).setProfession(prof);
- }
- }
+ final String mobList = Util.joinList(Mob.getMobList());
+ throw new NotEnoughArgumentsException(_("mobsAvailable", mobList));
}
+
+ String[] mobData = SpawnMob.mobData(args[0]);
+ int mobCount = Integer.parseInt(args[1]);
+
+ final User target = getPlayer(ess.getServer(), args, 2);
+ SpawnMob.spawnmob(ess, server, sender, target, mobData, mobCount);
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandsudo.java b/Essentials/src/com/earth2me/essentials/commands/Commandsudo.java
index d41cf9a51..b2bd5d14b 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandsudo.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandsudo.java
@@ -27,13 +27,13 @@ public class Commandsudo extends EssentialsCommand
}
final User user = getPlayer(server, args, 0, false);
- if(args[1].equalsIgnoreCase("say"))
+ if(args[1].toLowerCase().startsWith("c:"))
{
- if (user.isAuthorized("essentials.sudo.exempt"))
+ if (user.isAuthorized("essentials.sudo.exempt") && sender instanceof Player)
{
throw new Exception(_("sudoExempt"));
}
- user.chat(getFinalArg(args, 2));
+ user.chat(getFinalArg(args, 1).substring(2));
return;
}
final String command = args[1];
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtp.java b/Essentials/src/com/earth2me/essentials/commands/Commandtp.java
index 7c6cbe82d..64332be68 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandtp.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtp.java
@@ -4,6 +4,7 @@ import com.earth2me.essentials.Console;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.Trade;
import com.earth2me.essentials.User;
+import org.bukkit.Location;
import org.bukkit.Server;
import org.bukkit.command.CommandSender;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
@@ -40,7 +41,28 @@ public class Commandtp extends EssentialsCommand
charge.isAffordableFor(user);
user.getTeleport().teleport(player, charge, TeleportCause.COMMAND);
throw new NoChargeException();
-
+ case 4:
+ if (!user.isAuthorized("essentials.tp.others"))
+ {
+ throw new Exception(_("noPerm", "essentials.tp.others"));
+ }
+ user.sendMessage(_("teleporting"));
+ final User target2 = getPlayer(server, args, 0);
+ final double x = args[1].startsWith("~") ? target2.getLocation().getX() + Integer.parseInt(args[1].substring(1)) : Integer.parseInt(args[1]);
+ final double y = args[2].startsWith("~") ? target2.getLocation().getY() + Integer.parseInt(args[2].substring(1)) : Integer.parseInt(args[2]);
+ final double z = args[3].startsWith("~") ? target2.getLocation().getZ() + Integer.parseInt(args[3].substring(1)) : Integer.parseInt(args[3]);
+ if (x > 30000000 || y > 30000000 || z > 30000000 || x < -30000000 || y < -30000000 || z < -30000000)
+ {
+ throw new NotEnoughArgumentsException("Value of coordinates cannot be over 30000000"); //todo: I18n
+ }
+ final Location location = new Location(target2.getWorld(), x, y, z);
+ if (!target2.isTeleportEnabled())
+ {
+ throw new Exception(_("teleportDisabled", target2.getDisplayName()));
+ }
+ target2.getTeleport().now(location, false, TeleportCause.COMMAND);
+ target2.sendMessage(_("teleporting"));
+ case 2:
default:
if (!user.isAuthorized("essentials.tp.others"))
{
@@ -76,10 +98,28 @@ public class Commandtp extends EssentialsCommand
throw new NotEnoughArgumentsException();
}
- sender.sendMessage(_("teleporting"));
final User target = getPlayer(server, args, 0);
- final User toPlayer = getPlayer(server, args, 1);
- target.getTeleport().now(toPlayer, false, TeleportCause.COMMAND);
- target.sendMessage(_("teleportAtoB", Console.NAME, toPlayer.getDisplayName()));
+ if (args.length == 2)
+ {
+ final User toPlayer = getPlayer(server, args, 1);
+ target.getTeleport().now(toPlayer, false, TeleportCause.COMMAND);
+ target.sendMessage(_("teleportAtoB", Console.NAME, toPlayer.getDisplayName()));
+ }
+ else if (args.length > 3)
+ {
+ final double x = args[1].startsWith("~") ? target.getLocation().getX() + Integer.parseInt(args[1].substring(1)) : Integer.parseInt(args[1]);
+ final double y = args[2].startsWith("~") ? target.getLocation().getY() + Integer.parseInt(args[2].substring(1)) : Integer.parseInt(args[2]);
+ final double z = args[3].startsWith("~") ? target.getLocation().getZ() + Integer.parseInt(args[3].substring(1)) : Integer.parseInt(args[3]);
+ if (x > 30000000 || y > 30000000 || z > 30000000 || x < -30000000 || y < -30000000 || z < -30000000)
+ {
+ throw new NotEnoughArgumentsException("Value of coordinates cannot be over 30000000"); //todo: I18n
+ }
+ final Location location = new Location(target.getWorld(), x, y, z);
+ target.getTeleport().now(location, false, TeleportCause.COMMAND);
+ target.sendMessage(_("teleporting"));
+ } else {
+ throw new NotEnoughArgumentsException();
+ }
+ sender.sendMessage(_("teleporting"));
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java b/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
index 75910cd85..c9253c99b 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
@@ -24,9 +24,9 @@ public class Commandtppos extends EssentialsCommand
throw new NotEnoughArgumentsException();
}
- final int x = Integer.parseInt(args[0]);
- final int y = Integer.parseInt(args[1]);
- final int z = Integer.parseInt(args[2]);
+ final double x = args[0].startsWith("~") ? user.getLocation().getX() + Integer.parseInt(args[0].substring(1)) : Integer.parseInt(args[0]);
+ final double y = args[1].startsWith("~") ? user.getLocation().getY() + Integer.parseInt(args[1].substring(1)) : Integer.parseInt(args[1]);
+ final double z = args[2].startsWith("~") ? user.getLocation().getZ() + Integer.parseInt(args[2].substring(1)) : Integer.parseInt(args[2]);
final Location location = new Location(user.getWorld(), x, y, z);
if (args.length > 3)
{
@@ -36,6 +36,10 @@ public class Commandtppos extends EssentialsCommand
{
location.setPitch(Float.parseFloat(args[4]));
}
+ if (x > 30000000 || y > 30000000 || z > 30000000 || x < -30000000 || y < -30000000 || z < -30000000)
+ {
+ throw new NotEnoughArgumentsException("Value of coordinates cannot be over 30000000"); //todo: I18n
+ }
final Trade charge = new Trade(this.getName(), ess);
charge.isAffordableFor(user);
user.sendMessage(_("teleporting"));
@@ -52,9 +56,9 @@ public class Commandtppos extends EssentialsCommand
}
User user = ess.getUser(server.getPlayer(args[0]));
- final int x = Integer.parseInt(args[1]);
- final int y = Integer.parseInt(args[2]);
- final int z = Integer.parseInt(args[3]);
+ final double x = args[1].startsWith("~") ? user.getLocation().getX() + Integer.parseInt(args[1].substring(1)) : Integer.parseInt(args[1]);
+ final double y = args[2].startsWith("~") ? user.getLocation().getY() + Integer.parseInt(args[2].substring(1)) : Integer.parseInt(args[2]);
+ final double z = args[3].startsWith("~") ? user.getLocation().getZ() + Integer.parseInt(args[3].substring(1)) : Integer.parseInt(args[3]);
final Location location = new Location(user.getWorld(), x, y, z);
if (args.length > 4)
{
@@ -64,8 +68,13 @@ public class Commandtppos extends EssentialsCommand
{
location.setPitch(Float.parseFloat(args[5]));
}
+ if (x > 30000000 || y > 30000000 || z > 30000000 || x < -30000000 || y < -30000000 || z < -30000000)
+ {
+ throw new NotEnoughArgumentsException("Value of coordinates cannot be over 30000000"); //todo: I18n
+ }
sender.sendMessage(_("teleporting"));
user.sendMessage(_("teleporting"));
user.getTeleport().teleport(location, null, TeleportCause.COMMAND);
+
}
} \ No newline at end of file
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java b/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java
index 1fc4c2aa4..769060980 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java
@@ -3,6 +3,8 @@ package com.earth2me.essentials.commands;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.User;
import org.bukkit.Server;
+import org.bukkit.command.CommandSender;
+import org.bukkit.entity.Player;
public class Commandtptoggle extends EssentialsCommand
@@ -13,10 +15,59 @@ public class Commandtptoggle extends EssentialsCommand
}
@Override
+ public void run(final Server server, final CommandSender sender, final String commandLabel, final String[] args) throws Exception
+ {
+ if (args.length < 1)
+ {
+ throw new NotEnoughArgumentsException();
+ }
+
+ toggleOtherPlayers(server, sender, args);
+ }
+
+ @Override
public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
- user.sendMessage(user.toggleTeleportEnabled()
- ? _("teleportationEnabled")
- : _("teleportationDisabled"));
+ if (args.length > 0 && args[0].trim().length() > 2 && user.isAuthorized("essentials.tptoggle.others"))
+ {
+ toggleOtherPlayers(server, user, args);
+ return;
+ }
+
+ user.sendMessage(user.toggleTeleportEnabled() ? _("teleportationEnabled") : _("teleportationDisabled"));
+ }
+
+ private void toggleOtherPlayers(final Server server, final CommandSender sender, final String[] args)
+ {
+ for (Player matchPlayer : server.matchPlayer(args[0]))
+ {
+ final User player = ess.getUser(matchPlayer);
+ if (player.isHidden())
+ {
+ continue;
+ }
+
+ if (args.length > 1)
+ {
+ if (args[1].contains("on") || args[1].contains("ena") || args[1].equalsIgnoreCase("1"))
+ {
+ player.setTeleportEnabled(true);
+ }
+ else
+ {
+ player.setTeleportEnabled(false);
+ }
+ }
+ else
+ {
+ player.toggleTeleportEnabled();
+ }
+
+ final boolean enabled = player.isTeleportEnabled();
+
+
+ player.sendMessage(enabled ? _("teleportationEnabled") : _("teleportationDisabled"));
+ sender.sendMessage(enabled ? _("teleportationEnabledFor", matchPlayer.getDisplayName()) : _("teleportationDisabledFor", matchPlayer.getDisplayName()));
+ }
}
}
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandwarp.java b/Essentials/src/com/earth2me/essentials/commands/Commandwarp.java
index 4268ed797..9755d451d 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandwarp.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandwarp.java
@@ -37,8 +37,9 @@ public class Commandwarp extends EssentialsCommand
}
if (args.length > 0)
{
+ //TODO: Remove 'otherplayers' permission.
User otherUser = null;
- if (args.length == 2 && user.isAuthorized("essentials.warp.otherplayers"))
+ if (args.length == 2 && (user.isAuthorized("essentials.warp.otherplayers") || user.isAuthorized("essentials.warp.others")))
{
otherUser = ess.getUser(server.getPlayer(args[1]));
if (otherUser == null)
diff --git a/Essentials/src/com/earth2me/essentials/commands/EssentialsCommand.java b/Essentials/src/com/earth2me/essentials/commands/EssentialsCommand.java
index 6bc0649e9..5287016eb 100644
--- a/Essentials/src/com/earth2me/essentials/commands/EssentialsCommand.java
+++ b/Essentials/src/com/earth2me/essentials/commands/EssentialsCommand.java
@@ -56,14 +56,14 @@ public abstract class EssentialsCommand implements IEssentialsCommand
}
if (args[pos].isEmpty())
{
- throw new NoSuchFieldException(_("playerNotFound"));
+ throw new PlayerNotFoundException();
}
final User user = ess.getUser(args[pos]);
if (user != null)
{
if (!getOffline && (!user.isOnline() || user.isHidden()))
{
- throw new NoSuchFieldException(_("playerNotFound"));
+ throw new PlayerNotFoundException();
}
return user;
}
@@ -85,7 +85,7 @@ public abstract class EssentialsCommand implements IEssentialsCommand
return userMatch;
}
}
- throw new NoSuchFieldException(_("playerNotFound"));
+ throw new PlayerNotFoundException();
}
@Override
diff --git a/Essentials/src/com/earth2me/essentials/commands/PlayerNotFoundException.java b/Essentials/src/com/earth2me/essentials/commands/PlayerNotFoundException.java
new file mode 100644
index 000000000..c33e87522
--- /dev/null
+++ b/Essentials/src/com/earth2me/essentials/commands/PlayerNotFoundException.java
@@ -0,0 +1,11 @@
+package com.earth2me.essentials.commands;
+
+import static com.earth2me.essentials.I18n._;
+
+public class PlayerNotFoundException extends NoSuchFieldException
+{
+ public PlayerNotFoundException()
+ {
+ super(_("playerNotFound"));
+ }
+}
diff --git a/Essentials/src/com/earth2me/essentials/craftbukkit/FakeWorld.java b/Essentials/src/com/earth2me/essentials/craftbukkit/FakeWorld.java
index 1ac37e459..7239ea475 100644
--- a/Essentials/src/com/earth2me/essentials/craftbukkit/FakeWorld.java
+++ b/Essentials/src/com/earth2me/essentials/craftbukkit/FakeWorld.java
@@ -699,4 +699,40 @@ public class FakeWorld implements World
{
throw new UnsupportedOperationException("Not supported yet.");
}
+
+ @Override
+ public int getAmbientSpawnLimit()
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public void setAmbientSpawnLimit(int i)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public String[] getGameRules()
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public String getGameRuleValue(String string)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public boolean setGameRuleValue(String string, String string1)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public boolean isGameRule(String string)
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
}
diff --git a/Essentials/src/com/earth2me/essentials/craftbukkit/SetExpFix.java b/Essentials/src/com/earth2me/essentials/craftbukkit/SetExpFix.java
index 7ed3034c3..e484ebfe1 100644
--- a/Essentials/src/com/earth2me/essentials/craftbukkit/SetExpFix.java
+++ b/Essentials/src/com/earth2me/essentials/craftbukkit/SetExpFix.java
@@ -67,6 +67,10 @@ public class SetExpFix
exp += getExpAtLevel(currentLevel);
currentLevel++;
}
+ if (exp < 0)
+ {
+ exp = Integer.MAX_VALUE;
+ }
return exp;
}
@@ -82,6 +86,10 @@ public class SetExpFix
currentLevel--;
exp += getExpAtLevel(currentLevel);
}
+ if (exp < 0)
+ {
+ exp = Integer.MAX_VALUE;
+ }
return exp;
}
diff --git a/Essentials/src/com/earth2me/essentials/metrics/Metrics.java b/Essentials/src/com/earth2me/essentials/metrics/Metrics.java
index a0bf103e8..77e68a9d6 100644
--- a/Essentials/src/com/earth2me/essentials/metrics/Metrics.java
+++ b/Essentials/src/com/earth2me/essentials/metrics/Metrics.java
@@ -35,6 +35,7 @@ import org.bukkit.configuration.InvalidConfigurationException;
import org.bukkit.configuration.file.YamlConfiguration;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.PluginDescriptionFile;
+import org.bukkit.scheduler.BukkitTask;
/**
@@ -51,7 +52,7 @@ public class Metrics
/**
* The current revision number
*/
- private final static int REVISION = 5;
+ private final static int REVISION = 6;
/**
* The base url of the metrics domain
*/
@@ -61,10 +62,6 @@ public class Metrics
*/
private static final String REPORT_URL = "/report/%s";
/**
- * The file where guid and opt out is stored in
- */
- private static final String CONFIG_FILE = "plugins/PluginMetrics/config.yml";
- /**
* The separator to use for custom data. This MUST NOT change unless you are hosting your own version of metrics and
* want to change it.
*/
@@ -98,13 +95,17 @@ public class Metrics
*/
private final String guid;
/**
+ * Debug mode
+ */
+ private final boolean debug;
+ /**
* Lock for synchronization
*/
private final Object optOutLock = new Object();
/**
- * Id of the scheduled task
+ * The scheduled task
*/
- private volatile int taskId = -1;
+ private volatile BukkitTask task = null;
public Metrics(final Plugin plugin) throws IOException
{
@@ -116,29 +117,31 @@ public class Metrics
this.plugin = plugin;
// load the config
- configurationFile = new File(CONFIG_FILE);
+ configurationFile = getConfigFile();
configuration = YamlConfiguration.loadConfiguration(configurationFile);
// add some defaults
configuration.addDefault("opt-out", false);
configuration.addDefault("guid", UUID.randomUUID().toString());
+ configuration.addDefault("debug", false);
// Do we need to create the file?
if (configuration.get("guid", null) == null)
{
- configuration.options().header("http://metrics.griefcraft.com").copyDefaults(true);
+ configuration.options().header("http://mcstats.org").copyDefaults(true);
configuration.save(configurationFile);
}
// Load the guid then
guid = configuration.getString("guid");
+ debug = configuration.getBoolean("debug", false);
}
/**
* Construct and create a Graph that can be used to separate specific plotters to their own graphs on the metrics
* website. Plotters can be added to the graph object returned.
*
- * @param name
+ * @param name The name of the graph
* @return Graph object created. Will never return NULL under normal circumstances unless bad parameters are given
*/
public Graph createGraph(final String name)
@@ -161,7 +164,7 @@ public class Metrics
/**
* Adds a custom data plotter to the default graph
*
- * @param plotter
+ * @param plotter The plotter to use to plot custom data
*/
public void addCustomData(final Plotter plotter)
{
@@ -193,7 +196,7 @@ public class Metrics
}
// Begin hitting the server with glorious data
- taskId = plugin.getServer().getScheduler().scheduleAsyncRepeatingTask(plugin, new Runnable()
+ task = plugin.getServer().getScheduler().runTaskTimerAsynchronously(plugin, new Runnable()
{
private boolean firstPost = true;
@@ -205,10 +208,15 @@ public class Metrics
synchronized (optOutLock)
{
// Disable Task, if it is running and the server owner decided to opt-out
- if (isOptOut() && taskId > 0)
+ if (isOptOut() && task != null)
{
- plugin.getServer().getScheduler().cancelTask(taskId);
- taskId = -1;
+ task.cancel();
+ task = null;
+ // Tell all plotters to stop gathering information.
+ for (Graph graph : graphs)
+ {
+ graph.onOptOut();
+ }
}
}
@@ -223,7 +231,10 @@ public class Metrics
}
catch (IOException e)
{
- Bukkit.getLogger().log(Level.FINE, "[Metrics] " + e.getMessage());
+ if (debug)
+ {
+ Bukkit.getLogger().log(Level.INFO, "[Metrics] " + e.getMessage());
+ }
}
}
}, 0, PING_INTERVAL * 1200);
@@ -233,7 +244,7 @@ public class Metrics
/**
* Has the server owner denied plugin metrics?
*
- * @return
+ * @return true if metrics should be opted out of it
*/
public boolean isOptOut()
{
@@ -242,16 +253,22 @@ public class Metrics
try
{
// Reload the metrics file
- configuration.load(CONFIG_FILE);
+ configuration.load(getConfigFile());
}
catch (IOException ex)
{
- Bukkit.getLogger().log(Level.INFO, "[Metrics] " + ex.getMessage());
+ if (debug)
+ {
+ Bukkit.getLogger().log(Level.INFO, "[Metrics] " + ex.getMessage());
+ }
return true;
}
catch (InvalidConfigurationException ex)
{
- Bukkit.getLogger().log(Level.INFO, "[Metrics] " + ex.getMessage());
+ if (debug)
+ {
+ Bukkit.getLogger().log(Level.INFO, "[Metrics] " + ex.getMessage());
+ }
return true;
}
return configuration.getBoolean("opt-out", false);
@@ -276,7 +293,7 @@ public class Metrics
}
// Enable Task, if it is not running
- if (taskId < 0)
+ if (task == null)
{
start();
}
@@ -297,35 +314,81 @@ public class Metrics
if (!isOptOut())
{
configuration.set("opt-out", true);
- final File file = new File(CONFIG_FILE);
- configuration.save(file);
+ configuration.save(configurationFile);
}
// Disable Task, if it is running
- if (taskId >= 0)
+ if (task != null)
{
- this.plugin.getServer().getScheduler().cancelTask(taskId);
- taskId = -1;
+ task.cancel();
+ task = null;
}
}
}
/**
+ * Gets the File object of the config file that should be used to store data such as the GUID and opt-out status
+ *
+ * @return the File object for the config file
+ */
+ public File getConfigFile()
+ {
+ // I believe the easiest way to get the base folder (e.g craftbukkit set via -P) for plugins to use
+ // is to abuse the plugin object we already have
+ // plugin.getDataFolder() => base/plugins/PluginA/
+ // pluginsFolder => base/plugins/
+ // The base is not necessarily relative to the startup directory.
+ File pluginsFolder = plugin.getDataFolder().getParentFile();
+
+ // return => base/plugins/PluginMetrics/config.yml
+ return new File(new File(pluginsFolder, "PluginMetrics"), "config.yml");
+ }
+
+ /**
* Generic method that posts a plugin to the metrics website
*/
private void postPlugin(final boolean isPing) throws IOException
{
- // The plugin's description file containg all of the plugin data such as name, version, author, etc
- final PluginDescriptionFile description = plugin.getDescription();
+ // Server software specific section
+ PluginDescriptionFile description = plugin.getDescription();
+ String pluginName = description.getName();
+ boolean onlineMode = Bukkit.getServer().getOnlineMode(); // TRUE if online mode is enabled
+ String pluginVersion = description.getVersion();
+ String serverVersion = Bukkit.getVersion();
+ int playersOnline = Bukkit.getServer().getOnlinePlayers().length;
+
+ // END server software specific section -- all code below does not use any code outside of this class / Java
// Construct the post data
final StringBuilder data = new StringBuilder();
+
+ // The plugin's description file containg all of the plugin data such as name, version, author, etc
data.append(encode("guid")).append('=').append(encode(guid));
- encodeDataPair(data, "version", description.getVersion());
- encodeDataPair(data, "server", Bukkit.getVersion());
- encodeDataPair(data, "players", Integer.toString(Bukkit.getServer().getOnlinePlayers().length));
+ encodeDataPair(data, "version", pluginVersion);
+ encodeDataPair(data, "server", serverVersion);
+ encodeDataPair(data, "players", Integer.toString(playersOnline));
encodeDataPair(data, "revision", String.valueOf(REVISION));
+ // New data as of R6
+ String osname = System.getProperty("os.name");
+ String osarch = System.getProperty("os.arch");
+ String osversion = System.getProperty("os.version");
+ String java_version = System.getProperty("java.version");
+ int coreCount = Runtime.getRuntime().availableProcessors();
+
+ // normalize os arch .. amd64 -> x86_64
+ if (osarch.equals("amd64"))
+ {
+ osarch = "x86_64";
+ }
+
+ encodeDataPair(data, "osname", osname);
+ encodeDataPair(data, "osarch", osarch);
+ encodeDataPair(data, "osversion", osversion);
+ encodeDataPair(data, "cores", Integer.toString(coreCount));
+ encodeDataPair(data, "online-mode", Boolean.toString(onlineMode));
+ encodeDataPair(data, "java_version", java_version);
+
// If we're pinging, append it
if (isPing)
{
@@ -342,10 +405,6 @@ public class Metrics
{
final Graph graph = iter.next();
- // Because we have a lock on the graphs set already, it is reasonable to assume
- // that our lock transcends down to the individual plotters in the graphs also.
- // Because our methods are private, no one but us can reasonably access this list
- // without reflection so this is a safe assumption without adding more code.
for (Plotter plotter : graph.getPlotters())
{
// The key name to send to the metrics server
@@ -364,7 +423,7 @@ public class Metrics
}
// Create the url
- final URL url = new URL(BASE_URL + String.format(REPORT_URL, description.getName()));
+ URL url = new URL(BASE_URL + String.format(REPORT_URL, encode(pluginName)));
// Connect to the website
URLConnection connection;
@@ -420,13 +479,12 @@ public class Metrics
}
}
}
- //if (response.startsWith("OK")) - We should get "OK" followed by an optional description if everything goes right
}
/**
* Check if mineshafter is present. If it is, we need to bypass it to send POST requests
*
- * @return
+ * @return true if mineshafter is installed on the server
*/
private boolean isMineshafterPresent()
{
@@ -450,10 +508,9 @@ public class Metrics
* encodeDataPair(data, "version", description.getVersion());
* </code>
*
- * @param buffer
- * @param key
- * @param value
- * @return
+ * @param buffer the stringbuilder to append the data pair onto
+ * @param key the key value
+ * @param value the value
*/
private static void encodeDataPair(final StringBuilder buffer, final String key, final String value) throws UnsupportedEncodingException
{
@@ -463,8 +520,8 @@ public class Metrics
/**
* Encode text as UTF-8
*
- * @param text
- * @return
+ * @param text the text to encode
+ * @return the encoded text, as UTF-8
*/
private static String encode(final String text) throws UnsupportedEncodingException
{
@@ -495,7 +552,7 @@ public class Metrics
/**
* Gets the graph's name
*
- * @return
+ * @return the Graph's name
*/
public String getName()
{
@@ -505,7 +562,7 @@ public class Metrics
/**
* Add a plotter to the graph, which will be used to plot entries
*
- * @param plotter
+ * @param plotter the plotter to add to the graph
*/
public void addPlotter(final Plotter plotter)
{
@@ -515,7 +572,7 @@ public class Metrics
/**
* Remove a plotter from the graph
*
- * @param plotter
+ * @param plotter the plotter to remove from the graph
*/
public void removePlotter(final Plotter plotter)
{
@@ -525,7 +582,7 @@ public class Metrics
/**
* Gets an <b>unmodifiable</b> set of the plotter objects in the graph
*
- * @return
+ * @return an unmodifiable {@link Set} of the plotter objects
*/
public Set<Plotter> getPlotters()
{
@@ -549,6 +606,13 @@ public class Metrics
final Graph graph = (Graph)object;
return graph.name.equals(name);
}
+
+ /**
+ * Called when the server owner decides to opt-out of Metrics while the server is running.
+ */
+ protected void onOptOut()
+ {
+ }
}
@@ -573,7 +637,7 @@ public class Metrics
/**
* Construct a plotter with a specific plot name
*
- * @param name
+ * @param name the name of the plotter to use, which will show up on the website
*/
public Plotter(final String name)
{
@@ -581,9 +645,11 @@ public class Metrics
}
/**
- * Get the current value for the plotted point
+ * Get the current value for the plotted point. Since this function defers to an external function it may or may
+ * not return immediately thus cannot be guaranteed to be thread friendly or safe. This function can be called
+ * from any thread so care should be taken when accessing resources that need to be synchronized.
*
- * @return
+ * @return the current value for the point to be plotted.
*/
public abstract int getValue();
@@ -607,7 +673,7 @@ public class Metrics
@Override
public int hashCode()
{
- return getColumnName().hashCode() + getValue();
+ return getColumnName().hashCode();
}
@Override
diff --git a/Essentials/src/com/earth2me/essentials/perm/BPermissions2Handler.java b/Essentials/src/com/earth2me/essentials/perm/BPermissions2Handler.java
index 653a13441..791ffbe92 100644
--- a/Essentials/src/com/earth2me/essentials/perm/BPermissions2Handler.java
+++ b/Essentials/src/com/earth2me/essentials/perm/BPermissions2Handler.java
@@ -35,7 +35,7 @@ public class BPermissions2Handler extends SuperpermsHandler
@Override
public boolean inGroup(final Player base, final String group)
{
- return ApiLayer.hasGroup(base.getWorld().getName(), CalculableType.USER, base.getName(), group);
+ return ApiLayer.hasGroupRecursive(base.getWorld().getName(), CalculableType.USER, base.getName(), group);
}
@Override
diff --git a/Essentials/src/com/earth2me/essentials/signs/SignPlayerListener.java b/Essentials/src/com/earth2me/essentials/signs/SignPlayerListener.java
index 08257c9e4..12296b023 100644
--- a/Essentials/src/com/earth2me/essentials/signs/SignPlayerListener.java
+++ b/Essentials/src/com/earth2me/essentials/signs/SignPlayerListener.java
@@ -21,6 +21,11 @@ public class SignPlayerListener implements Listener
this.ess = ess;
}
+ //This following code below listens to cancelled events to fix a bukkit issue
+ //Right clicking signs with a block in hand, can now fire cancelled events.
+ //This is because when the block place is cancelled (for example not enough space for the block to be placed),
+ //the event will be marked as cancelled, thus preventing 30% of sign purchases.
+
@EventHandler(priority = EventPriority.LOW)
public void onPlayerInteract(final PlayerInteractEvent event)
{
diff --git a/Essentials/src/com/earth2me/essentials/signs/SignProtection.java b/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
index 6fdf056e2..1ea26c859 100644
--- a/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
+++ b/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
@@ -10,7 +10,7 @@ import org.bukkit.block.BlockFace;
import org.bukkit.block.Sign;
import org.bukkit.inventory.ItemStack;
-
+@Deprecated // This sign will be removed soon
public class SignProtection extends EssentialsSign
{
private final transient Set<Material> protectedBlocks = EnumSet.noneOf(Material.class);
diff --git a/Essentials/src/com/earth2me/essentials/signs/SignSpawnmob.java b/Essentials/src/com/earth2me/essentials/signs/SignSpawnmob.java
index 7c4cfcd54..23f08a414 100644
--- a/Essentials/src/com/earth2me/essentials/signs/SignSpawnmob.java
+++ b/Essentials/src/com/earth2me/essentials/signs/SignSpawnmob.java
@@ -2,6 +2,7 @@ package com.earth2me.essentials.signs;
import com.earth2me.essentials.ChargeException;
import com.earth2me.essentials.IEssentials;
+import com.earth2me.essentials.SpawnMob;
import com.earth2me.essentials.Trade;
import com.earth2me.essentials.User;
import com.earth2me.essentials.commands.Commandspawnmob;
@@ -27,20 +28,17 @@ public class SignSpawnmob extends EssentialsSign
{
final Trade charge = getTrade(sign, 3, ess);
charge.isAffordableFor(player);
- Commandspawnmob command = new Commandspawnmob();
- command.setEssentials(ess);
- String[] args = new String[]
- {
- sign.getLine(2), sign.getLine(1)
- };
+
try
{
- command.run(ess.getServer(), player, "spawnmob", args);
+ String[] mobData = SpawnMob.mobData(sign.getLine(2));
+ SpawnMob.spawnmob(ess, ess.getServer(), player, player, mobData, Integer.parseInt(sign.getLine(1)));
}
catch (Exception ex)
{
throw new SignException(ex.getMessage(), ex);
}
+
charge.charge(player);
return true;
}
diff --git a/Essentials/src/config.yml b/Essentials/src/config.yml
index 9fa0f8c4c..a766e0549 100644
--- a/Essentials/src/config.yml
+++ b/Essentials/src/config.yml
@@ -32,11 +32,10 @@ change-displayname: true
# The value of change-displayname (above) has to be true.
#change-playerlist: true
-# Adds the prefix and suffix to the displayname of the player, so it will be displayed in messages and lists.
-# The prefix/suffix can be set using Permissions, Group Manager or PermissionsEx.
+# When essentialschat.jar isnt used, force essentials to add the prefix and suffix from permission plugins to displayname
+# This setting is ignored if essentialschat.jar is used, and defaults to 'true'
# The value of change-displayname (above) has to be true.
-# If you don't set this, it will default to true if essentials chat is installed.
-# Don't forget to remove the # in front of the line
+# Do not edit this setting unless you know what you are doing!
#add-prefix-suffix: false
# The delay, in seconds, required between /home, /tp, etc.
@@ -65,6 +64,7 @@ item-spawn-blacklist:
# - essentials.give.item-all
# - essentials.give.item-[itemname]
# - essentials.give.item-[itemid]
+# For more information, visit http://wiki.ess3.net/wiki/Command_Reference/ICheat#Item.2FGive
permission-based-item-spawn: false
# Mob limit on the /spawnmob command per execution
@@ -76,7 +76,7 @@ warn-on-smite: true
# motd and rules are now configured in the files motd.txt and rules.txt
# When a command conflicts with another plugin, by default, Essentials will try to force the OTHER plugin to take priority.
-# Commands in in this list, will tell Essentials to 'not give up' the command to other plugins.
+# Commands in this list, will tell Essentials to 'not give up' the command to other plugins.
# In this state, which plugin 'wins' appears to be almost random.
#
# If you have two plugin with the same command and you wish to force Essentials to take over, you need an alias.
@@ -89,11 +89,11 @@ overridden-commands:
# Disabled commands will be completely unavailable on the server.
# Disabling commands here will have no effect on command conflicts.
disabled-commands:
-# - nick
+# - nick
# If you do not wish to use a permission system, you can define a list of 'player perms' below.
-# This list has no effect if your using a supported permissions system.
-# If your using an unsupported permissions system simply delete this section.
+# This list has no effect if you are using a supported permissions system.
+# If you are using an unsupported permissions system simply delete this section.
# Whitelist the commands and permissions you wish to give players by default (everything else is op only).
# These are the permissions without the "essentials." part.
player-commands:
@@ -181,6 +181,7 @@ player-commands:
# All kit names should be lower case, and will be treated as lower in permissions/costs.
# Syntax: - itemID[:DataValue] Amount [Enchantment:Level]..
# 'delay' refers to the cooldown between how often you can use each kit, measured in seconds.
+# For more information, visit http://wiki.ess3.net/wiki/Command_Reference/ICheat#kits
kits:
dtools:
delay: 10
@@ -200,7 +201,7 @@ kits:
# See http://wiki.ess3.net/wiki/Sign_Tutorial for instructions on how to use these.
# To enable signs, remove # symbol. To disable all signs, comment/remove each sign.
# Essentials Colored sign support will be enabled when any sign types are enabled.
-# Color is not an actual sign, its for enabling using color codes on signs, when the correct permissions are given.
+# Color is not an actual sign, it's for enabling using color codes on signs, when the correct permissions are given.
enabledSigns:
#- color
@@ -246,8 +247,10 @@ debug: false
# Set the locale for all messages
# If you don't set this, the default locale of the server will be used.
+# For example, to set language to English, set locale to en, to use the file "messages_en.properties"
# Don't forget to remove the # in front of the line
-#locale: de_DE
+# For more information, visit http://wiki.ess3.net/wiki/Locale
+#locale: en
# Turn off god mode when people exit
remove-god-on-disconnect: false
@@ -287,12 +290,12 @@ no-god-in-worlds:
# Set to true to enable per-world permissions for teleporting between worlds with essentials commands
# This applies to /world, /back, /tp[a|o][here|all], but not warps.
# Give someone permission to teleport to a world with essentials.worlds.<worldname>
-# This does not effect the /home command, there is a separate toggle below for this.
+# This does not affect the /home command, there is a separate toggle below for this.
world-teleport-permissions: false
# The number of items given if the quantity parameter is left out in /item or /give.
# If this number is below 1, the maximum stack size size is given. If over-sized stacks
-# are not enabled, any number higher then the maximum stack size results in more than one stack.
+# are not enabled, any number higher than the maximum stack size results in more than one stack.
default-stack-size: -1
# Over-sized stacks are stacks that ignore the normal max stack size.
@@ -315,6 +318,9 @@ login-attack-delay: 5
#Set the max fly speed, values range from 0.1 to 1.0
max-fly-speed: 0.8
+#Set the maximum amount of mail that can be sent within a minute.
+mails-per-minute: 1000
+
############################################################
# +------------------------------------------------------+ #
# | EssentialsHome | #
@@ -333,6 +339,7 @@ world-home-permissions: false
# Players need essentials.sethome.multiple before they can have more than 1 home, defaults to 'default' below.
# Define different amounts of multiple homes for different permissions, e.g. essentials.sethome.multiple.vip
# People with essentials.sethome.multiple.unlimited are not limited by these numbers.
+# For more information, visit http://wiki.ess3.net/wiki/Multihome
sethome-multiple:
default: 3
# essentials.sethome.multiple.vip
@@ -350,6 +357,8 @@ tpa-accept-cancellation: 0
# +------------------------------------------------------+ #
############################################################
+# For more information, visit http://wiki.ess3.net/wiki/Essentials_Economy
+
# Defines the balance with which new players begin. Defaults to 0.
starting-balance: 0
@@ -368,7 +377,7 @@ command-costs:
currency-symbol: '$'
# Set the maximum amount of money a player can have
-# The amount is always limited to 10 trillions because of the limitations of a java double
+# The amount is always limited to 10 trillion because of the limitations of a java double
max-money: 10000000000000
# Set the minimum amount of money a player can have (must be above the negative of max-money).
@@ -457,6 +466,10 @@ protect:
fireball-explosion: false
fireball-fire: false
fireball-playerdamage: false
+ witherskull-explosion: false
+ witherskull-playerdamage: false
+ wither-spawnexplosion: false
+ wither-blockreplace: false
creeper-explosion: false
creeper-playerdamage: false
creeper-blockdamage: false
@@ -493,7 +506,10 @@ protect:
ocelot: false
iron_golem: false
villager: false
-
+ wither: false
+ bat: false
+ witch: false
+
# Maximum height the creeper should explode. -1 allows them to explode everywhere.
# Set prevent.creeper-explosion to true, if you want to disable creeper explosions.
creeper:
@@ -546,6 +562,9 @@ protect:
# Should the damage after hit by a lightning be disabled?
lightning: false
+
+ # Should Wither damage be disabled?
+ wither: false
# Disable weather options
weather:
@@ -560,6 +579,7 @@ protect:
############################################################
# Disable various default physics and behaviors
+ # For more information, visit http://wiki.ess3.net/wiki/AntiBuild
# Should people with build: false in permissions be allowed to build
# Set true to disable building for those people
diff --git a/Essentials/src/items.csv b/Essentials/src/items.csv
index a3d6ca91b..8b0f8b967 100644
--- a/Essentials/src/items.csv
+++ b/Essentials/src/items.csv
@@ -639,19 +639,22 @@ pstick,29,7
spiderweb,30,0
sweb,30,0
web,30,0
-longgrass,31,0
-tallgrass,31,0
-wildgrass,31,0
-grasslong,31,0
-grasstall,31,0
-grasswild,31,0
-lgrass,31,0
-tgrass,31,0
-wgrass,31,0
+longgrass,31,1
+tallgrass,31,1
+wildgrass,31,1
+grasslong,31,1
+grasstall,31,1
+grasswild,31,1
+lgrass,31,1
+tgrass,31,1
+wgrass,31,1
+fern,31,2
+bush,31,2
deadshrub,32,0
-shrubdead,32,0
dshrub,32,0
-shrubd,32,0
+deadbush,32,0
+dbush,32,0
+deadsapling,32,0
normalpistonbase,33,7
normalpiston,33,7
normpistonbase,33,7
@@ -826,12 +829,16 @@ rose,38,0
redflower,38,0
rflower,38,0
brownmushroom,39,0
+brownshroom,39,0
brownmush,39,0
bmushroom,39,0
+bshroom,39,0
bmush,39,0
redmushroom,40,0
+redshroom,40,0
redmush,40,0
rmushroom,40,0
+rshroom,40,0
rmush,40,0
goldblock,41,0
blockgold,41,0
@@ -1163,13 +1170,13 @@ smoothstonehalfblock,44,0
stonehalfblock,44,0
shalfblock,44,0
halfblock,44,0
-sanddstonestep,44,1
+sandstonestep,44,1
sstonestep,44,1
ssstep,44,1
-sanddstoneslab,44,1
+sandstoneslab,44,1
sstoneslab,44,1
ssslab,44,1
-sanddstonehalfblock,44,1
+sandstonehalfblock,44,1
sstonehalfblock,44,1
sshalfblock,44,1
woodenplankstonestep,44,2
@@ -1587,7 +1594,6 @@ tdoor,96,0
doort,96,0
trapd,96,0
dtrap,96,0
-monsteregg,97,0
silverfish,97,0
monsteregg,97,0
monstereggsmoothstone,97,0
@@ -1660,33 +1666,54 @@ circlestonebrick,98,3
circlestonebb,98,3
circlestone,98,3
circlesbb,98,3
+giantredmushroom,99,0
hugeredmushroom,99,0
bigredmushroom,99,0
-brmushroom,99,0
-giantredmushroom,99,0
+gredmushroom,99,0
+hredmushroom,99,0
+bredmushroom,99,0
+giantrmushroom,99,0
+hugermushroom,99,0
+bigrmushroom,99,0
grmushroom,99,0
+hrmushroom,99,0
+brmushroom,99,0
+giantbrownmushroom,100,0
hugebrownmushroom,100,0
bigbrownmushroom,100,0
-bbmushroom,100,0
-giantbrownmushroom,100,0
+gbrownmushroom,100,0
+hbrownmushroom,100,0
+bbrownmushroom,100,0
+giantbmushroom,100,0
+hugebmushroom,100,0
+bigbmushroom,100,0
gbmushroom,100,0
+hbmushroom,100,0
+bbmushroom,100,0
ironbars,101,0
ironbarsb,101,0
ironbarsblock,101,0
-metalbarsblock,101,0
-metalbarsb,101,0
+ironfence,101,0
metalbars,101,0
-jailbarsblock,101,0
-jailbarsb,101,0
+metalbarsb,101,0
+metalbarsblock,101,0
+metalfence,101,0
jailbars,101,0
-mbarsblock,101,0
-mbarsb,101,0
+jailbarsb,101,0
+jailbarsblock,101,0
+jailfence,101,0
mbars,101,0
-jbarsblock,101,0
-jbarsb,101,0
+mbarsb,101,0
+mbarsblock,101,0
+mfence,101,0
jbars,101,0
+jbarsb,101,0
+jbarsblock,101,0
+jfence,101,0
+ibars,101,0
ibarsb,101,0
ibarsblock,101,0
+ifence,101,0
glasspane,102,0
glassp,102,0
paneglass,102,0
@@ -2950,6 +2977,141 @@ forestwoodenstair,136,0
forestwoodstair,136,0
forestwstair,136,0
foreststair,136,0
+commandblock,137,0
+blockcommand,137,0
+cmdblock,137,0
+blockcmd,137,0
+macroblock,137,0
+blockmacro,137,0
+beacon,138,0
+beaconblock,138,0
+cobblestonewall,139,0
+cstonewall,139,0
+cobblewall,139,0
+cobblestonefence,139,0
+cstonefence,139,0
+cobblefence,139,0
+mosscobblestonewall,139,1
+mosscstonewall,139,1
+mosscobblewall,139,1
+mcobblestonewall,139,1
+mcstonewall,139,1
+mcobblewall,139,1
+mosscobblestonefence,139,1
+mosscstonefence,139,1
+mosscobblefence,139,1
+mcobblestonefence,139,1
+mcstonefence,139,1
+mcobblefence,139,1
+emptyflowerpot,140,0
+emptypot,140,0
+flowerpotblock,140,0
+potblock,140,0
+roseflowerpot,140,1
+rosepot,140,1
+dandelionflowerpot,140,2
+dandelionpot,140,2
+oaksaplingflowerpot,140,3
+saplingflowerpot,140,3
+oakflowerpot,140,3
+oaksaplingpot,140,3
+saplingpot,140,3
+oakpot,140,3
+sprucesaplingflowerpot,140,4
+spruceflowerpot,140,4
+darksaplingflowerpot,140,4
+darkflowerpot,140,4
+pinesaplingflowerpot,140,4
+pineflowerpot,140,4
+sprucesaplingpot,140,4
+sprucepot,140,4
+darksaplingpot,140,4
+darkpot,140,4
+pinesaplingpot,140,4
+pinepot,140,4
+birchsaplingflowerpot,140,5
+birchflowerpot,140,5
+lightsaplingflowerpot,140,5
+lightflowerpot,140,5
+whitesaplingflowerpot,140,5
+whiteflowerpot,140,5
+birchsaplingpot,140,5
+birchpot,140,5
+lightsaplingpot,140,5
+lightpot,140,5
+whitesaplingpot,140,5
+whitepot,140,5
+forestsaplingflowerpot,140,6
+forestflowerpot,140,6
+junglesaplingflowerpot,140,6
+jungleflowerpot,140,6
+forestsaplingpot,140,6
+forestpot,140,6
+junglesaplingpot,140,6
+junglepot,140,6
+redmushroomflowerpot,140,7
+redshroomflowerpot,140,7
+redmushflowerpot,140,7
+rmushroomflowerpot,140,7
+rshroomflowerpot,140,7
+rmushflowerpot,140,7
+redmushroompot,140,7
+redshroompot,140,7
+redmushpot,140,7
+rmushroompot,140,7
+rshroompot,140,7
+rmushpot,140,7
+brownmushroomflowerpot,140,8
+brownshroomflowerpot,140,8
+brownmushflowerpot,140,8
+bmushroomflowerpot,140,8
+bshroomflowerpot,140,7
+bmushflowerpot,140,8
+brownmushroompot,140,8
+brownshroompot,140,8
+brownmushpot,140,8
+bmushroompot,140,8
+bshroompot,140,8
+bmushpot,140,8
+cactusflowerpot,140,9
+cactuspot,140,9
+deadbushflowerpot,140,10
+dbushflowerpot,140,10
+deadsaplingflowerpot,140,10
+dsaplingflowerpot,140,10
+deadshrubflowerpot,140,10
+dshrubflowerpot,140,10
+deadbushpot,140,10
+dbushpot,140,10
+deadsaplingpot,140,10
+dsaplingpot,140,10
+deadshrubpot,140,10
+dshrubpot,140,10
+fernflowerpot,140,11
+bushflowerpot,140,11
+fernpot,140,11
+bushpot,140,11
+carrots,141,0
+plantedcarrot,141,0
+plantcarrot,141,0
+growingcarrot,141,0
+potatoes,142,0
+plantedpotato,142,0
+plantpotato,142,0
+growingpotato,142,0
+woodenplankbutton,143,0
+woodplankbutton,143,0
+wplankbutton,143,0
+plankbutton,143,0
+woodenbutton,143,0
+woodbutton,143,0
+wbutton,143,0
+headblock,144,0
+anvil,145,0
+slightlydamagedanvil,145,1
+slightdamageanvil,145,1
+damagedanvil,145,1
+verydamagedanvil,145,2
ironshovel,256,0
ironspade,256,0
ishovel,256,0
@@ -3819,7 +3981,6 @@ dioder,356,0
diode,356,0
cookie,357,0
chart,358,0
-map,358,0
map0,358,0
map1,358,1
map2,358,2
@@ -4075,6 +4236,19 @@ healingpot,373,8197
healpot,373,8197
lifepot,373,8197
hpot,373,8197
+nightvisionpotion,373,8198
+nvisionpotion,373,8198
+nightvpotion,373,8198
+darkvisionpotion,373,8198
+dvisionpotion,373,8198
+darkvpotion,373,8198
+nightvisionpot,373,8198
+nvisionpot,373,8198
+nightvpot,373,8198
+darkvisionpot,373,8198
+dvisionpot,373,8198
+darkvpot,373,8198
+npot,373,8198
weaknesspotion,373,8200
weakpotion,373,8200
weaknesspot,373,8200
@@ -4099,6 +4273,13 @@ harmingpot,373,8204
damagepot,373,8204
dmgpot,373,8204
dpot,373,8204
+invisibilitypotion,373,8206
+invisiblepotion,373,8206
+invpotion,373,8206
+invisibilitypot,373,8206
+invisiblepot,373,8206
+invpot,373,8206
+ipot,373,8206
regenerationleveliipotion,373,8225
regenerateleveliipotion,373,8225
regenleveliipotion,373,8225
@@ -4162,7 +4343,7 @@ healinglevel2pot,373,8229
heallevel2pot,373,8229
healingiipot,373,8229
healiipot,373,8229
-h2potpot,373,8229
+h2pot,373,8229
strengthleveliipotion,373,8233
strongleveliipotion,373,8233
strleveliipotion,373,8233
@@ -4249,6 +4430,31 @@ acidextendedpot,373,8260
posionexpot,373,8260
acidexpot,373,8260
pepot,373,8260
+nightvisionextendedpotion,373,8262
+nvisionextendedpotion,373,8262
+nightvextendedpotion,373,8262
+darkvisionextendedpotion,373,8262
+dvisionextendedpotion,373,8262
+darkvextendedpotion,373,8262
+nightvisionexpotion,373,8262
+nvisionexpotion,373,8262
+nightvexpotion,373,8262
+darkvisionexpotion,373,8262
+dvisionexpotion,373,8262
+darkvexpotion,373,8262
+nightvisionextendedpot,373,8262
+nvisionextendedpot,373,8262
+nightvextendedpot,373,8262
+darkvisionextendedpot,373,8262
+dvisionextendedpot,373,8262
+darkvextendedpot,373,8262
+nightvisionexpot,373,8262
+nvisionexpot,373,8262
+nightvexpot,373,8262
+darkvisionexpot,373,8262
+dvisionexpot,373,8262
+darkvexpot,373,8262
+nepot,373,8262
weaknessextendedpotion,373,8264
weakextendedpotion,373,8264
weaknessexpotion,373,8264
@@ -4280,6 +4486,19 @@ slowextenedpot,373,8266
slownessexpot,373,8266
slowexpot,373,8266
slepot,373,8266
+invisibilityextendedpotion,373,8270
+invisibleextendedpotion,373,8270
+invextendedpotion,373,8270
+invisibilityexpotion,373,8270
+invisibleexpotion,373,8270
+invexpotion,373,8270
+invisibilityextendedpot,373,8270
+invisibleextendedpot,373,8270
+invextendedpot,373,8270
+invisibilityexpot,373,8270
+invisibleexpot,373,8270
+invexpot,373,8270
+iepot,373,8270
regenerationdualbitpotion,373,8289
regeneratedualbitpotion,373,8289
regendualbitpotion,373,8289
@@ -4398,6 +4617,31 @@ splashclearpotion,373,16390
splashclearpot,373,16390
splclearpotion,373,16390
splclearpot,373,16390
+splashnightvisionpotion,373,16390
+splashnvisionpotion,373,16390
+splashnightvpotion,373,16390
+splashdarkvisionpotion,373,16390
+splashdvisionpotion,373,16390
+splashdarkvpotion,373,16390
+splashnightvisionpot,373,16390
+splashnvisionpot,373,16390
+splashnightvpot,373,16390
+splashdarkvisionpot,373,16390
+splashdvisionpot,373,16390
+splashdarkvpot,373,16390
+splnightvisionpotion,373,16390
+splnvisionpotion,373,16390
+splnightvpotion,373,16390
+spldarkvisionpotion,373,16390
+spldvisionpotion,373,16390
+spldarkvpotion,373,16390
+splnightvisionpot,373,16390
+splnvisionpot,373,16390
+splnightvpot,373,16390
+spldarkvisionpot,373,16390
+spldvisionpot,373,16390
+spldarkvpot,373,16390
+spnpot,373,16390
splashclearextendedpotion,373,16391
splashclearexpotion,373,16391
splashclear2potion,373,16391
@@ -4466,6 +4710,19 @@ splashthinpotion,373,16398
splashthinpot,373,16398
splthinpotion,373,16398
splthinpot,373,16398
+splashinvisibilitypotion,373,16398
+splashinvisiblepotion,373,16398
+splashinvpotion,373,16398
+splashinvisibilitypot,373,16398
+splashinvisiblepot,373,16398
+splashinvpot,373,16398
+splinvisibilitypotion,373,16398
+splinvisiblepotion,373,16398
+splinvpotion,373,16398
+splinvisibilitypot,373,16398
+splinvisiblepot,373,16398
+splinvpot,373,16398
+spipot,373,16398
splashthinextendedpotion,373,16399
splashthinexpotion,373,16399
splashthin2potion,373,16399
@@ -4912,6 +5169,55 @@ splacidextendedpot,373,16452
splposionexpot,373,16452
splacidexpot,373,16452
sppepot,373,16452
+splashnightvisionextendedpotion,373,16454
+splashnvisionextendedpotion,373,16454
+splashnightvextendedpotion,373,16454
+splashdarkvisionextendedpotion,373,16454
+splashdvisionextendedpotion,373,16454
+splashdarkvextendedpotion,373,16454
+splashnightvisionextendedpot,373,16454
+splashnvisionextendedpot,373,16454
+splashnightvextendedpot,373,16454
+splashdarkvisionextendedpot,373,16454
+splashdvisionextendedpot,373,16454
+splashdarkvextendedpot,373,16454
+splashnightvisionexpotion,373,16454
+splashnvisionexpotion,373,16454
+splashnightvexpotion,373,16454
+splashdarkvisionexpotion,373,16454
+splashdvisionexpotion,373,16454
+splashdarkvexpotion,373,16454
+splashnightvisionexpot,373,16454
+splashnvisionexpot,373,16454
+splashnightvexpot,373,16454
+splashdarkvisionexpot,373,16454
+splashdvisionexpot,373,16454
+splashdarkvexpot,373,16454
+splnightvisionextendedpotion,373,16454
+splnvisionextendedpotion,373,16454
+splnightvextendedpotion,373,16454
+spldarkvisionextendedpotion,373,16454
+spldvisionextendedpotion,373,16454
+spldarkvextendedpotion,373,16454
+splnightvisionextendedpot,373,16454
+splnvisionextendedpot,373,16454
+splnightvextendedpot,373,16454
+spldarkvisionextendedpot,373,16454
+spldvisionextendedpot,373,16454
+spldarkvextendedpot,373,16454
+splnightvisionexpotion,373,16454
+splnvisionexpotion,373,16454
+splnightvexpotion,373,16454
+spldarkvisionexpotion,373,16454
+spldvisionexpotion,373,16454
+spldarkvexpotion,373,16454
+splnightvisionexpot,373,16454
+splnvisionexpot,373,16454
+splnightvexpot,373,16454
+spldarkvisionexpot,373,16454
+spldvisionexpot,373,16454
+spldarkvexpot,373,16454
+spnepot,373,16454
splashweaknessextendedpotion,373,16456
splashweakextendedpotion,373,16456
splashweaknessexpotion,373,16456
@@ -4971,6 +5277,31 @@ splslowextenedpot,373,16458
splslownessexpot,373,16458
splslowexpot,373,16458
spslepot,373,16458
+splashinvisibilityextendedpotion,373,16462
+splashinvisibleextendedpotion,373,16462
+splashinvextendedpotion,373,16462
+splashinvisibilityextendedpot,373,16462
+splashinvisibleextendedpot,373,16462
+splashinvextendedpot,373,16462
+splashinvisibilityexpotion,373,16462
+splashinvisibleexpotion,373,16462
+splashinvexpotion,373,16462
+splashinvisibilityexpot,373,16462
+splashinvisibleexpot,373,16462
+splashinvexpot,373,16462
+splinvisibilityextendedpotion,373,16462
+splinvisibleextendedpotion,373,16462
+splinvextendedpotion,373,16462
+splinvisibilityextendedpot,373,16462
+splinvisibleextendedpot,373,16462
+splinvextendedpot,373,16462
+splinvisibilityexpotion,373,16462
+splinvisibleexpotion,373,16462
+splinvexpotion,373,16462
+splinvisibilityexpot,373,16462
+splinvisibleexpot,373,16462
+splinvexpot,373,16462
+spiepot,373,16462
splashregenerationdualbitpotion,373,16481
splashregeneratedualbitpotion,373,16481
splashregendualbitpotion,373,16481
@@ -5191,6 +5522,10 @@ egglavaslime,383,62
egglavacube,383,62
eggmagmacube,383,62
eggmagmaslime,383,62
+bategg,383,65
+eggbat,383,65
+witchegg,383,66
+eggwitch,383,66
pigegg,383,90
eggpig,383,90
sheepegg,383,91
@@ -5243,6 +5578,53 @@ sealedbook,387,0
diary,387,0
ownedbook,387,0
emerald,388,0
+itemframe,389,0
+pictureframe,389,0
+iframe,389,0
+pframe,389,0
+flowerpot,390,0
+pot,390,0
+carrot,391,0
+potato,392,0
+bakedpotato,393,0
+roastedpotato,393,0
+cookedpotato,393,0
+bakepotato,393,0
+roastpotato,393,0
+cookpotato,393,0
+posionouspotato,394,0
+posionpotato,394,0
+emptymap,395,0
+map,395,0
+goldencarrot,396,0
+goldcarrot,396,0
+gcarrot,396,0
+head,397,0
+skeletonhead,397,0
+headskeleton,397,0
+witherhead,397,1
+witherskeletonhead,397,1
+wskeletionhead,397,1
+headwither,397,1
+headwitherskeleton,397,1
+headwskeletion,397,1
+zombiehead,397,2
+headzombie,397,2
+humanhead,397,3
+stevehead,397,3
+headhuman,397,3
+headsteve,397,3
+creeperhead,397,4
+headcreeper,397,4
+carrotonastick,398,0
+carrotonstick,398,0
+netherstar,399,0
+hellstar,399,0
+pumpkinpie,400,0
+pumpkincake,400,0
+ppie,400,0
+pcake,400,0
+pie,400,0
goldmusicrecord,2256,0
goldmusicdisk,2256,0
goldmusicdisc,2256,0
diff --git a/Essentials/src/messages.properties b/Essentials/src/messages.properties
index 4852f2bef..8a17513cf 100644
--- a/Essentials/src/messages.properties
+++ b/Essentials/src/messages.properties
@@ -2,7 +2,7 @@
# Single quotes have to be doubled: ''
# Translations start here
# by:
-action=\u00a7d* {0} {1}
+action=\u00a75* {0} \u00a75{1}
addedToAccount=\u00a7a{0} has been added to your account.
addedToOthersAccount=\u00a7a{0} added to {1}\u00a7a account. New balance: {2}
adventure= adventure
@@ -194,7 +194,7 @@ listAmountHidden= \u00a76There are \u00a7c{0}\u00a76/{1}\u00a76 out of maximum \
listGroupTag={0}\u00a7r:
listHiddenTag= \u00a77[HIDDEN]\u00a7r
loadWarpError=\u00a74Failed to load warp {0}
-localFormat=Local: <{0}> {1}
+localFormat=[L]<{0}> {1}
mailClear=\u00a76To mark your mail as read, type\u00a7c /mail clear
mailCleared=\u00a76Mail Cleared!
mailSent=\u00a76Mail sent!
@@ -264,7 +264,7 @@ notRecommendedBukkit= \u00a74* ! * Bukkit version is not the recommended build f
notSupportedYet=Not supported yet.
nothingInHand=\u00a74You have nothing in your hand.
now=now
-nuke=\u00a7dMay death rain upon them
+nuke=\u00a75May death rain upon them
numberRequired=A number goes there, silly.
onlyDayNight=/time only supports day/night.
onlyPlayers=\u00a74Only in-game players can use {0}.
@@ -373,6 +373,8 @@ timeSet=\u00a76Time set in all worlds.
timeSetPermission=\u00a74You are not authorized to set the time.
timeWorldCurrent=\u00a76The current time in\u00a7c {0} \u00a76is \u00a7c{1}
timeWorldSet=\u00a76The time was set to\u00a7c {0} \u00a76in: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=\u00a76Current TPS = {0}
tradeCompleted=\u00a7aTrade completed.
tradeSignEmpty=\u00a74The trade sign has nothing available for you.
@@ -397,8 +399,8 @@ unvanished=\u00a76You are once again visible.
unvanishedReload=\u00a74A reload has forced you to become visible.
upgradingFilesError=Error while upgrading the files
userDoesNotExist=\u00a74The user\u00a7c {0} \u00a74does not exist.
-userIsAway=\u00a7d{0} \u00a7dis now AFK
-userIsNotAway=\u00a7d{0} \u00a7dis no longer AFK
+userIsAway=\u00a75{0} \u00a75is now AFK
+userIsNotAway=\u00a75{0} \u00a75is no longer AFK
userJailed=\u00a76You have been jailed
userUsedPortal={0} used an existing exit portal.
userdataMoveBackError=Failed to move userdata/{0}.tmp to userdata/{1}
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_cs.properties b/Essentials/src/messages_cs.properties
index 26e039001..5cc095f15 100644
--- a/Essentials/src/messages_cs.properties
+++ b/Essentials/src/messages_cs.properties
@@ -376,6 +376,8 @@ timeSet=Cas nastaven ve vsech svetech.
timeSetPermission=\u00a7cNejsi autorizovany ke zmene casu.
timeWorldCurrent=Ve svete {0} je prave \u00a73{1}
timeWorldSet=Cas byl nastaven na {0} ve: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Vymena kompletni.
tradeSignEmpty=Tato cedule jiz nema dostupny material na vymenu.
@@ -461,3 +463,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_da.properties b/Essentials/src/messages_da.properties
index 9419ad45e..6beff781a 100644
--- a/Essentials/src/messages_da.properties
+++ b/Essentials/src/messages_da.properties
@@ -373,6 +373,8 @@ timeSet=Tid \u00c3\u00a6ndret i alle verdener.
timeSetPermission=\u00a7cDu har ikke tilladelse til at \u00c3\u00a6ndre tiden.
timeWorldCurrent=Tiden p\u00c3\u00a5 nuv\u00c3\u00a6rende tidspunkt i {0} er \u00a73{1}
timeWorldSet=Tiden blev \u00c3\u00a6ndret til {0} i: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Handel gennemf\u00f8rt.
tradeSignEmpty=Handelsskiltet har udsolgt!
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_de.properties b/Essentials/src/messages_de.properties
index 90e373b33..4db624c6a 100644
--- a/Essentials/src/messages_de.properties
+++ b/Essentials/src/messages_de.properties
@@ -373,6 +373,8 @@ timeSet=Zeit in allen Welten gesetzt.
timeSetPermission=\u00a7cDu hast keine Berechtigung die Zeit zu \u00e4ndern.
timeWorldCurrent=Die momentane Zeit in {0} ist \u00a73{1}
timeWorldSet=Die Zeit in \u00a7c{1}\u00a7f wurde zu {0} gesetzt.
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Handel abgeschlossen.
tradeSignEmpty=Der Bestand des Trade-Schild ist aufgebraucht.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_en.properties b/Essentials/src/messages_en.properties
index 4852f2bef..8a17513cf 100644
--- a/Essentials/src/messages_en.properties
+++ b/Essentials/src/messages_en.properties
@@ -2,7 +2,7 @@
# Single quotes have to be doubled: ''
# Translations start here
# by:
-action=\u00a7d* {0} {1}
+action=\u00a75* {0} \u00a75{1}
addedToAccount=\u00a7a{0} has been added to your account.
addedToOthersAccount=\u00a7a{0} added to {1}\u00a7a account. New balance: {2}
adventure= adventure
@@ -194,7 +194,7 @@ listAmountHidden= \u00a76There are \u00a7c{0}\u00a76/{1}\u00a76 out of maximum \
listGroupTag={0}\u00a7r:
listHiddenTag= \u00a77[HIDDEN]\u00a7r
loadWarpError=\u00a74Failed to load warp {0}
-localFormat=Local: <{0}> {1}
+localFormat=[L]<{0}> {1}
mailClear=\u00a76To mark your mail as read, type\u00a7c /mail clear
mailCleared=\u00a76Mail Cleared!
mailSent=\u00a76Mail sent!
@@ -264,7 +264,7 @@ notRecommendedBukkit= \u00a74* ! * Bukkit version is not the recommended build f
notSupportedYet=Not supported yet.
nothingInHand=\u00a74You have nothing in your hand.
now=now
-nuke=\u00a7dMay death rain upon them
+nuke=\u00a75May death rain upon them
numberRequired=A number goes there, silly.
onlyDayNight=/time only supports day/night.
onlyPlayers=\u00a74Only in-game players can use {0}.
@@ -373,6 +373,8 @@ timeSet=\u00a76Time set in all worlds.
timeSetPermission=\u00a74You are not authorized to set the time.
timeWorldCurrent=\u00a76The current time in\u00a7c {0} \u00a76is \u00a7c{1}
timeWorldSet=\u00a76The time was set to\u00a7c {0} \u00a76in: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=\u00a76Current TPS = {0}
tradeCompleted=\u00a7aTrade completed.
tradeSignEmpty=\u00a74The trade sign has nothing available for you.
@@ -397,8 +399,8 @@ unvanished=\u00a76You are once again visible.
unvanishedReload=\u00a74A reload has forced you to become visible.
upgradingFilesError=Error while upgrading the files
userDoesNotExist=\u00a74The user\u00a7c {0} \u00a74does not exist.
-userIsAway=\u00a7d{0} \u00a7dis now AFK
-userIsNotAway=\u00a7d{0} \u00a7dis no longer AFK
+userIsAway=\u00a75{0} \u00a75is now AFK
+userIsNotAway=\u00a75{0} \u00a75is no longer AFK
userJailed=\u00a76You have been jailed
userUsedPortal={0} used an existing exit portal.
userdataMoveBackError=Failed to move userdata/{0}.tmp to userdata/{1}
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_es.properties b/Essentials/src/messages_es.properties
index b3b098d91..8d0ad7892 100644
--- a/Essentials/src/messages_es.properties
+++ b/Essentials/src/messages_es.properties
@@ -10,10 +10,10 @@ alertBroke=Roto:
alertFormat=\u00a73[{0}] \u00a7f {1} \u00a76 {2} en: {3}
alertPlaced=Situado:
alertUsed=Usado:
-antiBuildBreak=\u00a74You are not permitted to break {0} blocks here.
-antiBuildInteract=\u00a74You are not permitted to interact with {0}.
-antiBuildPlace=\u00a74You are not permitted to place {0} here.
-antiBuildUse=\u00a74You are not permitted to use {0}.
+antiBuildBreak=\u00a74Tu no tines permitido romper {0} bloques aca.
+antiBuildInteract=\u00a74Tu no tienes permitido interactuar con {0}.
+antiBuildPlace=\u00a74Tu no tienes permitido poner {0} aca.
+antiBuildUse=\u00a74Tu no tienes permitido usar {0}.
autoAfkKickReason=Has sido echado por ausentarte mas de {0} minutos.
backAfterDeath=\u00a77Usa el comando /back para volver al punto en el que moriste.
backUsageMsg=\u00a77Volviendo a la localizacion anterior.
@@ -28,7 +28,7 @@ banIpAddress=\u00a77Direccion IP baneada.
bigTreeFailure=\u00a7cBig Generacion de arbol fallida. Prueba de nuevo en hierba o arena.
bigTreeSuccess= \u00a77Big Arbol generado.
blockList=Essentials le ha cedido los siguientes comandos a otros plugins:
-broadcast=[\u00a7cAnuncio\u00a7f]\u00a7a {0}
+broadcast=\u00a7c[\u00a76Broadcast\u00a7c]\u00a7a {0}
buildAlert=\u00a7cNo tienes permisos para construir.
bukkitFormatChanged=Version de formato de Bukkit cambiado. Version no comprobada.
burnMsg=\u00a77Has puesto {0} en fuego durante {1} segundos.
@@ -36,16 +36,16 @@ canTalkAgain=\u00a77Ya puedes hablar de nuevo.
cantFindGeoIpDB=No se puede encontrar la base de datos del Geo IP.
cantReadGeoIpDB=Error al intentar leer la base de datos del Geo IP.
cantSpawnItem=\u00a7cNo tienes acceso para producir este objeto {0}
-chatTypeAdmin=[A]
-chatTypeLocal=[L]
+chatTypeAdmin=
+chatTypeLocal=
chatTypeSpy=[Espia]
commandFailed=Comando {0} fallado:
commandHelpFailedForPlugin=Error obteniendo ayuda para: {0}
-commandNotLoaded=\u00a7cCommand {0} esta cargado incorrectamente.
+commandNotLoaded=\u00a7cComando {0} esta cargado incorrectamente.
compassBearing=\u00a77Bearing: {0} ({1} grados).
configFileMoveError=Error al mover config.yml para hacer una copia de seguridad de la localizacion.
configFileRenameError=Error al renombrar archivo temp a config.yml.
-connectedPlayers=Jugadores conectados:
+connectedPlayers=Jugadores conectados:
connectionFailed=Error al abrir conexion.
cooldownWithMessage=\u00a7cTiempo restante: {0}
corruptNodeInConfig=\u00a74Notice: Tu archivo de configuracion tiene un nodo {0} incorrecto.
@@ -118,7 +118,7 @@ hatArmor=\u00a7cNo puedes usar este item como sombrero!
hatEmpty=\u00a7cNo estas usando un sombrero.
hatFail=\u00a7cDebes tener un item en tu mano para usarlo de sombrero.
hatPlaced=\u00a7eDisfruta tu nuevo sombrero!
-hatRemoved=\u00a7eYour hat has been removed.
+hatRemoved=\u00a7eTu sombrero a sido removido.
haveBeenReleased=\u00a77Has sido liberado.
heal=\u00a77Has sido curado.
healOther=\u00a77Has curado a {0}.
@@ -157,7 +157,7 @@ inventoryClearedOthers=\u00a77Inventario de \u00a7c{0}\u00a77 limpiado.
is=es
itemCannotBeSold=Ese objeto no puede ser vendido al servidor.
itemMustBeStacked=El objeto tiene que ser intercambiado en pilas. Una cantidad de 2s seria de dos pilas, etc.
-itemNames=Item short names: {0}
+itemNames=Articulo nombres cortos: {0}
itemNotEnough1=\u00a7cNo tienes suficientes ejemplares de ese objeto para venderlo.
itemNotEnough2=\u00a77Si pensabas en vender todos tus objetos de ese tipo, usa /sell nombredeobjeto
itemNotEnough3=\u00a77/sell nombredeobjeto -1 vendera todos excepto un objeto, etc.
@@ -188,10 +188,10 @@ kitTimed=\u00a7c No puedes usar ese kit de nuevo para otro{0}.
kits=\u00a77Kits: {0}
lightningSmited=\u00a77Acabas de ser golpeado.
lightningUse=\u00a77Golpeando a {0}
-listAfkTag = \u00a77[AFK]\u00a7f
+listAfkTag = \u00a77[Lejos]\u00a7f
listAmount = \u00a79Hay \u00a7c{0}\u00a79 jugadores de un maximo de \u00a7c{1}\u00a79 jugadores online.
listAmountHidden = \u00a79Hay \u00a7c{0}\u00a79 jugadores de un maximo de \u00a7c{1}\u00a79 jugadores online.
-listGroupTag={0}\u00a7f:
+listGroupTag={0}\u00a7f:
listHiddenTag = \u00a77[ESCONDIDO]\u00a7f
loadWarpError=Error al cargar el teletransporte {0}
localFormat=Local: <{0}> {1}
@@ -218,7 +218,7 @@ moneyTaken={0} han sido sacados de tu cuenta bancaria.
month=mes
months=meses
moreThanZero=Las cantidades han de ser mayores que 0.
-moveSpeed=\u00a77Set {0} speed to {1} for {2}.
+moveSpeed=\u00a77Has puesto {0} velocidad a {1} por {2}.
msgFormat=\u00a77[{0}\u00a77 -> {1}\u00a77] \u00a7f{2}
muteExempt=\u00a7cNo puedes silenciar a ese jugador.
mutedPlayer=Player {0} silenciado.
@@ -251,7 +251,7 @@ noPendingRequest=No tienes ninguna peticion pendiente.
noPerm=\u00a7cNo tienes el permiso de \u00a7f{0}\u00a7c.
noPermToSpawnMob=\u00a7cNo tienes permisos para spawnear a este mob.
noPlacePermission=\u00a7cNo tienes permiso para situar ese bloque en ese lugar.
-noPowerTools=You have no power tools assigned.
+noPowerTools=Usted no tiene ningunas herramientas el\u00c3\u00a9ctricas asignadas.
noRules=\u00a7cNo hay reglas especificadas todavia.
noWarpsDefined=No hay teletransportes definidos aun.
none=ninguno
@@ -262,7 +262,7 @@ notEnoughMoney=No tienes el dinero suficiente.
notFlying=no volando
notRecommendedBukkit=* ! * La version de bukkit no es la recomendada para esta version de Essentials.
notSupportedYet=No tiene soporte por el momento.
-nothingInHand = \u00a7cNo tienes anda en tu mano.
+nothingInHand = \u00a7cNo tienes nada en tu mano.
now=ahora
nuke=Que la muerta afecte al que no despierte.
numberRequired=Un numero es necesario, amigo .
@@ -304,8 +304,8 @@ powerToolRemove=Comando \u00a7c{0}\u00a7f borrado desde {1}.
powerToolRemoveAll=Todos los comandos borrados desde {0}.
powerToolsDisabled=Todas tus herramientas de poder han sido desactivadas.
powerToolsEnabled=Todas tus herramientas de poder han sido activadas.
-protectionOwner=\u00a76[EssentialsProtect] Due&ntilde;o de la proteccion: {0}
-questionFormat=\u00a77[Pregunta]\u00a7f {0}
+protectionOwner=\u00a76[EssentialsProtect] Dueno de la proteccion: {0}
+questionFormat=\u00a7c[Pregunta]\u00a7f {0}
readNextPage=escribe /{0} {1} para leer la prox. pagina.
reloadAllPlugins=\u00a77Todos los plugins recargados.
removed=\u00a77{0} entidades removidas.
@@ -330,7 +330,7 @@ serverFull=Servidor lleno.
serverTotal=Server Total: {0}
setSpawner=Cambiado tipo de spawner a {0}
sheepMalformedColor=Color malformado.
-shoutFormat=\u00a77[Shout]\u00a7f {0}
+shoutFormat=\u00a7a[Mundo]\u00a7f {0}
signFormatFail=\u00a74[{0}]
signFormatSuccess=\u00a71[{0}]
signFormatTemplate=[{0}]
@@ -343,7 +343,7 @@ spawned=nacido
sudoExempt=No puedes usar el comando sudo con este user.
sudoRun=Forzando {0} a ejecutar: /{1} {2}
suicideMessage=\u00a77Adios mundo cruel...
-suicideSuccess= \u00a77{0} se quito su propia vida.
+suicideSuccess= \u00a77{0} se tiro desde un rascacielos.
survival=supervivencia
takenFromAccount=\u00a7c{0} han sido sacados de tu cuenta.
takenFromOthersAccount=\u00a7c{0} han sidos sacados de la cuenta de {1}\u00a7c . Nuevo presupuesto: {2}
@@ -373,6 +373,8 @@ timeSet=Tiempo establecido en todos los mundos.
timeSetPermission=\u00a7cNo estas autorizado para establecer la hora.
timeWorldCurrent=La hora actual en {0} es \u00a73{1}
timeWorldSet=La hora ha sido establecida a {0} en: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=TPS actual = {0}
tradeCompleted=\u00a77Intercambio completado.
tradeSignEmpty=Esta tienda no tiene nada disponible para ti.
@@ -423,7 +425,7 @@ weatherStormFor=\u00a77Has establecido el tiempo como tormenta en este {1} duran
weatherSun=\u00a77Has establecido el tiempo como sol en este mundo.
weatherSunFor=\u00a77Has establecido el tiempo como sol en este {1} durante {0} segundos.
whoisAFK=\u00a76 - AFK:\u00a7f {0}
-whoisBanned=\u00a76 - Banned:\u00a7f {0}
+whoisBanned=\u00a76 - Baneado:\u00a7f {0}
whoisExp=\u00a76 - Exp:\u00a7f {0} (Nivel {1})
whoisFly=\u00a76 - Modo de vuelo:\u00a7f {0} ({1})
whoisGamemode=\u00a76 - Modo de juego:\u00a7f {0}
@@ -441,20 +443,26 @@ whoisTop=\u00a76 ====== WhoIs:\u00a7f {0} \u00a76======
worth=\u00a77Pila de {0} con valor de \u00a7c{1}\u00a77 ({2} objeto(s) a {3} cada uno)
worthMeta=\u00a77Pila de {0} con metadata de {1} , con valor de \u00a7c{2}\u00a77 ({3} objeto(s) a {4} cada uno)
worthSet=Establecer el valor de un valor
-year=a&ntilde;o
-years=a&ntilde;os
+year=ano
+years=anos
youAreHealed=\u00a77Has sido curado.
youHaveNewMail=\u00a7cTienes {0} mensajes!\u00a7f Pon \u00a77/mail read\u00a7f para ver tus emails no leidos!.
-posX=\u00a76X: {0} (+East <-> -West)
-posY=\u00a76Y: {0} (+Up <-> -Down)
-posZ=\u00a76Z: {0} (+South <-> -North)
-posYaw=\u00a76Yaw: {0} (Rotation)
-posPitch=\u00a76Pitch: {0} (Head angle)
-distance=\u00a76Distance: {0}
-giveSpawn=\u00a76Giving\u00a7c {0} \u00a76of\u00a7c {1} to\u00a7c {2}\u00a76.
+posX=\u00a76X: {0} (+Este <-> -Oeste)
+posY=\u00a76Y: {0} (+Arriba <-> -abajo)
+posZ=\u00a76Z: {0} (+Sur <-> -Norte)
+posYaw=\u00a76gui\u00c3\u00b1ar: {0} (Rotacion)
+posPitch=\u00a76Tono: {0} (Angulo de cabeza)
+distance=\u00a76Distancia: {0}
+giveSpawn=\u00a76Se a dado\u00a7c {0} \u00a76de\u00a7c {1} a\u00a7c {2}\u00a76.
warpList={0}
uptime=\u00a76Uptime:\u00a7c {0}
-antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
-antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
-gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
-invalidHomeName=\u00a74Invalid home name
+antiBuildCraft=\u00a74No se le permite crear\u00a7c {0}\u00a74.
+antiBuildDrop=\u00a74No se le permite botar \u00a7c {0}\u00a74.
+gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entidades
+invalidHomeName=\u00a74Nombre de casa invalido
+invalidWarpName=\u00a74Nombre de warp invalido
+userUnknown=\u00a74Peligro: El jugador '\u00a7c{0}\u00a74' Nunca a ingresado a este servidor.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_fi.properties b/Essentials/src/messages_fi.properties
index 8dd5343ad..fef0aeb78 100644
--- a/Essentials/src/messages_fi.properties
+++ b/Essentials/src/messages_fi.properties
@@ -373,6 +373,8 @@ timeSet=Aika asetettu kaikissa maailmoissa.
timeSetPermission=\u00a7cSinulla ei ole lupaa vaihtaa aikaa.
timeWorldCurrent=T\u00e4m\u00e4nhetkinen aika maailmassa {0} on \u00a73{1}
timeWorldSet=Aika vaihdettiin {0} maailmassa: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=T\u00e4m\u00e4nhetkinen TPS = {0}
tradeCompleted=\u00a77Vaihto suoritettu.
tradeSignEmpty=Vaihtokyltill\u00e4 ei ole mit\u00e4\u00e4n tarjolla sinulle.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_fr.properties b/Essentials/src/messages_fr.properties
index 7468952a6..e5cfd4975 100644
--- a/Essentials/src/messages_fr.properties
+++ b/Essentials/src/messages_fr.properties
@@ -3,31 +3,31 @@
# Translations start here
# by: L\u00e9a Gris
action=* {0} {1}
-addedToAccount=\u00a7a{0} a \u00e9t\u00e9 rajout\u00e9 \u00e0 votre compte.
-addedToOthersAccount=\u00a7a{0} added to {1}\u00a7a account. New balance: {2}
+addedToAccount=\u00a7a{0} ont \u00e9t\u00e9 ajout\u00e9 \u00e0 votre compte.
+addedToOthersAccount=\u00a7a{0} ajout\u00e9s au compte de {1}\u00a7a. Nouveau solde : {2}
adventure = adventure
alertBroke=a cass\u00e9 :
alertFormat=\u00a73[{0}] \u00a7f {1} \u00a76 {2} \u00e0:{3}
alertPlaced=a plac\u00e9 :
alertUsed=a utilis\u00e9 :
-antiBuildBreak=\u00a74You are not permitted to break {0} blocks here.
-antiBuildInteract=\u00a74You are not permitted to interact with {0}.
-antiBuildPlace=\u00a74You are not permitted to place {0} here.
-antiBuildUse=\u00a74You are not permitted to use {0}.
+antiBuildBreak=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 casser des blocs de {0} ici.
+antiBuildInteract=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 interagir avec {0}.
+antiBuildPlace=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 placer {0} ici.
+antiBuildUse=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 utliser {0}.
autoAfkKickReason=Vous avez \u00e9t\u00e9 \u00e9ject\u00e9 pour inactivit\u00e9e sup\u00e9rieure \u00e0 {0} minutes.
backAfterDeath=\u00a77Utilisez la commande /back pour retourner \u00e0 l''endroit ou vous \u00eates mort.
-backUsageMsg=\u00a77Retour \u00e0 votre emplacement pr\u00e9c\u00c3\u00a8dent.
-backupDisabled=An external backup script has not been configured.
+backUsageMsg=\u00a77Retour \u00e0 votre emplacement pr\u00e9c\u00e9dent.
+backupDisabled=Aucun script de backup externe n'a \u00e9t\u00e9 configur\u00e9.
backupFinished=Sauvegarde termin\u00e9
backupStarted=D\u00e9but de la sauvegarde...
balance=\u00a77Solde : {0}
balanceTop=\u00a77Meilleurs soldes au ({0})
banExempt=\u00a77Vous ne pouvez pas bannir ce joueur.
-banFormat=Banned: {0}
+banFormat=Banni : {0}
banIpAddress=\u00a77Adresse IP bannie.
bigTreeFailure=\u00a7c\u00c9chec de la g\u00e9n\u00e9ration du gros arbre. Essayez de nouveau sur de la terre ou de l'herbe.
bigTreeSuccess=\u00a77Gros arbre cr\u00e9e.
-blockList=Essentials relayed the following commands to another plugin:
+blockList=Essentials a relay\u00e9 les commandes suivantes \u00e0 un autre plugin :
broadcast=[\u00a7cMessage\u00a7f]\u00a7a {0}
buildAlert=\u00a7cVous n'avez pas la permission de construire.
bukkitFormatChanged=Le format de la version de Bukkit a \u00e9t\u00e9 chang\u00e9. La version n''a pas \u00e9t\u00e9 v\u00e9rifi\u00e9e.
@@ -35,7 +35,7 @@ burnMsg=\u00a77Vous avez enflamm\u00e9 {0} pour {1} seconde(s).
canTalkAgain=\u00a77Vous pouvez de nouveau parler.
cantFindGeoIpDB=N'arrive pas \u00e0 trouver la base de donn\u00e9es GeoIP!
cantReadGeoIpDB=Echec de la lecture de la base de donn\u00e9es GeoIP!
-cantSpawnItem=\u00a7cVous n''avez pas le droit de faire appara\u00c3\u00aetre {0}
+cantSpawnItem=\u00a7cVous n''avez pas le droit de faire appara\u00eetre {0}
chatTypeAdmin=[A]
chatTypeLocal=[L]
chatTypeSpy=[Spy]
@@ -46,15 +46,15 @@ compassBearing=\u00a77Orientation : {0} ({1} degr\u00e9s).
configFileMoveError=\u00c9chec du d\u00e9placement de config.yml vers l'emplacement de sauvegarde.
configFileRenameError=\u00c9chec du changement de nom du fichier temporaire de config.yml
connectedPlayers=Joueurs connect\u00e9s :
-connectionFailed=\u00c9chec de l'ouverture de la connexion.
+connectionFailed=\u00c9chec de la connexion.
cooldownWithMessage=\u00a7cR\u00e9utilisation : {0}
corruptNodeInConfig=\u00a74Annonce : Votre fichier de configuration a un {0} n\u0153ud corrompu.
-couldNotFindTemplate=Le mod\u00c3\u00a8le {0} est introuvable
-creatingConfigFromTemplate=Cr\u00e9ation de la configuration \u00e0 partir du mod\u00c3\u00a8le : {0}
+couldNotFindTemplate=Le mod\u00e8le {0} est introuvable
+creatingConfigFromTemplate=Cr\u00e9ation de la configuration \u00e0 partir du mod\u00e8le : {0}
creatingEmptyConfig=Cr\u00e9ation d''une configuration vierge : {0}
creative=cr\u00e9atif
currency={0}{1}
-currentWorld=Current World: {0}
+currentWorld=Monde actuel : {0}
day=jour
days=jours
defaultBanReason=Le marteau du bannissement a frapp\u00e9 !
@@ -62,7 +62,7 @@ deleteFileError=Le fichier {0} n''a pas pu \u00eatre supprim\u00e9
deleteHome=\u00a77La r\u00e9sidence {0} a \u00e9t\u00e9 supprim\u00e9e.
deleteJail=\u00a77La prison {0} a \u00e9t\u00e9 supprim\u00e9e.
deleteWarp=\u00a77Warp {0} supprim\u00e9.
-deniedAccessCommand=L''acc\u00c3\u00a8s \u00e0 la commande a \u00e9t\u00e9 refus\u00e9 pour {0}.
+deniedAccessCommand=L''acc\u00e8s \u00e0 la commande a \u00e9t\u00e9 refus\u00e9 pour {0}.
dependancyDownloaded=[Essentials] Fichier {0} correctement t\u00e9l\u00e9charg\u00e9.
dependancyException=[Essentials] Une erreur est survenue lors de la tentative de t\u00e9l\u00e9chargement.
dependancyNotFound=[Essentials] Une d\u00e9pendance requise n'a pas \u00e9t\u00e9 trouv\u00e9e, t\u00e9l\u00e9chargement en cours.
@@ -72,25 +72,25 @@ depthBelowSea=\u00a77Vous \u00eates \u00e0 {0} bloc(s) en-dessous du niveau de l
destinationNotSet=Destination non d\u00e9finie
disableUnlimited=\u00a77D\u00e9sactivation du placement illimit\u00e9 de {0} pour {1}.
disabled=d\u00e9sactiv\u00e9
-disabledToSpawnMob=Spawning this mob was disabled in the config file.
+disabledToSpawnMob=L'invacation de ce monstre a \u00e9t\u00e9 d\u00e9sactiv\u00e9e dans le fichier de configuration.
dontMoveMessage=\u00a77La t\u00e9l\u00e9portation commence dans {0}. Ne bougez pas.
downloadingGeoIp=T\u00e9l\u00e9chargement de la base de donn\u00e9es GeoIP ... Cela peut prendre un moment (Pays : 0.6 Mo, villes : 20Mo)
duplicatedUserdata=Donn\u00e9e utilisateur dupliqu\u00e9e : {0} et {1}
-durability=\u00a77This tool has \u00a7c{0}\u00a77 uses left
+durability=\u00a77Cet outil a \u00a7c{0}\u00a77 usages restants
enableUnlimited=\u00a77Quantit\u00e9 illimit\u00e9e de {0} \u00e0 {1}.
enabled=activ\u00e9
enchantmentApplied = \u00a77L''enchantement {0} a \u00e9t\u00e9 appliqu\u00e9 \u00e0 l''objet dans votre main.
-enchantmentNotFound = \u00a7cEnchantement non-trouv\u00e9
+enchantmentNotFound = \u00a7cEnchantement non trouv\u00e9
enchantmentPerm = \u00a7cVous n''avez pas les droits pour {0}.
-enchantmentRemoved = \u00a77The enchantment {0} has been removed from your item in hand.
-enchantments = \u00a77Enchantments : {0}
+enchantmentRemoved = \u00a77L'enchantement {0} de l'item dans votre main a \u00e9t\u00e9 supprim\u00e9.
+enchantments = \u00a77Enchantements : {0}
errorCallingCommand=Erreur en appelant la commande /{0}
errorWithMessage=\u00a7cErreur : {0}
essentialsHelp1=Le fichier est corrompuet Essentials ne peut l'ouvrir. Essentials est maintenant d\u00e9sactiv\u00e9. Si vous ne pouvez corriger vous-m\u00eame, aller \u00e0 http://tiny.cc/EssentialsChat
essentialsHelp2=Le fichier est corrompuet Essentials ne peut l'ouvrir. Essentials est maintenant d\u00e9sactiv\u00e9. Si vous ne pouvez corriger vous-m\u00eame, tapez /essentialshelp ou aller \u00e0 http://tiny.cc/EssentialsChat
essentialsReload=\u00a77Essentials {0} a \u00e9t\u00e9 recharg\u00e9.
-exp=\u00a7c{0} \u00a77has\u00a7c {1} \u00a77exp (level\u00a7c {2}\u00a77) and needs\u00a7c {3} \u00a77more exp to level up.
-expSet=\u00a7c{0} \u00a77now has\u00a7c {1} \u00a77exp.
+exp=\u00a7c{0} \u00a77a\u00a7c {1} \u00a77exp (niveau\u00a7c {2}\u00a77) et a besoin de\u00a7c {3} \u00a77pour monter d'un niveau.
+expSet=\u00a7c{0} \u00a77a maintenant\u00a7c {1} \u00a77exp.
extinguish=\u00a77Vous cessez de br\u00fbler.
extinguishOthers=\u00a77Vous avez \u00e9teint la combustion de {0}.
failedToCloseConfig=Echec de la fermeture de la configuration {0}
@@ -100,7 +100,7 @@ false=\u00a74false\u00a7f
feed=\u00a77Vous avez \u00e9t\u00e9 rassasi\u00e9.
feedOther=\u00a77 est rassasi\u00e9 {0}.
fileRenameError=Echec du changement de nom de {0}
-flyMode=\u00a77Set fly mode {0} for {1}.
+flyMode=\u00a77Fly mode {0} pour {1} d\u00e9fini.
flying=flying
foreverAlone=\u00a7cVous n''avez personne \u00e0 qui r\u00e9pondre
freedMemory=A lib\u00e9r\u00e9 {0} Mo.
@@ -114,21 +114,21 @@ geoipJoinFormat=Joueur {0} vient de {1}
godDisabledFor=d\u00e9sactiv\u00e9 pour {0}
godEnabledFor=activ\u00e9 pour {0}
godMode=\u00a77Mode Dieu {0}.
-hatArmor=\u00a7cError, you cannot use this item as a hat!
-hatEmpty=\u00a7cYou are not wearing a hat.
-hatFail=\u00a7cYou must have something to wear in your hand.
-hatPlaced=\u00a7eEnjoy your new hat!
-hatRemoved=\u00a7eYour hat has been removed.
+hatArmor=\u00a7cErreur, vous ne pouvez pas utliser cet item comme chapeau !
+hatEmpty=\u00a7cVous ne portez pas de chapeau.
+hatFail=\u00a7cVous devez avoir quelque chose \u00e0 porter dans votre main.
+hatPlaced=\u00a7eProfitez bien de votre nouveau chapeau !
+hatRemoved=\u00a7eVotre chapeau a \u00e9t\u00e9 retir\u00e9.
haveBeenReleased=\u00a77Vous avez \u00e9t\u00e9 lib\u00e9r\u00e9.
heal=\u00a77Vous avez \u00e9t\u00e9 soign\u00e9.
healOther=\u00a77{0} a \u00e9t\u00e9 soign\u00e9.
helpConsole=Pour voir l''aide tapez ?
helpFrom=\u00a77Commands from {0}:
helpLine=\u00a76/{0}\u00a7f: {1}
-helpMatching=\u00a77Commands matching "{0}":
+helpMatching=\u00a77Commandes correspondant \u00e0 "{0}" :
helpOp=\u00a7c[Aide Admin]\u00a7f \u00a77{0} : \u00a7f {1}
helpPages=Page \u00a7c{0}\u00a7f sur \u00a7c{1}\u00a7f.
-helpPlugin=\u00a74{0}\u00a7f: Plugin Help: /help {1}
+helpPlugin=\u00a74{0}\u00a7f: Aide Plugin : /help {1}
holeInFloor=Trou dans le Sol.
homeSet=\u00a77R\u00e9sidence d\u00e9finie.
homeSetToBed=\u00a77Votre r\u00e9sidence est d\u00e9sormais li\u00e9e \u00e0 ce lit.
@@ -147,8 +147,8 @@ invRestored=Votre inventaire vous a \u00e9t\u00e9 rendu.
invSee=Vous voyez l''inventaire de {0}.
invSeeHelp=Utilisez /invsee pour revenir \u00e0 votre inventaire.
invalidCharge=\u00a7cCharge invalide.
-invalidHome=Home {0} doesn't exist
-invalidMob=Mauvias type de cr\u00e9ature.
+invalidHome=La r\u00e9sidence {0} n'existe pas
+invalidMob=Mauvais type de cr\u00e9ature.
invalidServer=Serveur non valide.
invalidSignLine=La ligne {0} du panneau est invalide.
invalidWorld=\u00a7cMonde invalide.
@@ -173,11 +173,11 @@ jailNotExist=Cette prison n'existe pas.
jailReleased=\u00a77Joueur \u00a7e{0}\u00a77 lib\u00e9r\u00e9.
jailReleasedPlayerNotify=\u00a77Vous avez \u00e9t\u00e9 lib\u00e9r\u00e9 !
jailSentenceExtended=Dur\u00e9e d''emprisonnement rallong\u00e9e de : {0}
-jailSet=\u00a77La prison {0} a \u00e9t\u00e9 cr\u00e9\u00e9.
+jailSet=\u00a77La prison {0} a \u00e9t\u00e9 cr\u00e9\u00e9e.
jumpError=\u00c7a aurait pu faire mal au cerveau de votre ordinateur.
kickDefault=\u00c9ject\u00e9 du serveur
kickExempt=\u00a77Vous ne pouvez pas \u00e9jecter ce joueur.
-kickedAll=\u00a7cKicked all players from server
+kickedAll=\u00a7cTous les joueurs ont \u00e9t\u00e9 \u00e9ject\u00e9s
kill=\u00a77Tu\u00e9 {0}.
kitError2=\u00a7cCe kit n'existe pas ou a \u00e9t\u00e9 mal d\u00e9fini.
kitError=\u00a7cIl n'y a pas de kits valides.
@@ -193,14 +193,14 @@ listAmount = \u00a79Il y a \u00a7c{0}\u00a79 joueurs en ligne sur \u00a7c{1}\u00
listAmountHidden = \u00a79Il y a \u00a7c{0}\u00a77/{1}\u00a79 sur un maximum de \u00a7c{2}\u00a79 joueurs en ligne.
listGroupTag={0}\u00a7f:
listHiddenTag = \u00a77[MASQU\u00c9]\u00a7f
-loadWarpError=\u00c9chec du chargement du point de t\u00e9l\u00e9portation {0}.
-localFormat=Locale : <{0}> {1}
+loadWarpError=\u00c9chec du chargement du warp {0}.
+localFormat=Local : <{0}> {1}
mailClear=\u00a7cPour marquer votre courrier en tant que lu, entrez /mail clear
mailCleared=\u00a77Courrier supprim\u00e9 !
mailSent=\u00a77Courrier envoy\u00e9 !
markMailAsRead=\u00a7cPour marquer votre courrier en tant que lu, entrez /mail clear
markedAsAway=\u00a77Vous \u00eates d\u00e9sormais AFK.
-markedAsNotAway=\u00a77Vous n'\u00eates d\u00e9sormais plus AFK.
+markedAsNotAway=\u00a77Vous n'\u00eates plus AFK.
maxHomes=Vous ne pouvez pas cr\u00e9er plus de {0} r\u00e9sidences.
mayNotJail=\u00a7cVous ne pouvez pas emprisonner cette personne.
me=moi
@@ -213,7 +213,7 @@ mobSpawnLimit=Quantit\u00e9 de cr\u00e9atures limit\u00e9 \u00e0 au maximum du s
mobSpawnTarget=Le bloc cible doit \u00eatre un g\u00e9n\u00e9rateur de cr\u00e9atures.
mobsAvailable=\u00a77cr\u00e9atures : {0}
moneyRecievedFrom=\u00a7a{0} a \u00e9t\u00e9 re\u00e7u de {1}
-moneySentTo=\u00a7a{0} a \u00e9t\u00e9 envoy\u00e9 \u00e0 {1}
+moneySentTo=\u00a7a{0} ont \u00e9t\u00e9 envoy\u00e9s \u00e0 {1}
moneyTaken={0} pr\u00e9lev\u00e9(s) de votre compte.
month=mois
months=mois
@@ -233,12 +233,12 @@ nickNamesAlpha=\u00a7cLes surnoms doivent \u00eatre alphanum\u00e9riques.
nickNoMore=\u00a7 Vous n'avez plus de surnom.
nickOthersPermission=\u00a7cVous n'avez pas la permission de changer le surnom des autres.
nickSet=\u00a77Votre surnom est maintenant \u00a7c{0}
-noAccessCommand=\u00a7cVous n'avez pas acc\u00c3\u00a8s \u00e0 cette commande.
+noAccessCommand=\u00a7cVous n'avez pas acc\u00e8s \u00e0 cette commande.
noAccessPermission=\u00a7cVous n''avez pas la permissions d''acc\u00e9der \u00e0 cette {0}
-noBreakBedrock=You are not allowed to destroy bedrock.
+noBreakBedrock=Vous n'\u00eates pas autoris\u00e9s \u00e0 d\u00e9truire la bedrock.
noDestroyPermission=\u00a7cVous n''avez pas la permission de d\u00e9truire ce {0}.
-noDurability=\u00a7cThis item does not have a durability.
-noGodWorldWarning=\u00a7cWarning! Le mode Dieu est d\u00e9sactiv\u00e9 dans ce monde.
+noDurability=\u00a7cCet item n'a pas de durabilit\u00e9.
+noGodWorldWarning=\u00a7cAttention ! Le mode dieu est d\u00e9sactiv\u00e9 dans ce monde.
noHelpFound=\u00a7cAucune commande correspondante.
noHomeSet=Vous n'avez pas d\u00e9fini de r\u00e9sidence.
noHomeSetPlayer=Le joueur n'a pas d\u00e9fini sa r\u00e9sidence.
@@ -250,43 +250,43 @@ noNewMail=\u00a77Vous n'avez pas de courrier.
noPendingRequest=Vous n'avez pas de requ\u00eate non lue.
noPerm=\u00a7cVous n''avez pas la permission \u00a7f{0}\u00a7c.
noPermToSpawnMob=\u00a7cVous n'avez pas la permission d'invoquer cette cr\u00e9ature.
-noPlacePermission=\u00a7cVous n'avez pas la permission de placer un bloc pr\u00c3\u00a8 de cette pancarte.
+noPlacePermission=\u00a7cVous n'avez pas la permission de placer un bloc pr\u00e8s de cette pancarte.
noPowerTools=Vous n'avez pas d'outil macro associ\u00e9.
noRules=\u00a7cIl n'y a pas encore de r\u00e8gles d\u00e9finies.
-noWarpsDefined=Aucun point de t\u00e9l\u00e9portation d\u00e9fini.
+noWarpsDefined=Aucun warp d\u00e9fini.
none=aucun
notAllowedToQuestion=\u00a7cVous n'\u00eates pas autoris\u00e9 \u00e0 poser des questions.
notAllowedToShout=\u00a7cVous n'\u00eates pas autoris\u00e9 \u00e0 crier.
notEnoughExperience=Vous n'avez pas assez d'exp\u00e9rience.
notEnoughMoney=Vous n'avez pas les fonds n\u00e9cessaires.
notFlying=not flying
-notRecommendedBukkit=* ! * La version de Bukkit n'est pas celle qui est recommand\u00e9 pour cette version de Essentials.
+notRecommendedBukkit=* ! * Cette version de Bukkit n'est pas recommand\u00e9 pour cette version de Essentials.
notSupportedYet=Pas encore pris en charge.
nothingInHand = \u00a7cVous n'avez rien en main.
now=maintenant
nuke=Que la mort s'abatte sur eux !
-numberRequired=Il faut fournir un nombre ici.
+numberRequired=Un nombre est requis ici.
onlyDayNight=/time ne supporte que (jour) day/night (nuit).
-onlyPlayers=Seulement les joueurs en jeu peuvent utiliser {0}.
+onlyPlayers=Seuls les joueurs en jeu peuvent utiliser {0}.
onlySunStorm=/weather ne supporte que (soleil) sun/storm (temp\u00eate).
-orderBalances=Classement des balance de {0} utilisateurs, patientez ...
+orderBalances=Classement des soldes des {0} joueurs, patientez ...
pTimeCurrent=Pour \u00a7e{0}\u00a7f l''heure est {1}.
pTimeCurrentFixed=L''heure de \u00a7e{0}\u00a7f est fix\u00e9e \u00e0 {1}.
pTimeNormal=\u00a7fPour \u00a7e{0}\u00a7f l'heure est normale et correspond au server.
pTimeOthersPermission=\u00a7cVous n'etes pas autoris\u00e9 \u00e0 changer l'heure des autres joueurs.
-pTimePlayers=Ces joueurs ont leur propre horraire :
+pTimePlayers=Ces joueurs ont leur propre horaire :
pTimeReset=l''heure a \u00e9t\u00e9 r\u00e9initialis\u00e9e \u00e0 : \u00a7e{0}
pTimeSet=l''heure du joueur a \u00e9t\u00e9 r\u00e9egl\u00e9ee \u00e0 \u00a73{0}\u00a7f pour : \u00a7e{1}
pTimeSetFixed=l''heure du joueur a \u00e9t\u00e9 fix\u00e9e \u00e0 : \u00a7e{1}
parseError=Erreur de conversion {0} \u00e0 la ligne {1}
pendingTeleportCancelled=\u00a7cRequete de t\u00e9l\u00e9portation annul\u00e9e.
-permissionsError=Permissions/GroupManager manquant, les pr\u00e9fixes et suffixes ne seront pas affich\u00e9s.
+permissionsError=Permissions/GroupManager manquant, les pr\u00e9fixes et suffixes ne seront pas affich\u00e9s.
playerBanned=\u00a7cJoueur {0} banni {1} pour {2}
-playerInJail=\u00a7cLe joueur est d\u00e9j\u00e0 dans la prison {0}.
+playerInJail=\u00a7cLe joueur est d\u00e9j\u00e0 emprisonn\u00e9 dans {0}.
playerJailed=\u00a77Le joueur {0} a \u00e9t\u00e9 emprisonn\u00e9.
playerJailedFor=\u00a77{0} a \u00e9t\u00e9 emprisonn\u00e9 pour {1}.
playerKicked=\u00a7c{0} a \u00e9t\u00e9 \u00e9ject\u00e9 {1} pour {2}.
-playerMuted=\u00a77Vous avez \u00e9t\u00e9 r\u00e9duis au silence.
+playerMuted=\u00a77Vous avez \u00e9t\u00e9 r\u00e9duit au silence.
playerMutedFor=\u00a77Vous avez \u00e9t\u00e9 r\u00e9duis au silence pour {0}
playerNeverOnServer=\u00a7cLe joueur {0} n''a jamais \u00e9t\u00e9 sur le serveur.
playerNotFound=\u00a7cLe joueur est introuvable.
@@ -296,7 +296,7 @@ possibleWorlds=\u00a77Les mondes possibles sont les nombres de 0 \u00e0 {0}.
powerToolAir=La commande ne peut pas \u00eatre assign\u00e9e \u00e0 l'air.
powerToolAlreadySet=La commande \u00a7c{0}\u00a7f est d\u00e9j\u00e0 assign\u00e9e \u00e0 {1}.
powerToolAttach=Commande \u00a7c{0}\u00a7f assign\u00e9e \u00e0 {1}.
-powerToolClearAll=Toutes les commandes assign\u00e9es ont \u00e9et\u00e9e retir\u00e9ees.
+powerToolClearAll=Toutes les commandes assign\u00e9es ont \u00e9t\u00e9 retir\u00e9es.
powerToolList={1} assign\u00e9s aux commandes : \u00a7c{0}\u00a7f.
powerToolListEmpty={0} n'a pas de commande assign\u00e9e.
powerToolNoSuchCommandAssigned=La commande \u00a7c{0}\u00a7f n''a pas \u00e9t\u00e9 assign\u00e9e \u00e0 {1}.
@@ -313,42 +313,42 @@ repair=Vous avez r\u00e9par\u00e9 votre : \u00a7e{0}.
repairAlreadyFixed=\u00a77Cet objet n'a pas besoin de r\u00e9paration.
repairEnchanted=\u00a77Vous n'\u00eates pas autoris\u00e9 \u00e0 r\u00e9parer les objets enchant\u00e9s.
repairInvalidType=\u00a7cCet objet ne peut \u00eatre r\u00e9par\u00e9.
-repairNone=Aucun objet n'a besoin d'u00eatre r\u00e9par\u00e9.
+repairNone=Aucun objet n'a besoin d'\u00eatre r\u00e9par\u00e9.
requestAccepted=\u00a77Demande de t\u00e9l\u00e9portation accept\u00e9e.
requestAcceptedFrom=\u00a77{0} a accept\u00e9 votre demande de t\u00e9l\u00e9portation.
requestDenied=\u00a77Demande de t\u00e9l\u00e9portation refus\u00e9e.
requestDeniedFrom=\u00a77{0} a refus\u00e9 votre demande de t\u00e9l\u00e9portation.
requestSent=\u00a77Requ\u00eate envoy\u00e9e \u00e0 {0}\u00a77.
-requestTimedOut=\u00a7cLa de mande de t\u00e9l\u00e9portation a expir\u00e9.
-requiredBukkit=* ! * Vous avez besoin au moins de la version {0} de CraftBukkit. T\u00e9l\u00e9chargez-la ici http://dl.bukkit.org/downloads/craftbukkit/
+requestTimedOut=\u00a7cLa demande de t\u00e9l\u00e9portation a expir\u00e9.
+requiredBukkit=* ! * Vous avez au moins besoin de la version {0} de CraftBukkit. T\u00e9l\u00e9chargez-la ici http://dl.bukkit.org/downloads/craftbukkit/
returnPlayerToJailError=Error occurred when trying to return player {0} to jail: {1}
second=seconde
seconds=secondes
seenOffline=Le joueur {0} est hors ligne depuis {1}
seenOnline=Le joueur {0} est en ligne depuis {1}
serverFull=Le serveur est plein.
-serverTotal=Server Total: {0}
+serverTotal=Total du serveur : {0}
setSpawner=Type de g\u00e9n\u00e9rateur chang\u00e9 en {0}
-sheepMalformedColor=Couleur mal form\u00e9e.
+sheepMalformedColor=Couleur incorrecte.
shoutFormat=\u00a77[Crie]\u00a7f {0}
signFormatFail=\u00a74[{0}]
signFormatSuccess=\u00a71[{0}]
signFormatTemplate=[{0}]
signProtectInvalidLocation=\u00a74Vous n'avez pas l'autorisation de cr\u00e9er une pancarte ici.
-similarWarpExist=Un point de t\u00e9l\u00e9portation avec un nom similaire existe d\u00e9j\u00e0.
-slimeMalformedSize=Taille mal form\u00e9e.
-soloMob=Ce cr\u00e9ature aime \u00eatre seul.
+similarWarpExist=Un warp avec un nom similaire existe d\u00e9j\u00e0.
+slimeMalformedSize=Taille incorrecte.
+soloMob=Cette cr\u00e9ature pr\u00e9f\u00e8re \u00eatre seule.
spawnSet=\u00a77Le point de d\u00e9part a \u00e9t\u00e9 d\u00e9fini pour le groupe {0}.
spawned=invoqu\u00e9(s)
sudoExempt=You cannot sudo this user
-sudoRun=Forcing {0} to run: /{1} {2}
+sudoRun=Le joueur {0} ex\u00e9cute de force : /{1} {2}
suicideMessage=\u00a77Au revoir monde cruel...
suicideSuccess=\u00a77{0} s''est suicid\u00e9.
survival=survie
-takenFromAccount=\u00a7c{0} ont \u00e9t\u00e9 retir\u00e9 de votre compte.
-takenFromOthersAccount=\u00a7c{0} taken from {1}\u00a7c account. New balance: {2}
+takenFromAccount=\u00a7c{0} ont \u00e9t\u00e9 retir\u00e9s de votre compte.
+takenFromOthersAccount=\u00a7c{0} retir\u00e9s du compte de {1}\u00a7c. Nouveau solde : {2}
teleportAAll=\u00a77Demande de t\u00e9l\u00e9portation envoy\u00e9e \u00e0 tous les joueurs...
-teleportAll=\u00a77T\u00e9l\u00e9poration de tous les joueurs.
+teleportAll=\u00a77T\u00e9l\u00e9portation de tous les joueurs.
teleportAtoB=\u00a77{0}\u00a77 vous a t\u00e9l\u00e9port\u00e9 \u00e0 {1}\u00a77.
teleportDisabled={0} a la t\u00e9l\u00e9portation d\u00e9sactiv\u00e9.
teleportHereRequest=\u00a7c{0}\u00a7c Vous a demand\u00e9 de vous t\u00e9l\u00e9porter \u00e0 lui/elle.
@@ -357,9 +357,9 @@ teleportRequest=\u00a7c{0}\u00a7c vous demande s''il peut se t\u00e9l\u00e9porte
teleportRequestTimeoutInfo=\u00a77Cette demande de t\u00e9l\u00e9portation expirera dans {0} secondes.
teleportTop=\u00a77T\u00e9l\u00e9portation vers le haut.
teleportationCommencing=\u00a77D\u00e9but de la t\u00e9l\u00e9portation...
-teleportationDisabled=\u00a77T\u00e9l\u00e9poration d\u00e9sactiv\u00e9.
+teleportationDisabled=\u00a77T\u00e9l\u00e9portation d\u00e9sactiv\u00e9.
teleportationEnabled=\u00a77T\u00e9l\u00e9portation activ\u00e9e.
-teleporting=\u00a77T\u00e9l\u00e9poration en cours...
+teleporting=\u00a77T\u00e9l\u00e9portation en cours...
teleportingPortal=\u00a77T\u00e9l\u00e9portation via portail.
tempBanned=Banni temporairement du serveur pour {0}
tempbanExempt=\u00a77Vous ne pouvez pas bannir temporairement ce joueur.
@@ -373,12 +373,14 @@ timeSet=Heure r\u00e9gl\u00e9e dans tous les mondes.
timeSetPermission=\u00a7cVous n'\u00eates pas autoris\u00e9 \u00e0 r\u00e9gler l'heure.
timeWorldCurrent=Il est \u00a73{1}\u00a77 dans \u00a7c{0}.
timeWorldSet=L''heure a \u00e9t\u00e9 r\u00e9gl\u00e9e \u00e0 {0} dans : \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77\u00c9change termin\u00e9.
tradeSignEmpty=Le panneau de vente n'as pas encore assez de stock.
tradeSignEmptyOwner=Il n'y a rien \u00e0 collecter de cette pancarte d'\u00e9change commercial.
treeFailure=\u00a7cEchec de la g\u00e9n\u00e9ration de l'arbre. Essayez de nouveau sur de l'herbe ou de la terre.
-treeSpawned=\u00a77Arbre cr\u00e9\u00e9.
+treeSpawned=\u00a77Arbre cr\u00e9 \u00e9.
true=\u00a72true\u00a7f
typeTpaccept=\u00a77Pour le t\u00e9l\u00e9porter, utilisez \u00a7c/tpaccept\u00a77.
typeTpdeny=\u00a77Pour d\u00e9cliner cette demande, utilisez \u00a7c/tpdeny\u00a77.
@@ -391,55 +393,55 @@ unknownItemId=Num\u00e9ro d''objet inconnu : {0}
unknownItemInList=L''objet {0} est inconnu dans la liste {1}.
unknownItemName=Nom d''objet inconnu : {0}
unlimitedItemPermission=\u00a7cPas de permission pour l''objet illimit\u00e9 {0}.
-unlimitedItems=Objets illimit\u00e9s:
+unlimitedItems=Objets illimit\u00e9s :
unmutedPlayer=Le joueur {0} n''est plus muet.
unvanished=\u00a7aYou are once again visible.
unvanishedReload=\u00a7cA reload has forced you to become visible.
upgradingFilesError=Erreur durant la mise \u00e0 jour des fichiers.
userDoesNotExist=L''utilisateur {0} n''existe pas.
-userIsAway={0} s'est mis en AFK
+userIsAway={0} est d\u00e9sormais AFK
userIsNotAway={0} n'est plus AFK
userJailed=\u00a77Vous avez \u00e9t\u00e9 emprisonn\u00e9.
userUsedPortal={0} a utilis\u00e9 un portail existant.
userdataMoveBackError=Echec du d\u00e9placement de userdata/{0}.tmp vers userdata/{1}
userdataMoveError=Echec du d\u00e9placement de userdata/{0} vers userdata/{1}.tmp
usingTempFolderForTesting=Utilise un fichier temporaire pour un test.
-vanished=\u00a7aYou have now been vanished.
-versionMismatch=Versions diff\u00e9rentes ! Mettez s''il vous plait {0} \u00e0 la m\u00eame version.
-versionMismatchAll=Mauvaise version ! S'il vous plait mettez des jars Essentials de version identique.
+vanished=\u00a7aVous \u00eates d\u00e9sormais invisible.
+versionMismatch=Versions diff\u00e9rentes ! Veuillez mettre {0} \u00e0 la m\u00eame version.
+versionMismatchAll=Mauvaise version ! Veuillez mettre des jars Essentials de m\u00eame version.
voiceSilenced=\u00a77Vous avez \u00e9t\u00e9 r\u00e9duit au silence.
-walking=walking
-warpDeleteError=Probl\u00c3\u00a8me concernant la suppression du fichier warp.
+walking=en train de marcher
+warpDeleteError=Probl\u00e8me concernant la suppression du fichier warp.
warpListPermission=\u00a7cVous n'avez pas la permission d'afficher la liste des points de t\u00e9l\u00e9portation.
-warpNotExist=Ce point de t\u00e9l\u00e9portation n'existe pas.
-warpOverwrite=\u00a7cYou cannot overwrite that warp.
-warpSet=\u00a77Le point de t\u00e9l\u00e9portation {0} a \u00e9t\u00e9 cr\u00e9\u00e9.
-warpUsePermission=\u00a7cVous n'avez pas la permission d'utiliser ce point de t\u00e9l\u00e9portation.
+warpNotExist=Ce warp n'existe pas.
+warpOverwrite=\u00a7cVous ne pouvez pas \u00e9craser ce warp.
+warpSet=\u00a77Le warp {0} a \u00e9t\u00e9 cr\u00e9 \u00e9.
+warpUsePermission=\u00a7cVous n'avez pas la permission d'utiliser ce warp.
warpingTo=\u00a77T\u00e9l\u00e9portation vers {0}.
-warps=point de t\u00e9l\u00e9portations : {0}
-warpsCount=\u00a77Il y a {0} points de t\u00e9l\u00e9portations. Page {1} sur {2}.
+warps=warps : {0}
+warpsCount=\u00a77Il y a {0} warps. Page {1} sur {2}.
weatherStorm=\u00a77Vous avez programm\u00e9 l''orage dans {0}
weatherStormFor=\u00a77Vous avez programm\u00e9 l''orage dans {0} pour {1} secondes.
weatherSun=\u00a77Vous avez programm\u00e9 le beau temps dans {0}
weatherSunFor=\u00a77Vous avez programm\u00e9 le beau temps dans {0} pour {1} secondes.
-whoisAFK=\u00a76 - AFK:\u00a7f {0}
-whoisBanned=\u00a76 - Banni:\u00a7f {0}
-whoisExp=\u00a76 - Exp:\u00a7f {0} (Level {1})
-whoisFly=\u00a76 - Fly mode:\u00a7f {0} ({1})
-whoisGamemode=\u00a76 - Mode de jeu:\u00a7f {0}
-whoisGeoLocation=\u00a76 - Emplacement:\u00a7f {0}
-whoisGod=\u00a76 - Mode Dieu:\u00a7f {0}
-whoisHealth=\u00a76 - Sant\u00e9:\u00a7f {0} / 20
-whoisIPAddress=\u00a76 - Adresse IP:\u00a7f {0}
-whoisJail=\u00a76 - Jail:\u00a7f {0}
-whoisLocation=\u00a76 - Emplacement:\u00a7f ({0}, {1}, {2}, {3})
-whoisMoney=\u00a76 - Argent:\u00a7f {0}
-whoisMuted=\u00a76 - Muted:\u00a7f {0}
-whoisNick=\u00a76 - Nick:\u00a7f {0}
-whoisOp=\u00a76 - OP:\u00a7f {0}
+whoisAFK=\u00a76 - AFK :\u00a7f {0}
+whoisBanned=\u00a76 - Banni :\u00a7f {0}
+whoisExp=\u00a76 - Exp :\u00a7f {0} (Level {1})
+whoisFly=\u00a76 - Fly mode :\u00a7f {0} ({1})
+whoisGamemode=\u00a76 - Mode de jeu :\u00a7f {0}
+whoisGeoLocation=\u00a76 - Emplacement :\u00a7f {0}
+whoisGod=\u00a76 - Mode dieu :\u00a7f {0}
+whoisHealth=\u00a76 - Sant\u00e9 :\u00a7f {0} / 20
+whoisIPAddress=\u00a76 - Adresse IP :\u00a7f {0}
+whoisJail=\u00a76 - Jail :\u00a7f {0}
+whoisLocation=\u00a76 - Position :\u00a7f ({0}, {1}, {2}, {3})
+whoisMoney=\u00a76 - Argent :\u00a7f {0}
+whoisMuted=\u00a76 - Muet :\u00a7f {0}
+whoisNick=\u00a76 - Surnom :\u00a7f {0}
+whoisOp=\u00a76 - OP :\u00a7f {0}
whoisTop=\u00a76 ====== WhoIs:\u00a7f {0} \u00a76======
-worth=\u00a77Une pile de {0} vaut \u00a7c{1}\u00a77 ({2} objet(s) \u00e0 {3} chacun)
-worthMeta=\u00a77Une pile de {0} avec la m\u00e9tadonn\u00e9e de {1} vaut \u00a7c{2}\u00a77 ({3} objet(s) \u00e0 {4} chacun)
+worth=\u00a77Un stack de {0} vaut \u00a7c{1}\u00a77 ({2} objet(s) \u00e0 {3} chacun)
+worthMeta=\u00a77Un stack de {0} de type {1} vaut \u00a7c{2}\u00a77 ({3} objet(s) \u00e0 {4} chacun)
worthSet=Valeur cr\u00e9e
year=ann\u00e9e
years=ann\u00e9es
@@ -448,13 +450,19 @@ youHaveNewMail=\u00a7cVous avez {0} messages ! \u00a7fEntrez \u00a77/mail read\u
posX=\u00a76X: {0} (+East <-> -West)
posY=\u00a76Y: {0} (+Up <-> -Down)
posZ=\u00a76Z: {0} (+South <-> -North)
-posYaw=\u00a76Yaw: {0} (Rotation)
-posPitch=\u00a76Pitch: {0} (Head angle)
-distance=\u00a76Distance: {0}
+posYaw=\u00a76Yaw : {0} (Rotation)
+posPitch=\u00a76Pitch : {0} (Head angle)
+distance=\u00a76Distance : {0}
giveSpawn=\u00a76Giving\u00a7c {0} \u00a76of\u00a7c {1} to\u00a7c {2}\u00a76.
warpList={0}
-uptime=\u00a76Uptime:\u00a7c {0}
-antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
-antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
-gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
-invalidHomeName=\u00a74Invalid home name
+uptime=\u00a76Dur\u00e9e de fonctionnent :\u00a7c {0}
+antiBuildCraft=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 cr\u00e9er\u00a7c {0}\u00a74.
+antiBuildDrop=\u00a74Vous n'\u00eates pas autoris\u00e9s \u00e0 jeter\u00a7c {0}\u00a74.
+gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 portions, \u00a7c{3}\u00a76 entit\u00e9s
+invalidHomeName=\u00a74Nom de r\u00e9sindence invalide
+invalidWarpName=\u00a74Nom de warp invalide
+userUnknown=\u00a74Attention : Le joueur '\u00a7c{0}\u00a74' n'est jamais venu sur ce serveur.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_it.properties b/Essentials/src/messages_it.properties
index 91e2e8f27..f24899599 100644
--- a/Essentials/src/messages_it.properties
+++ b/Essentials/src/messages_it.properties
@@ -373,6 +373,8 @@ timeSet=Orario definito in tutti i mondi.
timeSetPermission=\u00a7cNon sei autorizzato a regolare l''orario.
timeWorldCurrent=L''orario attuale in {0} e'' \u00a73{1}
timeWorldSet=L''orario e'' stato regolato alle {0} in: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Affare concluso.
tradeSignEmpty=L''insegna non dispone di forniture sufficienti.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_nl.properties b/Essentials/src/messages_nl.properties
index 62be530f1..0c4fd2cd0 100644
--- a/Essentials/src/messages_nl.properties
+++ b/Essentials/src/messages_nl.properties
@@ -373,6 +373,8 @@ timeSet=Tijd ingesteld in alle werelden.
timeSetPermission=\u00a7cJe bent niet bevoegd om de tijd te veranderen.
timeWorldCurrent=De actuele tijd in {0} is \u00a73{1}
timeWorldSet=De tijd was veranderd naar {0} in: \u00a7c{1}
+totalWorthAll=\u00a7aAlle spullen verkocht voor een totale waarde van {1}.
+totalWorthBlocks=\u00a7aAlle blokken verkocht voor een totale waarde van {1}.
tps=Huidige TPS = {0}
tradeCompleted=\u00a77Ruil verricht.
tradeSignEmpty=Dit handelsbord heeft een te kleine voorraad.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_pl.properties b/Essentials/src/messages_pl.properties
index 1a1e73d65..804784f19 100644
--- a/Essentials/src/messages_pl.properties
+++ b/Essentials/src/messages_pl.properties
@@ -373,6 +373,8 @@ timeSet=Czas ustawiono we wszystkich swiatach.
timeSetPermission=\u00a7cNie masz uprawnien do ustawiania czasu.
timeWorldCurrent=Obecny czas {0} to \u00a73{1}.
timeWorldSet=Czas ustawiono {0} w: \u00a7c{1}.
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Handel zakonczono.
tradeSignEmpty=Tabliczka handlowa nie jest dostepna dla Ciebie.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_pt.properties b/Essentials/src/messages_pt.properties
index 11a2c1df0..4c039bc1c 100644
--- a/Essentials/src/messages_pt.properties
+++ b/Essentials/src/messages_pt.properties
@@ -373,6 +373,8 @@ timeSet=Horario definido em todos os mundos.
timeSetPermission=\u00a7cVoc\u00ea nao tem autoriza\u00e7ao para modificar o hor\u00e1rio.
timeWorldCurrent=O hor\u00e1rio atual no mundo {0} e \u00a73{1}
timeWorldSet=O hor\u00e1rio foi definido para {0} no: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Current TPS = {0}
tradeCompleted=\u00a77Compra concluida.
tradeSignEmpty=A placa de troca nao tem abastecimento suficiente.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/messages_se.properties b/Essentials/src/messages_se.properties
index c7685d6f4..b6017786b 100644
--- a/Essentials/src/messages_se.properties
+++ b/Essentials/src/messages_se.properties
@@ -373,6 +373,8 @@ timeSet=Tid inst\u00e4lld i alla v\u00e4rldar.
timeSetPermission=\u00a7cDu har inte tillst\u00e5nd att st\u00e4lla in tiden.
timeWorldCurrent=Den nuvarande tiden i {0} \u00e4r \u00a73{1}
timeWorldSet=Tiden \u00e4r nu {0} i: \u00a7c{1}
+totalWorthAll=\u00a7aSold all items and blocks for a total worth of {1}.
+totalWorthBlocks=\u00a7aSold all blocks for a total worth of {1}.
tps=Nuvarande TPS = {0}
tradeCompleted=\u00a77K\u00f6p avslutat.
tradeSignEmpty=K\u00f6pskylten har inget tillg\u00e4ngligt f\u00f6r dig.
@@ -458,3 +460,9 @@ antiBuildCraft=\u00a74You are not permitted to create\u00a7c {0}\u00a74.
antiBuildDrop=\u00a74You are not permitted to drop\u00a7c {0}\u00a74.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76": \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities
invalidHomeName=\u00a74Invalid home name
+invalidWarpName=\u00a74Invalid warp name
+userUnknown=\u00a74Warning: The user '\u00a7c{0}\u00a74' has never joined this server.
+teleportationEnabledFor=\u00a76Teleportation enabled for {0}
+teleportationDisabledFor=\u00a76Teleportation disabled for {0}
+kitOnce=\u00a74You can't use that kit again.
+fullStack=\u00a74You already have a full stack
diff --git a/Essentials/src/plugin.yml b/Essentials/src/plugin.yml
index 225534a08..95c7e943a 100644
--- a/Essentials/src/plugin.yml
+++ b/Essentials/src/plugin.yml
@@ -109,12 +109,8 @@ commands:
aliases: [efeed,eat,eeat]
fly:
description: Take off, and soar!
- usage: /<command> [player] [on|off]
+ usage: /<command> [player [on|off]]
aliases: [efly]
- itemdb:
- description: Searches for an item.
- usage: /<command> <item>
- aliases: [eitemdb,itemno,eitemno,durability,dura,edura,edurability]
fireball:
description: Throw a fireball.
usage: /<command> [small]
@@ -123,21 +119,21 @@ commands:
description: Change player gamemode.
usage: /<command> <survival|creative|adventure> [player]
aliases: [gm,creative,creativemode,survival,survivalmode,adventure,adventuremode,gmc,gma,gms,gmt,egamemod,eecreative,ecreativemode,esurvival,esurvivalmode,eadventure,eadventuremode,egmc,egma,egms,egm,egmt]
- getpos:
- description: Get your current coordinates or those of a player.
- usage: /<command> [player]
- aliases: [coords,egetpos,position,eposition,whereami,ewhereami]
gc:
description: Reports memory, uptime and tick info.
usage: /<command>
aliases: [elag,lag,mem,memory,egc,emem,ememory,uptime,euptime]
+ getpos:
+ description: Get your current coordinates or those of a player.
+ usage: /<command> [player]
+ aliases: [coords,egetpos,position,eposition,whereami,ewhereami]
give:
description: Give a player an item.
usage: /<command> <player> <item|numeric> [amount <enchantmentname[:level]> ...]
aliases: [egive]
god:
description: Enables your godly powers.
- usage: /<command> [player] [on|off]
+ usage: /<command> [player [on|off]]
aliases: [tgm,godmode,egod,etgm,egodmode]
hat:
description: Get some cool new headgear
@@ -175,6 +171,10 @@ commands:
description: Spawn an item.
usage: /<command> <item|numeric> [amount <enchantmentname[:level]> ...]
aliases: [i,eitem]
+ itemdb:
+ description: Searches for an item.
+ usage: /<command> <item>
+ aliases: [eitemdb,itemno,eitemno,durability,dura,edura,edurability]
jails:
description: List all jails.
usage: /<command>
@@ -191,10 +191,6 @@ commands:
description: Kicks all players off the server except the issuer.
usage: /<command> [reason]
aliases: [ekickall]
- kit:
- description: Obtains the specified kit or views all available kits.
- usage: /<command> [kit] [player]
- aliases: [ekit,kits,ekits]
kill:
description: Kills specified player.
usage: /<command> <player>
@@ -203,17 +199,21 @@ commands:
description: Kill all mobs in a world.
usage: /<command> [mobType] [radius]
aliases: [ekillall,butcher,ebutcher,mobkill,emobkill]
+ kit:
+ description: Obtains the specified kit or views all available kits.
+ usage: /<command> [kit] [player]
+ aliases: [ekit,kits,ekits]
kittycannon:
description: Throw an exploding kitten at your opponent
usage: /<command>
- list:
- description: List all online players.
- usage: /<command>
- aliases: [playerlist,who,online,plist,eplist,elist,ewho,eplayerlist,eonline]
lightning:
description: The power of Thor. Strike at cursor or player.
usage: /<command> [player] [power]
aliases: [strike,smite,thor,shock,elightning,estrike,esmite,ethor,eshock]
+ list:
+ description: List all online players.
+ usage: /<command>
+ aliases: [playerlist,who,online,plist,eplist,elist,ewho,eplayerlist,eonline]
mail:
description: Manages inter-player, intra-server mail.
usage: /<command> [read|clear|send [to] [message]|sendall [message]]
@@ -404,7 +404,7 @@ commands:
aliases: [etppos]
tptoggle:
description: Blocks all forms of teleportation.
- usage: /<command>
+ usage: /<command> [player [on|off]]
aliases: [etptoggle]
tree:
description: Spawn a tree where you are looking.
diff --git a/Essentials/test/com/earth2me/essentials/FakeServer.java b/Essentials/test/com/earth2me/essentials/FakeServer.java
index c86068eb8..e8b8ce01c 100644
--- a/Essentials/test/com/earth2me/essentials/FakeServer.java
+++ b/Essentials/test/com/earth2me/essentials/FakeServer.java
@@ -119,6 +119,12 @@ public class FakeServer implements Server
}
@Override
+ public boolean isHardcore()
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
public Player getPlayer(String string)
{
for (Player player : players)
@@ -240,6 +246,42 @@ public class FakeServer implements Server
{
throw new UnsupportedOperationException("Not supported yet.");
}
+
+ @Override
+ public BukkitTask runTask(Plugin plugin, Runnable r) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public BukkitTask runTaskAsynchronously(Plugin plugin, Runnable r) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public BukkitTask runTaskLater(Plugin plugin, Runnable r, long l) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public BukkitTask runTaskLaterAsynchronously(Plugin plugin, Runnable r, long l) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public BukkitTask runTaskTimer(Plugin plugin, Runnable r, long l, long l1) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
+
+ @Override
+ public BukkitTask runTaskTimerAsynchronously(Plugin plugin, Runnable r, long l, long l1) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
};
}
@@ -759,4 +801,10 @@ public class FakeServer implements Server
{
throw new UnsupportedOperationException("Not supported yet.");
}
+
+ @Override
+ public int getAmbientSpawnLimit()
+ {
+ throw new UnsupportedOperationException("Not supported yet.");
+ }
}
diff --git a/EssentialsAntiBuild/nbproject/build-impl.xml b/EssentialsAntiBuild/nbproject/build-impl.xml
index fd7175255..94e589ef7 100644
--- a/EssentialsAntiBuild/nbproject/build-impl.xml
+++ b/EssentialsAntiBuild/nbproject/build-impl.xml
@@ -12,9 +12,9 @@ is divided into following sections:
- execution
- debugging
- javadoc
- - junit compilation
- - junit execution
- - junit debugging
+ - test compilation
+ - test execution
+ - test debugging
- applet
- cleanup
@@ -181,6 +181,7 @@ is divided into following sections:
</and>
</condition>
<property name="run.jvmargs" value=""/>
+ <property name="run.jvmargs.ide" value=""/>
<property name="javac.compilerargs" value=""/>
<property name="work.dir" value="${basedir}"/>
<condition property="no.deps">
@@ -225,6 +226,27 @@ is divided into following sections:
<property name="jar.index.metainf" value="${jar.index}"/>
<property name="copylibs.rebase" value="true"/>
<available file="${meta.inf.dir}/persistence.xml" property="has.persistence.xml"/>
+ <condition property="junit.available">
+ <or>
+ <available classname="org.junit.Test" classpath="${run.test.classpath}"/>
+ <available classname="junit.framework.Test" classpath="${run.test.classpath}"/>
+ </or>
+ </condition>
+ <condition property="testng.available">
+ <available classname="org.testng.annotations.Test" classpath="${run.test.classpath}"/>
+ </condition>
+ <condition property="junit+testng.available">
+ <and>
+ <istrue value="${junit.available}"/>
+ <istrue value="${testng.available}"/>
+ </and>
+ </condition>
+ <condition else="testng" property="testng.mode" value="mixed">
+ <istrue value="${junit+testng.available}"/>
+ </condition>
+ <condition else="" property="testng.debug.mode" value="-mixed">
+ <istrue value="${junit+testng.available}"/>
+ </condition>
</target>
<target name="-post-init">
<!-- Empty placeholder for easier customization. -->
@@ -357,11 +379,52 @@ is divided into following sections:
</sequential>
</macrodef>
</target>
- <target name="-init-macrodef-junit">
+ <target if="${junit.available}" name="-init-macrodef-junit-init">
+ <condition else="false" property="nb.junit.batch" value="true">
+ <and>
+ <istrue value="${junit.available}"/>
+ <not>
+ <isset property="test.method"/>
+ </not>
+ </and>
+ </condition>
+ <condition else="false" property="nb.junit.single" value="true">
+ <and>
+ <istrue value="${junit.available}"/>
+ <isset property="test.method"/>
+ </and>
+ </condition>
+ </target>
+ <target if="${nb.junit.single}" name="-init-macrodef-junit-single" unless="${nb.junit.batch}">
+ <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
<attribute default="${includes}" name="includes"/>
<attribute default="${excludes}" name="excludes"/>
<attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
<sequential>
<property name="junit.forkmode" value="perTest"/>
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
@@ -370,32 +433,270 @@ is divided into following sections:
<filename name="@{testincludes}"/>
</fileset>
</batchtest>
- <classpath>
- <path path="${run.test.classpath}"/>
- </classpath>
<syspropertyset>
<propertyref prefix="test-sys-prop."/>
<mapper from="test-sys-prop.*" to="*" type="glob"/>
</syspropertyset>
<formatter type="brief" usefile="false"/>
<formatter type="xml"/>
- <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
<jvmarg value="-ea"/>
- <jvmarg line="${run.jvmargs}"/>
+ <customize/>
</junit>
</sequential>
</macrodef>
</target>
- <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile, -profile-init-check" name="profile-init"/>
- <target name="-profile-pre-init">
+ <target depends="-init-macrodef-junit-init,-init-macrodef-junit-single, -init-macrodef-junit-batch" if="${junit.available}" name="-init-macrodef-junit"/>
+ <target if="${testng.available}" name="-init-macrodef-testng">
+ <macrodef name="testng" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <condition else="" property="testng.methods.arg" value="@{testincludes}.@{testmethods}">
+ <isset property="test.method"/>
+ </condition>
+ <union id="test.set">
+ <fileset dir="${test.src.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
+ <filename name="@{testincludes}"/>
+ </fileset>
+ </union>
+ <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
+ <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="EssentialsAntiBuild" testname="TestNG tests" workingDir="${work.dir}">
+ <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
+ <propertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </propertyset>
+ <customize/>
+ </testng>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-test-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <echo>No tests executed.</echo>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit" if="${junit.available}" name="-init-macrodef-junit-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:junit excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng" if="${testng.available}" name="-init-macrodef-testng-impl">
+ <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:testng excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:testng>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-test-impl,-init-macrodef-junit-impl,-init-macrodef-testng-impl" name="-init-macrodef-test">
+ <macrodef name="test" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <sequential>
+ <j2seproject3:test-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
+ </customize>
+ </j2seproject3:test-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${junit.available}" name="-init-macrodef-junit-debug" unless="${nb.junit.batch}">
+ <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">
+ <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property name="junit.forkmode" value="perTest"/>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+ <batchtest todir="${build.test.results.dir}">
+ <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
+ <filename name="@{testincludes}"/>
+ </fileset>
+ </batchtest>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg value="-ea"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <customize/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit-debug,-init-macrodef-junit-debug-batch" if="${junit.available}" name="-init-macrodef-junit-debug-impl">
+ <macrodef name="test-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <element implicit="true" name="customize" optional="true"/>
+ <sequential>
+ <j2seproject3:junit-debug excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize/>
+ </j2seproject3:junit-debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target if="${testng.available}" name="-init-macrodef-testng-debug">
+ <macrodef name="testng-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <element name="customize2" optional="true"/>
+ <sequential>
+ <condition else="-testclass @{testClass}" property="test.class.or.method" value="-methods @{testClass}.@{testMethod}">
+ <isset property="test.method"/>
+ </condition>
+ <condition else="-suitename EssentialsAntiBuild -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">
+ <matches pattern=".*\.xml" string="@{testClass}"/>
+ </condition>
+ <delete dir="${build.test.results.dir}" quiet="true"/>
+ <mkdir dir="${build.test.results.dir}"/>
+ <j2seproject3:debug classname="org.testng.TestNG" classpath="${debug.test.classpath}">
+ <customize>
+ <customize2/>
+ <jvmarg value="-ea"/>
+ <arg line="${testng.debug.mode}"/>
+ <arg line="-d ${build.test.results.dir}"/>
+ <arg line="-listener org.testng.reporters.VerboseReporter"/>
+ <arg line="${testng.cmd.args}"/>
+ </customize>
+ </j2seproject3:debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng-debug" if="${testng.available}" name="-init-macrodef-testng-debug-impl">
+ <macrodef name="testng-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <element implicit="true" name="customize2" optional="true"/>
+ <sequential>
+ <j2seproject3:testng-debug testClass="@{testClass}" testMethod="@{testMethod}">
+ <customize2/>
+ </j2seproject3:testng-debug>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-junit-debug-impl" if="${junit.available}" name="-init-macrodef-test-debug-junit">
+ <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <sequential>
+ <j2seproject3:test-debug-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
+ <customize>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
+ </customize>
+ </j2seproject3:test-debug-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-testng-debug-impl" if="${testng.available}" name="-init-macrodef-test-debug-testng">
+ <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <attribute default="" name="testmethods"/>
+ <attribute default="${main.class}" name="testClass"/>
+ <attribute default="" name="testMethod"/>
+ <sequential>
+ <j2seproject3:testng-debug-impl testClass="@{testClass}" testMethod="@{testMethod}">
+ <customize2>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ </customize2>
+ </j2seproject3:testng-debug-impl>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-macrodef-test-debug-junit,-init-macrodef-test-debug-testng" name="-init-macrodef-test-debug"/>
+ <!--
+ pre NB7.2 profiling section; consider it deprecated
+ -->
+ <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile, -profile-init-check" if="profiler.info.jvmargs.agent" name="profile-init"/>
+ <target if="profiler.info.jvmargs.agent" name="-profile-pre-init">
<!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. -->
</target>
- <target name="-profile-post-init">
+ <target if="profiler.info.jvmargs.agent" name="-profile-post-init">
<!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. -->
</target>
- <target name="-profile-init-macrodef-profile">
+ <target if="profiler.info.jvmargs.agent" name="-profile-init-macrodef-profile">
<macrodef name="resolve">
<attribute name="name"/>
<attribute name="value"/>
@@ -427,10 +728,13 @@ is divided into following sections:
</sequential>
</macrodef>
</target>
- <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile" name="-profile-init-check">
+ <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile" if="profiler.info.jvmargs.agent" name="-profile-init-check">
<fail unless="profiler.info.jvm">Must set JVM to use for profiling in profiler.info.jvm</fail>
<fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail>
</target>
+ <!--
+ end of pre NB7.2 profiling section
+ -->
<target depends="-init-debug-args" name="-init-macrodef-nbjpda">
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
<attribute default="${main.class}" name="name"/>
@@ -488,6 +792,7 @@ is divided into following sections:
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
<jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
<classpath>
<path path="@{classpath}"/>
</classpath>
@@ -504,6 +809,7 @@ is divided into following sections:
<macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
<attribute default="${main.class}" name="classname"/>
<attribute default="${run.classpath}" name="classpath"/>
+ <attribute default="jvm" name="jvm"/>
<element name="customize" optional="true"/>
<sequential>
<java classname="@{classname}" dir="${work.dir}" fork="true">
@@ -511,6 +817,7 @@ is divided into following sections:
<jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
<redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
<jvmarg line="${run.jvmargs}"/>
+ <jvmarg line="${run.jvmargs.ide}"/>
<classpath>
<path path="@{classpath}"/>
</classpath>
@@ -537,6 +844,9 @@ is divided into following sections:
<path path="${run.classpath.without.build.classes.dir}"/>
<chainedmapper>
<flattenmapper/>
+ <filtermapper>
+ <replacestring from=" " to="%20"/>
+ </filtermapper>
<globmapper from="*" to="lib/*"/>
</chainedmapper>
</pathconvert>
@@ -582,7 +892,7 @@ is divided into following sections:
<target depends="-init-ap-cmdline-properties,-init-ap-cmdline-supported" name="-init-ap-cmdline">
<property name="ap.cmd.line.internal" value=""/>
</target>
- <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/>
+ <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-test,-init-macrodef-test-debug,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/>
<!--
===================
COMPILATION SECTION
@@ -805,7 +1115,11 @@ is divided into following sections:
PROFILING SECTION
=================
-->
- <target depends="profile-init,compile" description="Profile a project in the IDE." if="netbeans.home" name="profile">
+ <!--
+ pre NB7.2 profiler integration
+ -->
+ <target depends="profile-init,compile" description="Profile a project in the IDE." if="profiler.info.jvmargs.agent" name="-profile-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -813,8 +1127,9 @@ is divided into following sections:
</nbprofiledirect>
<profile/>
</target>
- <target depends="profile-init,compile-single" description="Profile a selected class in the IDE." if="netbeans.home" name="profile-single">
+ <target depends="profile-init,compile-single" description="Profile a selected class in the IDE." if="profiler.info.jvmargs.agent" name="-profile-single-pre72">
<fail unless="profile.class">Must select one file in the IDE or set profile.class</fail>
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -822,12 +1137,8 @@ is divided into following sections:
</nbprofiledirect>
<profile classname="${profile.class}"/>
</target>
- <!--
- =========================
- APPLET PROFILING SECTION
- =========================
- -->
- <target depends="profile-init,compile-single" if="netbeans.home" name="profile-applet">
+ <target depends="profile-init,compile-single" if="profiler.info.jvmargs.agent" name="-profile-applet-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.classpath}"/>
@@ -839,12 +1150,8 @@ is divided into following sections:
</customize>
</profile>
</target>
- <!--
- =========================
- TESTS PROFILING SECTION
- =========================
- -->
- <target depends="profile-init,compile-test-single" if="netbeans.home" name="profile-test-single">
+ <target depends="profile-init,compile-test-single" if="profiler.info.jvmargs.agent" name="-profile-test-single-pre72">
+ <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
<nbprofiledirect>
<classpath>
<path path="${run.test.classpath}"/>
@@ -867,6 +1174,42 @@ is divided into following sections:
</junit>
</target>
<!--
+ end of pre NB72 profiling section
+ -->
+ <target if="netbeans.home" name="-profile-check">
+ <condition property="profiler.configured">
+ <or>
+ <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-agentpath:"/>
+ <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-javaagent:"/>
+ </or>
+ </condition>
+ </target>
+ <target depends="-profile-check,-profile-pre72" description="Profile a project in the IDE." if="profiler.configured" name="profile" unless="profiler.info.jvmargs.agent">
+ <startprofiler/>
+ <antcall target="run"/>
+ </target>
+ <target depends="-profile-check,-profile-single-pre72" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-single" unless="profiler.info.jvmargs.agent">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <startprofiler/>
+ <antcall target="run-single"/>
+ </target>
+ <target depends="-profile-test-single-pre72" description="Profile a selected test in the IDE." name="profile-test-single"/>
+ <target depends="-profile-check" description="Profile a selected test in the IDE." if="profiler.configured" name="profile-test" unless="profiler.info.jvmargs">
+ <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
+ <startprofiler/>
+ <antcall target="test-single"/>
+ </target>
+ <target depends="-profile-check" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-test-with-main">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <startprofiler/>
+ <antcal target="run-test-with-main"/>
+ </target>
+ <target depends="-profile-check,-profile-applet-pre72" if="profiler.configured" name="profile-applet" unless="profiler.info.jvmargs.agent">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <startprofiler/>
+ <antcall target="run-applet"/>
+ </target>
+ <!--
===============
JAVADOC SECTION
===============
@@ -909,7 +1252,7 @@ is divided into following sections:
<target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
<!--
=========================
- JUNIT COMPILATION SECTION
+ TEST COMPILATION SECTION
=========================
-->
<target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
@@ -952,14 +1295,14 @@ is divided into following sections:
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
<!--
=======================
- JUNIT EXECUTION SECTION
+ TEST EXECUTION SECTION
=======================
-->
<target depends="init" if="have.tests" name="-pre-test-run">
<mkdir dir="${build.test.results.dir}"/>
</target>
<target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
- <j2seproject3:junit testincludes="**/*Test.java"/>
+ <j2seproject3:test testincludes="**/*Test.java"/>
</target>
<target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
@@ -972,39 +1315,40 @@ is divided into following sections:
</target>
<target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
- <j2seproject3:junit excludes="" includes="${test.includes}"/>
+ <j2seproject3:test excludes="" includes="${test.includes}" testincludes="${test.includes}"/>
</target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
<fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
</target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single-method">
+ <fail unless="test.class">Must select some files in the IDE or set test.class</fail>
+ <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
+ <j2seproject3:test excludes="" includes="${javac.includes}" testincludes="${test.class}" testmethods="${test.method}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method" if="have.tests" name="-post-test-run-single-method">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method,-post-test-run-single-method" description="Run single unit test." name="test-single-method"/>
<!--
=======================
- JUNIT DEBUGGING SECTION
+ TEST DEBUGGING SECTION
=======================
-->
- <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test">
<fail unless="test.class">Must select one file in the IDE or set test.class</fail>
- <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
- <delete file="${test.report.file}"/>
- <mkdir dir="${build.test.results.dir}"/>
- <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
- <customize>
- <syspropertyset>
- <propertyref prefix="test-sys-prop."/>
- <mapper from="test-sys-prop.*" to="*" type="glob"/>
- </syspropertyset>
- <arg value="${test.class}"/>
- <arg value="showoutput=true"/>
- <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
- <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
- </customize>
- </j2seproject3:debug>
+ <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testincludes="${javac.includes}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test-method">
+ <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
+ <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
+ <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testMethod="${test.method}" testincludes="${test.class}" testmethods="${test.method}"/>
</target>
<target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
<j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
</target>
<target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
+ <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test-method" name="debug-test-method"/>
<target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
<j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
</target>
@@ -1076,9 +1420,12 @@ is divided into following sections:
<target name="-check-call-dep">
<property file="${call.built.properties}" prefix="already.built."/>
<condition property="should.call.dep">
- <not>
- <isset property="already.built.${call.subproject}"/>
- </not>
+ <and>
+ <not>
+ <isset property="already.built.${call.subproject}"/>
+ </not>
+ <available file="${call.script}"/>
+ </and>
</condition>
</target>
<target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">
diff --git a/EssentialsAntiBuild/nbproject/genfiles.properties b/EssentialsAntiBuild/nbproject/genfiles.properties
index 61188645c..ed84f2f67 100644
--- a/EssentialsAntiBuild/nbproject/genfiles.properties
+++ b/EssentialsAntiBuild/nbproject/genfiles.properties
@@ -4,5 +4,5 @@ build.xml.stylesheet.CRC32=28e38971@1.38.3.45
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
nbproject/build-impl.xml.data.CRC32=ddb4519c
-nbproject/build-impl.xml.script.CRC32=cfb9443d
-nbproject/build-impl.xml.stylesheet.CRC32=fcddb364@1.50.3.46
+nbproject/build-impl.xml.script.CRC32=00e1454b
+nbproject/build-impl.xml.stylesheet.CRC32=6ddba6b6@1.53.1.46
diff --git a/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java b/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java
index d2f46586f..7e5c60476 100644
--- a/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java
+++ b/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java
@@ -36,6 +36,10 @@ public class EssentialsAntiBuildListener implements Listener
{
if (block == null)
{
+ if (ess.getSettings().isDebug())
+ {
+ ess.getLogger().log(Level.INFO, "AntiBuild permission check failed, invalid block.");
+ }
return false;
}
return metaPermCheck(user, action, block.getTypeId(), block.getData());
@@ -47,7 +51,7 @@ public class EssentialsAntiBuildListener implements Listener
return user.isAuthorized(blockPerm);
}
- private boolean metaPermCheck(final User user, final String action, final int blockId, final byte data)
+ private boolean metaPermCheck(final User user, final String action, final int blockId, final short data)
{
final String blockPerm = "essentials.build." + action + "." + blockId;
final String dataPerm = blockPerm + ":" + data;
@@ -215,7 +219,7 @@ public class EssentialsAntiBuildListener implements Listener
if (prot.getSettingBool(AntiBuildConfig.disable_use) && !user.canBuild() && !user.isAuthorized("essentials.build"))
{
- if (event.hasItem() && !metaPermCheck(user, "interact", item.getTypeId(), item.getData().getData()))
+ if (event.hasItem() && !metaPermCheck(user, "interact", item.getTypeId(), item.getDurability()))
{
event.setCancelled(true);
if (ess.getSettings().warnOnBuildDisallow())
@@ -247,7 +251,7 @@ public class EssentialsAntiBuildListener implements Listener
if (prot.getSettingBool(AntiBuildConfig.disable_use) && !user.canBuild() && !user.isAuthorized("essentials.build"))
{
- if (!metaPermCheck(user, "craft", item.getTypeId(), item.getData().getData()))
+ if (!metaPermCheck(user, "craft", item.getTypeId(), item.getDurability()))
{
event.setCancelled(true);
if (ess.getSettings().warnOnBuildDisallow())
@@ -268,7 +272,7 @@ public class EssentialsAntiBuildListener implements Listener
if (prot.getSettingBool(AntiBuildConfig.disable_use) && !user.canBuild() && !user.isAuthorized("essentials.build"))
{
- if (!metaPermCheck(user, "pickup", item.getTypeId(), item.getData().getData()))
+ if (!metaPermCheck(user, "pickup", item.getTypeId(), item.getDurability()))
{
event.setCancelled(true);
event.getItem().setPickupDelay(50);
@@ -285,7 +289,7 @@ public class EssentialsAntiBuildListener implements Listener
if (prot.getSettingBool(AntiBuildConfig.disable_use) && !user.canBuild() && !user.isAuthorized("essentials.build"))
{
- if (!metaPermCheck(user, "drop", item.getTypeId(), item.getData().getData()))
+ if (!metaPermCheck(user, "drop", item.getTypeId(), item.getDurability()))
{
event.setCancelled(true);
user.updateInventory();
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
index f38f91b8e..fe7808238 100644
--- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
+++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
@@ -389,6 +389,11 @@ public class GroupManager extends JavaPlugin {
return true;
}
+ if (sender.getClass().getName().equals("org.bukkit.craftbukkit.command.CraftBlockCommandSender")) {
+ sender.sendMessage(ChatColor.RED + "GM Commands can not be called from CommandBlocks");
+ return true;
+ }
+
// DETERMINING PLAYER INFORMATION
if (sender instanceof Player) {
senderPlayer = (Player) sender;
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtect.java b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtect.java
index 06dc03656..0ccf6917f 100644
--- a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtect.java
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtect.java
@@ -1,9 +1,11 @@
package com.earth2me.essentials.protect;
import com.earth2me.essentials.protect.data.IProtectedBlock;
+import com.mchange.v2.log.MLevel;
import java.util.EnumMap;
import java.util.List;
import java.util.Map;
+import java.util.Properties;
import java.util.logging.Filter;
import java.util.logging.Level;
import java.util.logging.LogRecord;
@@ -27,14 +29,20 @@ public class EssentialsProtect extends JavaPlugin implements IProtect
@Override
public void onLoad()
{
- C3P0logger = com.mchange.v2.log.MLog.getLogger(com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.class);
- C3P0logger.setFilter(new Filter()
+ try
+ {
+ // Simple fix for the case that log4j is on the class path by another plugin
+ Class propertyConfiguratorClass = Class.forName("org.apache.log4j.PropertyConfigurator");
+ Properties properties = new Properties();
+ properties.load(this.getClass().getResourceAsStream("log4j.properties"));
+ propertyConfiguratorClass.getMethod("configure", Properties.class).invoke(null, properties);
+ }
+ catch (Exception ex)
{
- public boolean isLoggable(LogRecord lr)
- {
- return lr.getLevel() != Level.INFO;
- }
- });
+ //Ignore me, log4j not found on classloader.
+ }
+ C3P0logger = com.mchange.v2.log.MLog.getLogger(com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.class);
+ C3P0logger.setLevel(MLevel.WARNING);
}
public void onEnable()
@@ -65,7 +73,7 @@ public class EssentialsProtect extends JavaPlugin implements IProtect
{
final EmergencyListener emListener = new EmergencyListener();
pm.registerEvents(emListener, this);
-
+
for (Player player : getServer().getOnlinePlayers())
{
player.sendMessage("Essentials Protect is in emergency mode. Check your log for errors.");
@@ -89,7 +97,7 @@ public class EssentialsProtect extends JavaPlugin implements IProtect
{
return ess;
}
-
+
public Map<ProtectConfig, Boolean> getSettingsBoolean()
{
return settingsBoolean;
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java
index ef556c9bd..1ca9519ce 100644
--- a/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/EssentialsProtectEntityListener.java
@@ -10,9 +10,9 @@ import org.bukkit.entity.*;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
+import org.bukkit.event.entity.*;
import org.bukkit.event.entity.EntityDamageEvent.DamageCause;
import org.bukkit.event.entity.EntityTargetEvent.TargetReason;
-import org.bukkit.event.entity.*;
public class EssentialsProtectEntityListener implements Listener
@@ -38,33 +38,27 @@ public class EssentialsProtectEntityListener implements Listener
}
final User user = ess.getUser(target);
+ final DamageCause cause = event.getCause();
+
if (event instanceof EntityDamageByBlockEvent)
{
- final DamageCause cause = event.getCause();
-
if (prot.getSettingBool(ProtectConfig.disable_contactdmg)
&& cause == DamageCause.CONTACT
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.contact")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !(target instanceof Player && shouldBeDamaged(user, "contact")))
{
event.setCancelled(true);
return;
}
if (prot.getSettingBool(ProtectConfig.disable_lavadmg)
&& cause == DamageCause.LAVA
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.lava")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !(target instanceof Player && shouldBeDamaged(user, "lava")))
{
event.setCancelled(true);
return;
}
if (prot.getSettingBool(ProtectConfig.prevent_tnt_explosion)
&& cause == DamageCause.BLOCK_EXPLOSION
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.tnt")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !(target instanceof Player && shouldBeDamaged(user, "tnt")))
{
event.setCancelled(true);
return;
@@ -77,48 +71,43 @@ public class EssentialsProtectEntityListener implements Listener
final Entity eAttack = edEvent.getDamager();
final User attacker = ess.getUser(eAttack);
- // PVP Settings
- if (target instanceof Player && eAttack instanceof Player
- && prot.getSettingBool(ProtectConfig.disable_pvp)
- && (!user.isAuthorized("essentials.protect.pvp") || !attacker.isAuthorized("essentials.protect.pvp")))
+ //Creeper explode prevention
+ if (eAttack instanceof Creeper
+ && (prot.getSettingBool(ProtectConfig.prevent_creeper_explosion)
+ || prot.getSettingBool(ProtectConfig.prevent_creeper_playerdmg))
+ && !(target instanceof Player && shouldBeDamaged(user, "creeper")))
{
event.setCancelled(true);
return;
}
- //Creeper explode prevention
- if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_explosion)
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.creeper")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ if ((event.getEntity() instanceof Fireball || event.getEntity() instanceof SmallFireball)
+ && prot.getSettingBool(ProtectConfig.prevent_fireball_playerdmg)
+ && !(target instanceof Player && shouldBeDamaged(user, "fireball")))
{
event.setCancelled(true);
return;
}
- if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_playerdmg)
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.creeper")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ if (event.getEntity() instanceof WitherSkull
+ && prot.getSettingBool(ProtectConfig.prevent_witherskull_playerdmg)
+ && !(target instanceof Player && shouldBeDamaged(user, "witherskull")))
{
event.setCancelled(true);
return;
}
- if ((event.getEntity() instanceof Fireball || event.getEntity() instanceof SmallFireball)
- && prot.getSettingBool(ProtectConfig.prevent_fireball_playerdmg)
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.fireball")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ if (eAttack instanceof TNTPrimed && prot.getSettingBool(ProtectConfig.prevent_tnt_playerdmg)
+ && !(target instanceof Player && shouldBeDamaged(user, "tnt")))
{
event.setCancelled(true);
return;
}
- if (eAttack instanceof TNTPrimed && prot.getSettingBool(ProtectConfig.prevent_tnt_playerdmg)
- && !(target instanceof Player
- && user.isAuthorized("essentials.protect.damage.tnt")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ // PVP Settings
+ if (target instanceof Player && eAttack instanceof Player
+ && prot.getSettingBool(ProtectConfig.disable_pvp)
+ && (!user.isAuthorized("essentials.protect.pvp") || !attacker.isAuthorized("essentials.protect.pvp")))
{
event.setCancelled(true);
return;
@@ -126,9 +115,7 @@ public class EssentialsProtectEntityListener implements Listener
if (edEvent.getDamager() instanceof Projectile
&& target instanceof Player
- && ((prot.getSettingBool(ProtectConfig.disable_projectiles)
- && !(user.isAuthorized("essentials.protect.damage.projectiles")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && ((prot.getSettingBool(ProtectConfig.disable_projectiles) && !shouldBeDamaged(user, "projectiles"))
|| (((Projectile)edEvent.getDamager()).getShooter() instanceof Player
&& prot.getSettingBool(ProtectConfig.disable_pvp)
&& (!user.isAuthorized("essentials.protect.pvp")
@@ -139,13 +126,11 @@ public class EssentialsProtectEntityListener implements Listener
}
}
- final DamageCause cause = event.getCause();
if (target instanceof Player)
{
if (cause == DamageCause.FALL
&& prot.getSettingBool(ProtectConfig.disable_fall)
- && !(user.isAuthorized("essentials.protect.damage.fall")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !shouldBeDamaged(user, "fall"))
{
event.setCancelled(true);
return;
@@ -153,33 +138,35 @@ public class EssentialsProtectEntityListener implements Listener
if (cause == DamageCause.SUFFOCATION
&& prot.getSettingBool(ProtectConfig.disable_suffocate)
- && !(user.isAuthorized("essentials.protect.damage.suffocation")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !shouldBeDamaged(user, "suffocation"))
{
event.setCancelled(true);
return;
}
- if ((cause == DamageCause.FIRE
- || cause == DamageCause.FIRE_TICK)
+ if ((cause == DamageCause.FIRE || cause == DamageCause.FIRE_TICK)
&& prot.getSettingBool(ProtectConfig.disable_firedmg)
- && !(user.isAuthorized("essentials.protect.damage.fire")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !shouldBeDamaged(user, "fire"))
{
event.setCancelled(true);
return;
}
if (cause == DamageCause.DROWNING
&& prot.getSettingBool(ProtectConfig.disable_drown)
- && !(user.isAuthorized("essentials.protect.damage.drowning")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !shouldBeDamaged(user, "drowning"))
{
event.setCancelled(true);
return;
}
if (cause == DamageCause.LIGHTNING
&& prot.getSettingBool(ProtectConfig.disable_lightning)
- && !(user.isAuthorized("essentials.protect.damage.lightning")
- && !user.isAuthorized("essentials.protect.damage.disable")))
+ && !shouldBeDamaged(user, "lightning"))
+ {
+ event.setCancelled(true);
+ return;
+ }
+ if (cause == DamageCause.WITHER
+ && prot.getSettingBool(ProtectConfig.disable_wither)
+ && !shouldBeDamaged(user, "wither"))
{
event.setCancelled(true);
return;
@@ -187,6 +174,12 @@ public class EssentialsProtectEntityListener implements Listener
}
}
+ private boolean shouldBeDamaged(final User user, final String type)
+ {
+ return (user.isAuthorized("essentials.protect.damage.".concat(type))
+ && !user.isAuthorized("essentials.protect.damage.disable"));
+ }
+
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onEntityExplode(final EntityExplodeEvent event)
{
@@ -206,6 +199,12 @@ public class EssentialsProtectEntityListener implements Listener
}
return;
}
+ if (event.getEntity() instanceof Wither
+ && prot.getSettingBool(ProtectConfig.prevent_wither_spawnexplosion))
+ {
+ event.setCancelled(true);
+ return;
+ }
else if (event.getEntity() instanceof Creeper
&& (prot.getSettingBool(ProtectConfig.prevent_creeper_explosion)
|| prot.getSettingBool(ProtectConfig.prevent_creeper_blockdmg)
@@ -228,6 +227,13 @@ public class EssentialsProtectEntityListener implements Listener
event.setCancelled(true);
return;
}
+ else if ((event.getEntity() instanceof WitherSkull)
+ && prot.getSettingBool(ProtectConfig.prevent_witherskull_explosion))
+ {
+ event.setCancelled(true);
+ return;
+ }
+
// This code will prevent explosions near protected rails, signs or protected chests
// TODO: Use protect db instead of this code
@@ -294,6 +300,7 @@ public class EssentialsProtectEntityListener implements Listener
|| event.getReason() == TargetReason.TARGET_ATTACKED_ENTITY
|| event.getReason() == TargetReason.PIG_ZOMBIE_TARGET
|| event.getReason() == TargetReason.RANDOM_TARGET
+ || event.getReason() == TargetReason.DEFEND_VILLAGE
|| event.getReason() == TargetReason.TARGET_ATTACKED_OWNER
|| event.getReason() == TargetReason.OWNER_ATTACKED_TARGET)
&& prot.getSettingBool(ProtectConfig.prevent_entitytarget)
@@ -322,5 +329,10 @@ public class EssentialsProtectEntityListener implements Listener
event.setCancelled(true);
return;
}
+ if (event.getEntityType() == EntityType.WITHER && prot.getSettingBool(ProtectConfig.prevent_wither_blockreplace))
+ {
+ event.setCancelled(true);
+ return;
+ }
}
}
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/ProtectConfig.java b/EssentialsProtect/src/com/earth2me/essentials/protect/ProtectConfig.java
index 31141d7e7..d7f428539 100644
--- a/EssentialsProtect/src/com/earth2me/essentials/protect/ProtectConfig.java
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/ProtectConfig.java
@@ -17,6 +17,7 @@ public enum ProtectConfig
disable_firedmg("protect.disable.firedmg", false),
disable_lightning("protect.disable.lightning", false),
disable_drown("protect.disable.drown", false),
+ disable_wither("protect.disable.wither", false),
disable_weather_storm("protect.disable.weather.storm", false),
disable_weather_lightning("protect.disable.weather.lightning", false),
disable_weather_thunder("protect.disable.weather.thunder", false),
@@ -34,6 +35,10 @@ public enum ProtectConfig
prevent_fireball_explosion("protect.prevent.fireball-explosion", false),
prevent_fireball_fire("protect.prevent.fireball-fire", false),
prevent_fireball_playerdmg("protect.prevent.fireball-playerdamage", false),
+ prevent_witherskull_explosion("protect.prevent.witherskull-explosion", false),
+ prevent_witherskull_playerdmg("protect.prevent.witherskull-playerdamage", false),
+ prevent_wither_spawnexplosion("protect.prevent.wither-spawnexplosion", false),
+ prevent_wither_blockreplace("protect.prevent.wither-blockreplace", false),
prevent_creeper_explosion("protect.prevent.creeper-explosion", true),
prevent_creeper_playerdmg("protect.prevent.creeper-playerdamage", false),
prevent_creeper_blockdmg("protect.prevent.creeper-blockdamage", false),
diff --git a/EssentialsProtect/src/com/earth2me/essentials/protect/log4j.properties b/EssentialsProtect/src/com/earth2me/essentials/protect/log4j.properties
new file mode 100644
index 000000000..2642ee541
--- /dev/null
+++ b/EssentialsProtect/src/com/earth2me/essentials/protect/log4j.properties
@@ -0,0 +1,4 @@
+log4j.rootLogger=INFO, A1
+log4j.appender.A1=org.apache.log4j.ConsoleAppender
+log4j.appender.A1.layout=org.apache.log4j.PatternLayout
+log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n \ No newline at end of file
diff --git a/EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawnPlayerListener.java b/EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawnPlayerListener.java
index 0dcf9843a..6fdd4a6a5 100644
--- a/EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawnPlayerListener.java
+++ b/EssentialsSpawn/src/com/earth2me/essentials/spawn/EssentialsSpawnPlayerListener.java
@@ -97,6 +97,7 @@ public class EssentialsSpawnPlayerListener implements Listener
ess.scheduleSyncDelayedTask(new NewPlayerTeleport(user), 1L);
}
+ //This method allows for multiple line player announce messages using multiline yaml syntax #EasterEgg
if (ess.getSettings().getAnnounceNewPlayers())
{
final IText output = new KeywordReplacer(ess.getSettings().getAnnounceNewPlayerFormat(), user, ess);
diff --git a/EssentialsXMPP/src/com/earth2me/essentials/xmpp/XMPPManager.java b/EssentialsXMPP/src/com/earth2me/essentials/xmpp/XMPPManager.java
index 164f40c2a..673ef3377 100644
--- a/EssentialsXMPP/src/com/earth2me/essentials/xmpp/XMPPManager.java
+++ b/EssentialsXMPP/src/com/earth2me/essentials/xmpp/XMPPManager.java
@@ -12,8 +12,8 @@ import java.util.logging.Level;
import java.util.logging.LogRecord;
import java.util.logging.Logger;
import org.bukkit.entity.Player;
-import org.jivesoftware.smack.Roster.SubscriptionMode;
import org.jivesoftware.smack.*;
+import org.jivesoftware.smack.Roster.SubscriptionMode;
import org.jivesoftware.smack.packet.Message;
import org.jivesoftware.smack.packet.Presence;
import org.jivesoftware.smack.util.StringUtils;
@@ -263,7 +263,7 @@ public class XMPPManager extends Handler implements MessageListener, ChatManager
for (LogRecord logRecord : copy)
{
final String message = String.format("[" + logRecord.getLevel().getLocalizedName() + "] " + logRecord.getMessage(), logRecord.getParameters());
- if (!XMPPManager.this.sendMessage(user, message))
+ if (!XMPPManager.this.sendMessage(user, Util.stripLogColorFormat(message)))
{
failedUsers.add(user);
break;
diff --git a/lib/craftbukkit.jar b/lib/craftbukkit.jar
index 5911ae805..beff3e4a8 100644
--- a/lib/craftbukkit.jar
+++ b/lib/craftbukkit.jar
Binary files differ