summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2011-06-23 15:02:05 +0200
committersnowleo <schneeleo@gmail.com>2011-06-23 15:02:05 +0200
commitb9e56d100c00390c180e68dcea52f1eda7b90d82 (patch)
tree93dfb922042499bda8b1b7dceb5338edbca4a02b
parent0a924bf22604cf863adbe23fdc9735e72bd3a283 (diff)
downloadEssentials-b9e56d100c00390c180e68dcea52f1eda7b90d82.tar
Essentials-b9e56d100c00390c180e68dcea52f1eda7b90d82.tar.gz
Essentials-b9e56d100c00390c180e68dcea52f1eda7b90d82.tar.lz
Essentials-b9e56d100c00390c180e68dcea52f1eda7b90d82.tar.xz
Essentials-b9e56d100c00390c180e68dcea52f1eda7b90d82.zip
/antioch now uses bukkit code
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandantioch.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java b/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
index b30799adf..4dd3042d0 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandantioch.java
@@ -1,12 +1,10 @@
package com.earth2me.essentials.commands;
-import net.minecraft.server.EntityTNTPrimed;
-import net.minecraft.server.World;
import org.bukkit.Location;
import org.bukkit.Server;
-import org.bukkit.craftbukkit.CraftWorld;
import com.earth2me.essentials.User;
import com.earth2me.essentials.TargetBlock;
+import org.bukkit.entity.TNTPrimed;
public class Commandantioch extends EssentialsCommand
@@ -17,16 +15,13 @@ public class Commandantioch extends EssentialsCommand
}
@Override
- public void run(Server server, User user, String commandLabel, String[] args) throws Exception
+ public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception
{
charge(user);
ess.broadcastMessage(user.getName(), "...lobbest thou thy Holy Hand Grenade of Antioch towards thy foe,");
ess.broadcastMessage(user.getName(), "who being naughty in My sight, shall snuff it.");
- final World world = ((CraftWorld)user.getWorld()).getHandle();
final Location loc = new TargetBlock(user).getTargetBlock().getLocation();
- final EntityTNTPrimed tnt = new EntityTNTPrimed(world, loc.getBlockX(), loc.getBlockY(), loc.getBlockZ());
- world.addEntity(tnt);
- world.makeSound(tnt, "random.fuse", 1.0F, 1.0F);
+ loc.getWorld().spawn(loc, TNTPrimed.class);
}
}