mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Added dummy getPlayer() to BlockBrokenEvent and BlockPlacedEvent in order to get WorldEdit to compile.
By: sk89q <the.sk89q@gmail.com>
This commit is contained in:
parent
089d7906b9
commit
c8ade7e5bb
2 changed files with 12 additions and 0 deletions
|
@ -1,13 +1,19 @@
|
||||||
package org.bukkit.event.block;
|
package org.bukkit.event.block;
|
||||||
|
|
||||||
import org.bukkit.Block;
|
import org.bukkit.Block;
|
||||||
|
import org.bukkit.Player;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Not implemented yet
|
* Not implemented yet
|
||||||
*/
|
*/
|
||||||
public class BlockBrokenEvent extends BlockEvent {
|
public class BlockBrokenEvent extends BlockEvent {
|
||||||
|
private Player player;
|
||||||
|
|
||||||
public BlockBrokenEvent(Type type, Block block ) {
|
public BlockBrokenEvent(Type type, Block block ) {
|
||||||
super(type, block);
|
super(type, block);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Player getPlayer() {
|
||||||
|
return player;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
package org.bukkit.event.block;
|
package org.bukkit.event.block;
|
||||||
|
|
||||||
import org.bukkit.Block;
|
import org.bukkit.Block;
|
||||||
|
import org.bukkit.Player;
|
||||||
import org.bukkit.event.Cancellable;
|
import org.bukkit.event.Cancellable;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -8,6 +9,7 @@ import org.bukkit.event.Cancellable;
|
||||||
*/
|
*/
|
||||||
public class BlockPlacedEvent extends BlockEvent implements Cancellable {
|
public class BlockPlacedEvent extends BlockEvent implements Cancellable {
|
||||||
private boolean cancel;
|
private boolean cancel;
|
||||||
|
private Player player;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param type
|
* @param type
|
||||||
|
@ -18,6 +20,10 @@ public class BlockPlacedEvent extends BlockEvent implements Cancellable {
|
||||||
cancel = false;
|
cancel = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Player getPlayer() {
|
||||||
|
return player;
|
||||||
|
}
|
||||||
|
|
||||||
public boolean isCancelled() {
|
public boolean isCancelled() {
|
||||||
// TODO Auto-generated method stub
|
// TODO Auto-generated method stub
|
||||||
return cancel;
|
return cancel;
|
||||||
|
|
Loading…
Reference in a new issue