summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordurron597 <martin.jared@gmail.com>2010-12-31 09:09:02 -0500
committerdurron597 <martin.jared@gmail.com>2010-12-31 09:09:02 -0500
commit055c64106dd29a4da04e5f86e69fc452217d9c95 (patch)
treec441dfa4cd0dff52b0374e7cca9bd81f65242ecf
parenta8b7a63a8e342a0165f43d550ef8cf870fc6e41d (diff)
downloadbukkit-055c64106dd29a4da04e5f86e69fc452217d9c95.tar
bukkit-055c64106dd29a4da04e5f86e69fc452217d9c95.tar.gz
bukkit-055c64106dd29a4da04e5f86e69fc452217d9c95.tar.lz
bukkit-055c64106dd29a4da04e5f86e69fc452217d9c95.tar.xz
bukkit-055c64106dd29a4da04e5f86e69fc452217d9c95.zip
Implemented BlockRightClickedEvent
-rw-r--r--src/org/bukkit/event/block/BlockRightClickedEvent.java43
1 files changed, 37 insertions, 6 deletions
diff --git a/src/org/bukkit/event/block/BlockRightClickedEvent.java b/src/org/bukkit/event/block/BlockRightClickedEvent.java
index 730d6879..4f43492c 100644
--- a/src/org/bukkit/event/block/BlockRightClickedEvent.java
+++ b/src/org/bukkit/event/block/BlockRightClickedEvent.java
@@ -4,19 +4,50 @@
package org.bukkit.event.block;
import org.bukkit.Block;
+import org.bukkit.BlockFace;
+import org.bukkit.ItemStack;
+import org.bukkit.Player;
/**
- * Not implemented yet
+ * @author durron597
*/
public class BlockRightClickedEvent extends BlockEvent {
-
+ protected Player clicker;
+ protected BlockFace direction;
+ protected ItemStack clickedWith;
+
/**
- * @param type
- * @param theBlock
+ * @param type The type of event this is
+ * @param theBlock The clicked block
+ * @param direction The face we clicked from
+ * @param clicker The player who clicked a block
+ * @param clickedWith Item in player's hand
*/
- public BlockRightClickedEvent(Type type, Block theBlock) {
+ public BlockRightClickedEvent(Type type, Block theBlock, BlockFace direction, Player clicker, ItemStack clickedWith) {
super(type, theBlock);
- // TODO Auto-generated constructor stub
+ this.direction = direction;
+ this.clicker = clicker;
+ this.clickedWith = clickedWith;
+ }
+
+ /**
+ * @return the clicker
+ */
+ public Player getClicker() {
+ return clicker;
+ }
+
+ /**
+ * @return the direction
+ */
+ public BlockFace getDirection() {
+ return direction;
}
+ /**
+ * @return the clickedWith
+ */
+ public ItemStack getClickedWith() {
+ return clickedWith;
+ }
}