-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Preliminary work for #90
- Loading branch information
Showing
9 changed files
with
77 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
bukkit/src/main/java/org/popcraft/bolt/event/Cancellable.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package org.popcraft.bolt.event; | ||
|
||
public abstract class Cancellable implements Event { | ||
private boolean cancelled; | ||
|
||
public boolean isCancelled() { | ||
return cancelled; | ||
} | ||
|
||
public void setCancelled(final boolean cancelled) { | ||
this.cancelled = cancelled; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
package org.popcraft.bolt.event; | ||
|
||
public interface Event { | ||
} |
22 changes: 22 additions & 0 deletions
22
bukkit/src/main/java/org/popcraft/bolt/event/LockBlockEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package org.popcraft.bolt.event; | ||
|
||
import org.bukkit.block.Block; | ||
import org.bukkit.entity.Player; | ||
|
||
public class LockBlockEvent extends Cancellable implements Event { | ||
private final Player player; | ||
private final Block block; | ||
|
||
public LockBlockEvent(Player player, Block block) { | ||
this.player = player; | ||
this.block = block; | ||
} | ||
|
||
public Player getPlayer() { | ||
return this.player; | ||
} | ||
|
||
public Block getBlock() { | ||
return this.block; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters