Correcting all line endings to LF

This commit is contained in:
snowleo 2011-07-24 23:19:12 +02:00
parent 19ba6e5195
commit bc1c252dca
18 changed files with 3392 additions and 3392 deletions

View File

@ -1,84 +1,84 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="Essentials" default="default" basedir="."> <project name="Essentials" default="default" basedir=".">
<description>Builds, tests, and runs the project Essentials.</description> <description>Builds, tests, and runs the project Essentials.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="Essentials-impl.jar"> <target name="run" depends="Essentials-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
<!--target name="-post-jar"> <!--target name="-post-jar">
<jar jarfile="${dist.dir}/Essentials.jar"> <jar jarfile="${dist.dir}/Essentials.jar">
<zipfileset src="${dist.jar}" excludes="META-INF/*" /> <zipfileset src="${dist.jar}" excludes="META-INF/*" />
<zipfileset src="${dist.dir}/lib/Register.jar" excludes="META-INF/*" /> <zipfileset src="${dist.dir}/lib/Register.jar" excludes="META-INF/*" />
<manifest> <manifest>
<attribute name="Classpath" value="Essentials.jar"/> <attribute name="Classpath" value="Essentials.jar"/>
</manifest> </manifest>
</jar> </jar>
</target--> </target-->
</project> </project>

View File

@ -1,52 +1,52 @@
package com.earth2me.essentials.commands; package com.earth2me.essentials.commands;
import org.bukkit.Server; import org.bukkit.Server;
import org.bukkit.command.CommandSender; import org.bukkit.command.CommandSender;
import com.earth2me.essentials.User; import com.earth2me.essentials.User;
import com.earth2me.essentials.Util; import com.earth2me.essentials.Util;
public class Commandmute extends EssentialsCommand public class Commandmute extends EssentialsCommand
{ {
public Commandmute() public Commandmute()
{ {
super("mute"); super("mute");
} }
@Override @Override
public void run(Server server, CommandSender sender, String commandLabel, String[] args) throws Exception public void run(Server server, CommandSender sender, String commandLabel, String[] args) throws Exception
{ {
if (args.length < 1) if (args.length < 1)
{ {
throw new NotEnoughArgumentsException(); throw new NotEnoughArgumentsException();
} }
User p = getPlayer(server, args, 0, true); User p = getPlayer(server, args, 0, true);
if (!p.isMuted() && p.isAuthorized("essentials.mute.exempt")) if (!p.isMuted() && p.isAuthorized("essentials.mute.exempt"))
{ {
sender.sendMessage(Util.i18n("muteExempt")); sender.sendMessage(Util.i18n("muteExempt"));
return; return;
} }
long muteTimestamp = 0; long muteTimestamp = 0;
if (args.length > 1) if (args.length > 1)
{ {
String time = getFinalArg(args, 1); String time = getFinalArg(args, 1);
muteTimestamp = Util.parseDateDiff(time, true); muteTimestamp = Util.parseDateDiff(time, true);
} }
p.setMuteTimeout(muteTimestamp); p.setMuteTimeout(muteTimestamp);
charge(sender); charge(sender);
boolean muted = p.toggleMuted(); boolean muted = p.toggleMuted();
sender.sendMessage( sender.sendMessage(
muted muted
? (muteTimestamp > 0 ? (muteTimestamp > 0
? Util.format("mutedPlayerFor", p.getDisplayName(), Util.formatDateDiff(muteTimestamp)) ? Util.format("mutedPlayerFor", p.getDisplayName(), Util.formatDateDiff(muteTimestamp))
: Util.format("mutedPlayer", p.getDisplayName())) : Util.format("mutedPlayer", p.getDisplayName()))
: Util.format("unmutedPlayer", p.getDisplayName())); : Util.format("unmutedPlayer", p.getDisplayName()));
p.sendMessage( p.sendMessage(
muted muted
? (muteTimestamp > 0 ? (muteTimestamp > 0
? Util.format("playerMutedFor", Util.formatDateDiff(muteTimestamp)) ? Util.format("playerMutedFor", Util.formatDateDiff(muteTimestamp))
: Util.i18n("playerMuted")) : Util.i18n("playerMuted"))
: Util.i18n("playerUnmuted")); : Util.i18n("playerUnmuted"));
} }
} }

File diff suppressed because it is too large Load Diff

View File

@ -1,199 +1,199 @@
worth: worth:
stonebutton: stonebutton:
'0': 7.0 '0': 7.0
wood: 1.0 wood: 1.0
arrow: 10.0 arrow: 10.0
diamondpickaxe: 1000.0 diamondpickaxe: 1000.0
rawfish: 5.0 rawfish: 5.0
minecart: 20.0 minecart: 20.0
leatherchestplate: 40.0 leatherchestplate: 40.0
storageminecart: 35.0 storageminecart: 35.0
leaves: leaves:
'0': 0.0 '0': 0.0
feather: 3.0 feather: 3.0
goldchestplate: 600.0 goldchestplate: 600.0
mushroomsoup: 30.0 mushroomsoup: 30.0
bread: 20.0 bread: 20.0
stationarywater: stationarywater:
'0': 1.0 '0': 1.0
workbench: 20.0 workbench: 20.0
stonehoe: 40.0 stonehoe: 40.0
brownmushroom: 2.0 brownmushroom: 2.0
wool: wool:
'0': 8.0 '0': 8.0
mossycobblestone: 90.0 mossycobblestone: 90.0
diamondhoe: 600.0 diamondhoe: 600.0
woodsword: 10.0 woodsword: 10.0
torch: torch:
'0': 1.0 '0': 1.0
grass: 1.0 grass: 1.0
poweredminecart: 30.0 poweredminecart: 30.0
snowball: 1.0 snowball: 1.0
goldenapple: 500.0 goldenapple: 500.0
leatherleggings: 20.0 leatherleggings: 20.0
log: log:
'0': 2.0 '0': 2.0
diamondaxe: 1000.0 diamondaxe: 1000.0
slimeball: 50.0 slimeball: 50.0
fence: 10.0 fence: 10.0
stonespade: 40.0 stonespade: 40.0
claybrick: 10.0 claybrick: 10.0
noteblock: 40.0 noteblock: 40.0
ironaxe: 60.0 ironaxe: 60.0
coalore: 15.0 coalore: 15.0
clayball: 8.0 clayball: 8.0
fishingrod: 25.0 fishingrod: 25.0
ironhoe: 60.0 ironhoe: 60.0
goldrecord: 950.0 goldrecord: 950.0
ironpickaxe: 80.0 ironpickaxe: 80.0
irondoor: 35.0 irondoor: 35.0
bucket: 10.0 bucket: 10.0
redrose: 2.0 redrose: 2.0
grilledpork: 6.0 grilledpork: 6.0
gravel: 1.0 gravel: 1.0
wooddoor: 30.0 wooddoor: 30.0
chainmailhelmet: 40.0 chainmailhelmet: 40.0
ironchestplate: 300.0 ironchestplate: 300.0
diamondblock: 1500.0 diamondblock: 1500.0
diamondhelmet: 1500.0 diamondhelmet: 1500.0
goldhelmet: 300.0 goldhelmet: 300.0
redstonetorchon: redstonetorchon:
'0': 10.0 '0': 10.0
ironspade: 40.0 ironspade: 40.0
furnace: furnace:
'0': 10.0 '0': 10.0
ironsword: 60.0 ironsword: 60.0
dispenser: dispenser:
'0': 9.0 '0': 9.0
woodaxe: 10.0 woodaxe: 10.0
seeds: 5.0 seeds: 5.0
painting: 50.0 painting: 50.0
woodplate: woodplate:
'0': 10.0 '0': 10.0
redstoneore: 30.0 redstoneore: 30.0
diamondspade: 350.0 diamondspade: 350.0
waterbucket: 10.0 waterbucket: 10.0
water: water:
'0': 1.0 '0': 1.0
bedrock: 1000.0 bedrock: 1000.0
irondoorblock: irondoorblock:
'0': 15.0 '0': 15.0
goldhoe: 200.0 goldhoe: 200.0
sand: 1.0 sand: 1.0
goldsword: 200.0 goldsword: 200.0
stoneaxe: 40.0 stoneaxe: 40.0
bookshelf: 20.0 bookshelf: 20.0
ironblock: 160.0 ironblock: 160.0
jackolantern: jackolantern:
'0': 60.0 '0': 60.0
boat: 5.0 boat: 5.0
diamondchestplate: 3000.0 diamondchestplate: 3000.0
redstonewire: redstonewire:
'0': 7.0 '0': 7.0
redmushroom: 2.0 redmushroom: 2.0
string: 5.0 string: 5.0
stoneplate: stoneplate:
'0': 10.0 '0': 10.0
wallsign: wallsign:
'0': 1.0 '0': 1.0
cactus: cactus:
'0': 10.0 '0': 10.0
sulphur: 19.0 sulphur: 19.0
rails: rails:
'0': 40.0 '0': 40.0
ironore: 18.0 ironore: 18.0
leatherhelmet: 20.0 leatherhelmet: 20.0
stone: 2.0 stone: 2.0
egg: 1.0 egg: 1.0
diamondore: 200.0 diamondore: 200.0
woodhoe: 10.0 woodhoe: 10.0
goldleggings: 400.0 goldleggings: 400.0
chainmailleggings: 50.0 chainmailleggings: 50.0
yellowflower: 2.0 yellowflower: 2.0
ironhelmet: 120.0 ironhelmet: 120.0
obsidian: 130.0 obsidian: 130.0
dirt: 1.0 dirt: 1.0
leather: 10.0 leather: 10.0
leatherboots: 17.0 leatherboots: 17.0
lever: lever:
'0': 7.0 '0': 7.0
cobblestone: 1.0 cobblestone: 1.0
cake: 100.0 cake: 100.0
woodstairs: woodstairs:
'0': 8.0 '0': 8.0
ironingot: 20.0 ironingot: 20.0
goldore: 45.0 goldore: 45.0
pumpkin: pumpkin:
'0': 50.0 '0': 50.0
bed: 25.0 bed: 25.0
watch: 100.0 watch: 100.0
ironleggings: 250.0 ironleggings: 250.0
sign: 10.0 sign: 10.0
doublestep: doublestep:
'0': 3.0 '0': 3.0
woodpickaxe: 10.0 woodpickaxe: 10.0
stonepickaxe: 40.0 stonepickaxe: 40.0
chainmailboots: 30.0 chainmailboots: 30.0
diamondleggings: 2200.0 diamondleggings: 2200.0
cookedfish: 20.0 cookedfish: 20.0
saddle: 100.0 saddle: 100.0
cobblestonestairs: cobblestonestairs:
'0': 22.0 '0': 22.0
tnt: 10000.0 tnt: 10000.0
glowingredstoneore: 30.0 glowingredstoneore: 30.0
apple: 10.0 apple: 10.0
woodspade: 10.0 woodspade: 10.0
goldingot: 50.0 goldingot: 50.0
diode: 10.0 diode: 10.0
soil: soil:
'0': 3.0 '0': 3.0
clay: 3.0 clay: 3.0
goldblock: 400.0 goldblock: 400.0
stick: 1.0 stick: 1.0
paper: 30.0 paper: 30.0
brick: 40.0 brick: 40.0
stationarylava: stationarylava:
'0': 1.0 '0': 1.0
chest: 15.0 chest: 15.0
sandstone: 5.0 sandstone: 5.0
goldpickaxe: 300.0 goldpickaxe: 300.0
compass: 50.0 compass: 50.0
sugarcane: 10.0 sugarcane: 10.0
diamondsword: 700.0 diamondsword: 700.0
goldboots: 250.0 goldboots: 250.0
sponge: 80.0 sponge: 80.0
stonesword: 40.0 stonesword: 40.0
coal: coal:
'0': 3.0 '0': 3.0
goldaxe: 300.0 goldaxe: 300.0
bone: 10.0 bone: 10.0
diamond: 230.0 diamond: 230.0
glass: 10.0 glass: 10.0
goldspade: 220.0 goldspade: 220.0
lapisblock: 500.0 lapisblock: 500.0
lavabucket: 30.0 lavabucket: 30.0
wheat: 9.0 wheat: 9.0
ladder: ladder:
'0': 10.0 '0': 10.0
sugarcaneblock: sugarcaneblock:
'0': 15.0 '0': 15.0
bowl: 6.0 bowl: 6.0
chainmailchestplate: 40.0 chainmailchestplate: 40.0
sapling: sapling:
'0': 2.0 '0': 2.0
diamondboots: 1500.0 diamondboots: 1500.0
lapisore: 100.0 lapisore: 100.0
lava: lava:
'0': 1.0 '0': 1.0
milkbucket: 15.0 milkbucket: 15.0
redstone: 1.0 redstone: 1.0
greenrecord: 1000.0 greenrecord: 1000.0
inksack: inksack:
'0': 10.0 '0': 10.0
glowstonedust: 11.0 glowstonedust: 11.0
book: 35.0 book: 35.0
bow: 75.0 bow: 75.0
ironboots: 50.0 ironboots: 50.0
step: step:
'0': 3.0 '0': 3.0
sugar: 5.0 sugar: 5.0

View File

@ -50,200 +50,200 @@
2011-02-28 16:57:50 [INFO] §eLoaded Essentials build TeamCity maintained by Zenexer, ementalo, Aelux, and Brettflan 2011-02-28 16:57:50 [INFO] §eLoaded Essentials build TeamCity maintained by Zenexer, ementalo, Aelux, and Brettflan
2011-02-28 16:57:50 [INFO] Preparing spawn area: 8% 2011-02-28 16:57:50 [INFO] Preparing spawn area: 8%
2011-02-28 16:57:51 [INFO] > 2011-02-28 16:57:51 [INFO] >
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] Starting minecraft server version Beta 1.3 2011-02-28 16:57:51 [INFO] Starting minecraft server version Beta 1.3
2011-02-28 16:57:51 [INFO] Preparing spawn area: 12% 2011-02-28 16:57:51 [INFO] Preparing spawn area: 12%
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:51 [INFO] 2011-02-28 16:57:51 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:52 [INFO] 2011-02-28 16:57:52 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:53 [INFO] 2011-02-28 16:57:53 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:54 [INFO] 2011-02-28 16:57:54 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:55 [INFO] 2011-02-28 16:57:55 [INFO]
2011-02-28 16:57:56 [INFO] 2011-02-28 16:57:56 [INFO]
2011-02-28 16:57:56 [INFO] 2011-02-28 16:57:56 [INFO]
2011-02-28 16:57:56 [INFO] 2011-02-28 16:57:56 [INFO]
2011-02-28 16:57:56 [INFO] 2011-02-28 16:57:56 [INFO]
2011-02-28 16:59:07 [INFO] Starting minecraft server version Beta 1.3 2011-02-28 16:59:07 [INFO] Starting minecraft server version Beta 1.3
2011-02-28 16:59:07 [INFO] Loading properties 2011-02-28 16:59:07 [INFO] Loading properties
2011-02-28 16:59:07 [INFO] Starting Minecraft server on *:25565 2011-02-28 16:59:07 [INFO] Starting Minecraft server on *:25565

View File

@ -1,13 +1,13 @@
#Minecraft server properties #Minecraft server properties
#Mon Feb 28 16:56:01 EST 2011 #Mon Feb 28 16:56:01 EST 2011
level-name=world level-name=world
hellworld=false hellworld=false
spawn-monsters=true spawn-monsters=true
online-mode=true online-mode=true
spawn-animals=true spawn-animals=true
max-players=20 max-players=20
server-ip= server-ip=
pvp=true pvp=true
server-port=25565 server-port=25565
white-list=false white-list=false
spawn-protection=16 spawn-protection=16

View File

@ -1,76 +1,76 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]> <!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="EssentialsChat" default="default" basedir="."> <project name="EssentialsChat" default="default" basedir=".">
<description>Builds, tests, and runs the project EssentialsChat.</description> <description>Builds, tests, and runs the project EssentialsChat.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
&buildinc; &buildinc;
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="EssentialsChat-impl.jar"> <target name="run" depends="EssentialsChat-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
</project> </project>

View File

@ -1,74 +1,74 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="EssentialsGroupBridge" default="default" basedir="."> <project name="EssentialsGroupBridge" default="default" basedir=".">
<description>Builds, tests, and runs the project EssentialsGroupBridge.</description> <description>Builds, tests, and runs the project EssentialsGroupBridge.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="EssentialsGroupBridge-impl.jar"> <target name="run" depends="EssentialsGroupBridge-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
</project> </project>

View File

@ -1,25 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://www.netbeans.org/ns/project/1"> <project xmlns="http://www.netbeans.org/ns/project/1">
<type>org.netbeans.modules.java.j2seproject</type> <type>org.netbeans.modules.java.j2seproject</type>
<configuration> <configuration>
<data xmlns="http://www.netbeans.org/ns/j2se-project/3"> <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
<name>EssentialsGroupBridge</name> <name>EssentialsGroupBridge</name>
<source-roots> <source-roots>
<root id="src.dir"/> <root id="src.dir"/>
</source-roots> </source-roots>
<test-roots> <test-roots>
<root id="test.src.dir"/> <root id="test.src.dir"/>
</test-roots> </test-roots>
</data> </data>
<references xmlns="http://www.netbeans.org/ns/ant-project-references/1"> <references xmlns="http://www.netbeans.org/ns/ant-project-references/1">
<reference> <reference>
<foreign-project>EssentialsGroupManager</foreign-project> <foreign-project>EssentialsGroupManager</foreign-project>
<artifact-type>jar</artifact-type> <artifact-type>jar</artifact-type>
<script>build.xml</script> <script>build.xml</script>
<target>jar</target> <target>jar</target>
<clean-target>clean</clean-target> <clean-target>clean</clean-target>
<id>jar</id> <id>jar</id>
</reference> </reference>
</references> </references>
</configuration> </configuration>
</project> </project>

View File

@ -1,74 +1,74 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="EssentialsGroupManager" default="default" basedir="."> <project name="EssentialsGroupManager" default="default" basedir=".">
<description>Builds, tests, and runs the project EssentialsGroupManager.</description> <description>Builds, tests, and runs the project EssentialsGroupManager.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="EssentialsGroupManager-impl.jar"> <target name="run" depends="EssentialsGroupManager-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
</project> </project>

View File

@ -1,2 +1,2 @@
Manifest-Version: 1.0 Manifest-Version: 1.0
Class-Path: ../lib/mysql.jar ../lib/sqlite.jar Class-Path: ../lib/mysql.jar ../lib/sqlite.jar

View File

@ -1,84 +1,84 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]> <!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="EssentialsProtect" default="default" basedir="."> <project name="EssentialsProtect" default="default" basedir=".">
<description>Builds, tests, and runs the project EssentialsProtect.</description> <description>Builds, tests, and runs the project EssentialsProtect.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="EssentialsProtect-impl.jar"> <target name="run" depends="EssentialsProtect-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
<target name="-post-jar"> <target name="-post-jar">
<jar jarfile="${dist.dir}/EssentialsProtect.jar"> <jar jarfile="${dist.dir}/EssentialsProtect.jar">
<zipfileset src="${dist.jar}" excludes="META-INF/*" /> <zipfileset src="${dist.jar}" excludes="META-INF/*" />
<zipfileset src="../lib/c3p0-0.9.1.2.jar" excludes="META-INF/*" /> <zipfileset src="../lib/c3p0-0.9.1.2.jar" excludes="META-INF/*" />
<manifest> <manifest>
<attribute name="Classpath" value="EssentialsProtect.jar"/> <attribute name="Classpath" value="EssentialsProtect.jar"/>
</manifest> </manifest>
</jar> </jar>
</target> </target>
</project> </project>

View File

@ -1,348 +1,348 @@
package com.earth2me.essentials.protect; package com.earth2me.essentials.protect;
import com.earth2me.essentials.EssentialsBlockListener; import com.earth2me.essentials.EssentialsBlockListener;
import com.earth2me.essentials.IEssentials; import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User; import com.earth2me.essentials.User;
import java.util.HashSet; import java.util.HashSet;
import java.util.Set; import java.util.Set;
import net.minecraft.server.ChunkPosition; import net.minecraft.server.ChunkPosition;
import net.minecraft.server.Packet60Explosion; import net.minecraft.server.Packet60Explosion;
import org.bukkit.Location; import org.bukkit.Location;
import org.bukkit.Material; import org.bukkit.Material;
import org.bukkit.block.Block; import org.bukkit.block.Block;
import org.bukkit.block.BlockFace; import org.bukkit.block.BlockFace;
import org.bukkit.craftbukkit.CraftServer; import org.bukkit.craftbukkit.CraftServer;
import org.bukkit.craftbukkit.CraftWorld; import org.bukkit.craftbukkit.CraftWorld;
import org.bukkit.craftbukkit.entity.CraftFireball; import org.bukkit.craftbukkit.entity.CraftFireball;
import org.bukkit.craftbukkit.entity.CraftPlayer; import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.craftbukkit.entity.CraftTNTPrimed; import org.bukkit.craftbukkit.entity.CraftTNTPrimed;
import org.bukkit.entity.Creeper; import org.bukkit.entity.Creeper;
import org.bukkit.entity.Entity; import org.bukkit.entity.Entity;
import org.bukkit.entity.Fireball; import org.bukkit.entity.Fireball;
import org.bukkit.entity.LivingEntity; import org.bukkit.entity.LivingEntity;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.entity.TNTPrimed; import org.bukkit.entity.TNTPrimed;
import org.bukkit.event.entity.CreatureSpawnEvent; import org.bukkit.event.entity.CreatureSpawnEvent;
import org.bukkit.event.entity.EntityDamageByBlockEvent; import org.bukkit.event.entity.EntityDamageByBlockEvent;
import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.event.entity.EntityDamageByEntityEvent;
import org.bukkit.event.entity.EntityDamageByProjectileEvent; import org.bukkit.event.entity.EntityDamageByProjectileEvent;
import org.bukkit.event.entity.EntityDamageEvent; import org.bukkit.event.entity.EntityDamageEvent;
import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.event.entity.EntityDamageEvent.DamageCause;
import org.bukkit.event.entity.EntityExplodeEvent; import org.bukkit.event.entity.EntityExplodeEvent;
import org.bukkit.event.entity.EntityListener; import org.bukkit.event.entity.EntityListener;
import org.bukkit.event.entity.EntityTargetEvent; import org.bukkit.event.entity.EntityTargetEvent;
import org.bukkit.event.entity.EntityTargetEvent.TargetReason; import org.bukkit.event.entity.EntityTargetEvent.TargetReason;
import org.bukkit.event.entity.ExplosionPrimeEvent; import org.bukkit.event.entity.ExplosionPrimeEvent;
public class EssentialsProtectEntityListener extends EntityListener public class EssentialsProtectEntityListener extends EntityListener
{ {
private final transient IProtect prot; private final transient IProtect prot;
private final transient IEssentials ess; private final transient IEssentials ess;
public EssentialsProtectEntityListener(final IProtect prot) public EssentialsProtectEntityListener(final IProtect prot)
{ {
this.prot = prot; this.prot = prot;
this.ess = prot.getEssentials(); this.ess = prot.getEssentials();
} }
@Override @Override
public void onEntityDamage(EntityDamageEvent event) public void onEntityDamage(EntityDamageEvent event)
{ {
if (event.isCancelled()) if (event.isCancelled())
{ {
return; return;
} }
final Entity target = event.getEntity(); final Entity target = event.getEntity();
final User user = ess.getUser(target); final User user = ess.getUser(target);
if (event instanceof EntityDamageByBlockEvent) if (event instanceof EntityDamageByBlockEvent)
{ {
final DamageCause cause = event.getCause(); final DamageCause cause = event.getCause();
if (prot.getSettingBool(ProtectConfig.disable_contactdmg) if (prot.getSettingBool(ProtectConfig.disable_contactdmg)
&& cause == DamageCause.CONTACT && cause == DamageCause.CONTACT
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.contact") && user.isAuthorized("essentials.protect.damage.contact")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (prot.getSettingBool(ProtectConfig.disable_lavadmg) if (prot.getSettingBool(ProtectConfig.disable_lavadmg)
&& cause == DamageCause.LAVA && cause == DamageCause.LAVA
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.lava") && user.isAuthorized("essentials.protect.damage.lava")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (prot.getSettingBool(ProtectConfig.prevent_tnt_explosion) if (prot.getSettingBool(ProtectConfig.prevent_tnt_explosion)
&& cause == DamageCause.BLOCK_EXPLOSION && cause == DamageCause.BLOCK_EXPLOSION
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.tnt") && user.isAuthorized("essentials.protect.damage.tnt")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
} }
if (event instanceof EntityDamageByEntityEvent) if (event instanceof EntityDamageByEntityEvent)
{ {
final EntityDamageByEntityEvent edEvent = (EntityDamageByEntityEvent)event; final EntityDamageByEntityEvent edEvent = (EntityDamageByEntityEvent)event;
final Entity eAttack = edEvent.getDamager(); final Entity eAttack = edEvent.getDamager();
final User attacker = ess.getUser(eAttack); final User attacker = ess.getUser(eAttack);
// PVP Settings // PVP Settings
if (target instanceof Player && eAttack instanceof Player if (target instanceof Player && eAttack instanceof Player
&& prot.getSettingBool(ProtectConfig.disable_pvp) && prot.getSettingBool(ProtectConfig.disable_pvp)
&& (!user.isAuthorized("essentials.protect.pvp") || !attacker.isAuthorized("essentials.protect.pvp"))) && (!user.isAuthorized("essentials.protect.pvp") || !attacker.isAuthorized("essentials.protect.pvp")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
//Creeper explode prevention //Creeper explode prevention
if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_explosion) if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_explosion)
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.creeper") && user.isAuthorized("essentials.protect.damage.creeper")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_playerdmg) if (eAttack instanceof Creeper && prot.getSettingBool(ProtectConfig.prevent_creeper_playerdmg)
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.creeper") && user.isAuthorized("essentials.protect.damage.creeper")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (eAttack instanceof Fireball && prot.getSettingBool(ProtectConfig.prevent_fireball_playerdmg) if (eAttack instanceof Fireball && prot.getSettingBool(ProtectConfig.prevent_fireball_playerdmg)
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.fireball") && user.isAuthorized("essentials.protect.damage.fireball")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (eAttack instanceof TNTPrimed && prot.getSettingBool(ProtectConfig.prevent_tnt_playerdmg) if (eAttack instanceof TNTPrimed && prot.getSettingBool(ProtectConfig.prevent_tnt_playerdmg)
&& !(target instanceof Player && !(target instanceof Player
&& user.isAuthorized("essentials.protect.damage.tnt") && user.isAuthorized("essentials.protect.damage.tnt")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
} }
if (event instanceof EntityDamageByProjectileEvent if (event instanceof EntityDamageByProjectileEvent
&& target instanceof Player && target instanceof Player
&& prot.getSettingBool(ProtectConfig.disable_projectiles) && prot.getSettingBool(ProtectConfig.disable_projectiles)
&& !(user.isAuthorized("essentials.protect.damage.projectiles") && !(user.isAuthorized("essentials.protect.damage.projectiles")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
((EntityDamageByProjectileEvent)event).setBounce(true); ((EntityDamageByProjectileEvent)event).setBounce(true);
return; return;
} }
final DamageCause cause = event.getCause(); final DamageCause cause = event.getCause();
if (target instanceof Player) if (target instanceof Player)
{ {
if (cause == DamageCause.FALL if (cause == DamageCause.FALL
&& prot.getSettingBool(ProtectConfig.disable_fall) && prot.getSettingBool(ProtectConfig.disable_fall)
&& !(user.isAuthorized("essentials.protect.damage.fall") && !(user.isAuthorized("essentials.protect.damage.fall")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (cause == DamageCause.SUFFOCATION if (cause == DamageCause.SUFFOCATION
&& prot.getSettingBool(ProtectConfig.disable_suffocate) && prot.getSettingBool(ProtectConfig.disable_suffocate)
&& !(user.isAuthorized("essentials.protect.damage.suffocation") && !(user.isAuthorized("essentials.protect.damage.suffocation")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if ((cause == DamageCause.FIRE if ((cause == DamageCause.FIRE
|| cause == DamageCause.FIRE_TICK) || cause == DamageCause.FIRE_TICK)
&& prot.getSettingBool(ProtectConfig.disable_firedmg) && prot.getSettingBool(ProtectConfig.disable_firedmg)
&& !(user.isAuthorized("essentials.protect.damage.fire") && !(user.isAuthorized("essentials.protect.damage.fire")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (cause == DamageCause.DROWNING if (cause == DamageCause.DROWNING
&& prot.getSettingBool(ProtectConfig.disable_drown) && prot.getSettingBool(ProtectConfig.disable_drown)
&& !(user.isAuthorized("essentials.protect.damage.drowning") && !(user.isAuthorized("essentials.protect.damage.drowning")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if (cause == DamageCause.LIGHTNING if (cause == DamageCause.LIGHTNING
&& prot.getSettingBool(ProtectConfig.disable_lightning) && prot.getSettingBool(ProtectConfig.disable_lightning)
&& !(user.isAuthorized("essentials.protect.damage.lightning") && !(user.isAuthorized("essentials.protect.damage.lightning")
&& !user.isAuthorized("essentials.protect.damage.disable"))) && !user.isAuthorized("essentials.protect.damage.disable")))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
} }
} }
@Override @Override
public void onEntityExplode(EntityExplodeEvent event) public void onEntityExplode(EntityExplodeEvent event)
{ {
if (event.isCancelled()) if (event.isCancelled())
{ {
return; return;
} }
final int maxHeight = ess.getSettings().getProtectCreeperMaxHeight(); final int maxHeight = ess.getSettings().getProtectCreeperMaxHeight();
//Nicccccccccce plaaacccccccccce.. //Nicccccccccce plaaacccccccccce..
if (event.getEntity() instanceof LivingEntity if (event.getEntity() instanceof LivingEntity
&& (prot.getSettingBool(ProtectConfig.prevent_creeper_explosion) && (prot.getSettingBool(ProtectConfig.prevent_creeper_explosion)
|| prot.getSettingBool(ProtectConfig.prevent_creeper_blockdmg) || prot.getSettingBool(ProtectConfig.prevent_creeper_blockdmg)
|| (maxHeight >= 0 && event.getLocation().getBlockY() > maxHeight))) || (maxHeight >= 0 && event.getLocation().getBlockY() > maxHeight)))
{ {
final Set<ChunkPosition> set = new HashSet<ChunkPosition>(event.blockList().size()); final Set<ChunkPosition> set = new HashSet<ChunkPosition>(event.blockList().size());
final Player[] players = ess.getServer().getOnlinePlayers(); final Player[] players = ess.getServer().getOnlinePlayers();
final Set<ChunkPosition> blocksUnderPlayers = new HashSet<ChunkPosition>(players.length); final Set<ChunkPosition> blocksUnderPlayers = new HashSet<ChunkPosition>(players.length);
final Location loc = event.getLocation(); final Location loc = event.getLocation();
for (Player player : players) for (Player player : players)
{ {
if (player.getWorld().equals(loc.getWorld())) if (player.getWorld().equals(loc.getWorld()))
{ {
blocksUnderPlayers.add( blocksUnderPlayers.add(
new ChunkPosition( new ChunkPosition(
player.getLocation().getBlockX(), player.getLocation().getBlockX(),
player.getLocation().getBlockY() - 1, player.getLocation().getBlockY() - 1,
player.getLocation().getBlockZ())); player.getLocation().getBlockZ()));
} }
} }
ChunkPosition cp; ChunkPosition cp;
for (Block block : event.blockList()) for (Block block : event.blockList())
{ {
cp = new ChunkPosition(block.getX(), block.getY(), block.getZ()); cp = new ChunkPosition(block.getX(), block.getY(), block.getZ());
if (!blocksUnderPlayers.contains(cp)) if (!blocksUnderPlayers.contains(cp))
{ {
set.add(cp); set.add(cp);
} }
} }
((CraftServer)ess.getServer()).getHandle().sendPacketNearby(loc.getX(), loc.getY(), loc.getZ(), 64.0D, ((CraftWorld)loc.getWorld()).getHandle().worldProvider.dimension, ((CraftServer)ess.getServer()).getHandle().sendPacketNearby(loc.getX(), loc.getY(), loc.getZ(), 64.0D, ((CraftWorld)loc.getWorld()).getHandle().worldProvider.dimension,
new Packet60Explosion(loc.getX(), loc.getY(), loc.getZ(), 3.0f, set)); new Packet60Explosion(loc.getX(), loc.getY(), loc.getZ(), 3.0f, set));
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
else if (event.getEntity() instanceof CraftTNTPrimed else if (event.getEntity() instanceof CraftTNTPrimed
&& prot.getSettingBool(ProtectConfig.prevent_tnt_explosion)) && prot.getSettingBool(ProtectConfig.prevent_tnt_explosion))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
else if (event.getEntity() instanceof CraftFireball else if (event.getEntity() instanceof CraftFireball
&& prot.getSettingBool(ProtectConfig.prevent_fireball_explosion)) && prot.getSettingBool(ProtectConfig.prevent_fireball_explosion))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
// This code will prevent explosions near protected rails, signs or protected chests // This code will prevent explosions near protected rails, signs or protected chests
// TODO: Use protect db instead of this code // TODO: Use protect db instead of this code
for (Block block : event.blockList()) for (Block block : event.blockList())
{ {
if ((block.getType() == Material.RAILS || block.getRelative(BlockFace.UP).getType() == Material.RAILS) if ((block.getType() == Material.RAILS || block.getRelative(BlockFace.UP).getType() == Material.RAILS)
&& prot.getSettingBool(ProtectConfig.protect_rails)) && prot.getSettingBool(ProtectConfig.protect_rails))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
if ((block.getType() == Material.WALL_SIGN if ((block.getType() == Material.WALL_SIGN
|| block.getRelative(BlockFace.NORTH).getType() == Material.WALL_SIGN || block.getRelative(BlockFace.NORTH).getType() == Material.WALL_SIGN
|| block.getRelative(BlockFace.EAST).getType() == Material.WALL_SIGN || block.getRelative(BlockFace.EAST).getType() == Material.WALL_SIGN
|| block.getRelative(BlockFace.SOUTH).getType() == Material.WALL_SIGN || block.getRelative(BlockFace.SOUTH).getType() == Material.WALL_SIGN
|| block.getRelative(BlockFace.WEST).getType() == Material.WALL_SIGN || block.getRelative(BlockFace.WEST).getType() == Material.WALL_SIGN
|| block.getType() == Material.SIGN_POST || block.getType() == Material.SIGN_POST
|| block.getRelative(BlockFace.UP).getType() == Material.SIGN_POST) || block.getRelative(BlockFace.UP).getType() == Material.SIGN_POST)
&& prot.getSettingBool(ProtectConfig.protect_signs)) && prot.getSettingBool(ProtectConfig.protect_signs))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
/*if (EssentialsBlockListener.protectedBlocks.contains(block.getType()) /*if (EssentialsBlockListener.protectedBlocks.contains(block.getType())
&& EssentialsBlockListener.isBlockProtected(block)) && EssentialsBlockListener.isBlockProtected(block))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
}*/ }*/
} }
} }
@Override @Override
public void onCreatureSpawn(final CreatureSpawnEvent event) public void onCreatureSpawn(final CreatureSpawnEvent event)
{ {
if (event.getEntity() instanceof CraftPlayer) if (event.getEntity() instanceof CraftPlayer)
{ {
return; return;
} }
if (event.isCancelled()) if (event.isCancelled())
{ {
return; return;
} }
final String creatureName = event.getCreatureType().toString().toLowerCase(); final String creatureName = event.getCreatureType().toString().toLowerCase();
if (creatureName == null || creatureName.isEmpty()) if (creatureName == null || creatureName.isEmpty())
{ {
return; return;
} }
if (ess.getSettings().getProtectPreventSpawn(creatureName)) if (ess.getSettings().getProtectPreventSpawn(creatureName))
{ {
event.setCancelled(true); event.setCancelled(true);
} }
} }
@Override @Override
public void onEntityTarget(final EntityTargetEvent event) public void onEntityTarget(final EntityTargetEvent event)
{ {
if (event.isCancelled()) if (event.isCancelled())
{ {
return; return;
} }
if (!(event.getTarget() instanceof Player)) if (!(event.getTarget() instanceof Player))
{ {
return; return;
} }
final User user = ess.getUser(event.getTarget()); final User user = ess.getUser(event.getTarget());
if ((event.getReason() == TargetReason.CLOSEST_PLAYER if ((event.getReason() == TargetReason.CLOSEST_PLAYER
|| event.getReason() == TargetReason.TARGET_ATTACKED_ENTITY || event.getReason() == TargetReason.TARGET_ATTACKED_ENTITY
|| event.getReason() == TargetReason.PIG_ZOMBIE_TARGET || event.getReason() == TargetReason.PIG_ZOMBIE_TARGET
|| event.getReason() == TargetReason.RANDOM_TARGET || event.getReason() == TargetReason.RANDOM_TARGET
|| event.getReason() == TargetReason.TARGET_ATTACKED_OWNER || event.getReason() == TargetReason.TARGET_ATTACKED_OWNER
|| event.getReason() == TargetReason.OWNER_ATTACKED_TARGET) || event.getReason() == TargetReason.OWNER_ATTACKED_TARGET)
&& prot.getSettingBool(ProtectConfig.prevent_entitytarget) && prot.getSettingBool(ProtectConfig.prevent_entitytarget)
&& !user.isAuthorized("essentials.protect.entitytarget.bypass")) && !user.isAuthorized("essentials.protect.entitytarget.bypass"))
{ {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
} }
@Override @Override
public void onExplosionPrime(ExplosionPrimeEvent event) public void onExplosionPrime(ExplosionPrimeEvent event)
{ {
if (event.getEntity() instanceof CraftFireball if (event.getEntity() instanceof CraftFireball
&& prot.getSettingBool(ProtectConfig.prevent_fireball_fire)) && prot.getSettingBool(ProtectConfig.prevent_fireball_fire))
{ {
event.setFire(false); event.setFire(false);
} }
} }
} }

View File

@ -1,9 +1,9 @@
# This determines the command prefix when there are conflicts (/name:home, /name:help, etc.) # This determines the command prefix when there are conflicts (/name:home, /name:help, etc.)
name: EssentialsProtect name: EssentialsProtect
main: com.earth2me.essentials.protect.EssentialsProtect main: com.earth2me.essentials.protect.EssentialsProtect
# Note to developers: This next line cannot change, or the automatic versioning system will break. # Note to developers: This next line cannot change, or the automatic versioning system will break.
version: TeamCity version: TeamCity
website: http://www.earth2me.net:8001/ website: http://www.earth2me.net:8001/
description: Provides protection for various parts of the world. description: Provides protection for various parts of the world.
authors: [Zenexer, ementalo, Aelux, Brettflan, KimKandor, snowleo, ceulemans, Xeology] authors: [Zenexer, ementalo, Aelux, Brettflan, KimKandor, snowleo, ceulemans, Xeology]
depend: [Essentials] depend: [Essentials]

View File

@ -1,76 +1,76 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]> <!DOCTYPE project [ <!ENTITY buildinc SYSTEM "../build.inc.xml"> ]>
<!-- You may freely edit this file. See commented blocks below for --> <!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. --> <!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) --> <!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. --> <!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if --> <!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. --> <!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.--> <!-- in the project's Project Properties dialog box.-->
<project name="EssentialsSpawn" default="default" basedir="."> <project name="EssentialsSpawn" default="default" basedir=".">
<description>Builds, tests, and runs the project EssentialsSpawn.</description> <description>Builds, tests, and runs the project EssentialsSpawn.</description>
<import file="nbproject/build-impl.xml"/> <import file="nbproject/build-impl.xml"/>
&buildinc; &buildinc;
<!-- <!--
There exist several targets which are by default empty and which can be There exist several targets which are by default empty and which can be
used for execution of your tasks. These targets are usually executed used for execution of your tasks. These targets are usually executed
before and after some main targets. They are: before and after some main targets. They are:
-pre-init: called before initialization of project properties -pre-init: called before initialization of project properties
-post-init: called after initialization of project properties -post-init: called after initialization of project properties
-pre-compile: called before javac compilation -pre-compile: called before javac compilation
-post-compile: called after javac compilation -post-compile: called after javac compilation
-pre-compile-single: called before javac compilation of single file -pre-compile-single: called before javac compilation of single file
-post-compile-single: called after javac compilation of single file -post-compile-single: called after javac compilation of single file
-pre-compile-test: called before javac compilation of JUnit tests -pre-compile-test: called before javac compilation of JUnit tests
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-jar: called before JAR building -pre-jar: called before JAR building
-post-jar: called after JAR building -post-jar: called after JAR building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
(Targets beginning with '-' are not intended to be called on their own.) (Targets beginning with '-' are not intended to be called on their own.)
Example of inserting an obfuscator after compilation could look like this: Example of inserting an obfuscator after compilation could look like this:
<target name="-post-compile"> <target name="-post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
</target> </target>
For list of available properties check the imported For list of available properties check the imported
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
Another way to customize the build is by overriding existing main targets. Another way to customize the build is by overriding existing main targets.
The targets of interest are: The targets of interest are:
-init-macrodef-javac: defines macro for javac compilation -init-macrodef-javac: defines macro for javac compilation
-init-macrodef-junit: defines macro for junit execution -init-macrodef-junit: defines macro for junit execution
-init-macrodef-debug: defines macro for class debugging -init-macrodef-debug: defines macro for class debugging
-init-macrodef-java: defines macro for class execution -init-macrodef-java: defines macro for class execution
-do-jar-with-manifest: JAR building (if you are using a manifest) -do-jar-with-manifest: JAR building (if you are using a manifest)
-do-jar-without-manifest: JAR building (if you are not using a manifest) -do-jar-without-manifest: JAR building (if you are not using a manifest)
run: execution of project run: execution of project
-javadoc-build: Javadoc generation -javadoc-build: Javadoc generation
test-report: JUnit report generation test-report: JUnit report generation
An example of overriding the target for project execution could look like this: An example of overriding the target for project execution could look like this:
<target name="run" depends="EssentialsSpawn-impl.jar"> <target name="run" depends="EssentialsSpawn-impl.jar">
<exec dir="bin" executable="launcher.exe"> <exec dir="bin" executable="launcher.exe">
<arg file="${dist.jar}"/> <arg file="${dist.jar}"/>
</exec> </exec>
</target> </target>
Notice that the overridden target depends on the jar target and not only on Notice that the overridden target depends on the jar target and not only on
the compile target as the regular run target does. Again, for a list of available the compile target as the regular run target does. Again, for a list of available
properties which you can use, check the target you are overriding in the properties which you can use, check the target you are overriding in the
nbproject/build-impl.xml file. nbproject/build-impl.xml file.
--> -->
</project> </project>

View File

@ -1,16 +1,16 @@
# This determines the command prefix when there are conflicts (/name:home, /name:help, etc.) # This determines the command prefix when there are conflicts (/name:home, /name:help, etc.)
name: EssentialsSpawn name: EssentialsSpawn
main: com.earth2me.essentials.spawn.EssentialsSpawn main: com.earth2me.essentials.spawn.EssentialsSpawn
# Note to developers: This next line cannot change, or the automatic versioning system will break. # Note to developers: This next line cannot change, or the automatic versioning system will break.
version: TeamCity version: TeamCity
website: http://www.earth2me.net:8001/ website: http://www.earth2me.net:8001/
description: Provides spawn control commands, utilizing Essentials. description: Provides spawn control commands, utilizing Essentials.
authors: [Zenexer, ementalo, Aelux, Brettflan, KimKandor, snowleo, ceulemans, Xeology] authors: [Zenexer, ementalo, Aelux, Brettflan, KimKandor, snowleo, ceulemans, Xeology]
depend: [Essentials] depend: [Essentials]
commands: commands:
setspawn: setspawn:
description: Set the spawnpoint to your current position. description: Set the spawnpoint to your current position.
usage: /<command> <group> usage: /<command> <group>
spawn: spawn:
description: Teleport to the spawnpoint. description: Teleport to the spawnpoint.
usage: /<command> usage: /<command>

View File

@ -1,7 +1,7 @@
<target name="-post-jar"> <target name="-post-jar">
<jar destfile="${dist.jar}" update="true"> <jar destfile="${dist.jar}" update="true">
<manifest> <manifest>
<attribute name="Classpath" value="Essentials.jar"/> <attribute name="Classpath" value="Essentials.jar"/>
</manifest> </manifest>
</jar> </jar>
</target> </target>

View File

@ -1,12 +1,12 @@
libs.CopyLibs.classpath=\ libs.CopyLibs.classpath=\
${base}/CopyLibs/org-netbeans-modules-java-j2seproject-copylibstask.jar ${base}/CopyLibs/org-netbeans-modules-java-j2seproject-copylibstask.jar
libs.junit.classpath=\ libs.junit.classpath=\
${base}/junit/junit-3.8.2.jar ${base}/junit/junit-3.8.2.jar
libs.junit.javadoc=\ libs.junit.javadoc=\
${base}/junit/junit-3.8.2-api.zip ${base}/junit/junit-3.8.2-api.zip
libs.junit_4.classpath=\ libs.junit_4.classpath=\
${base}/junit_4/junit-4.5.jar ${base}/junit_4/junit-4.5.jar
libs.junit_4.javadoc=\ libs.junit_4.javadoc=\
${base}/junit_4/junit-4.5-api.zip ${base}/junit_4/junit-4.5-api.zip
libs.junit_4.src=\ libs.junit_4.src=\
${base}/junit_4/junit-4.5-src.jar ${base}/junit_4/junit-4.5-src.jar