public class IslandChangeGeneratorRateEvent extends IslandEvent implements org.bukkit.event.Cancellable
island
Constructor and Description |
---|
IslandChangeGeneratorRateEvent(SuperiorPlayer superiorPlayer,
Island island,
Key block,
org.bukkit.World.Environment environment,
int generatorRate)
The constructor of the event.
|
Modifier and Type | Method and Description |
---|---|
Key |
getBlock()
Get the block that the generator-rate was changed for.
|
org.bukkit.World.Environment |
getEnvironment()
Get the environment of the world that the rate was changed for.
|
int |
getGeneratorRate()
Get the new generator-rate of the block.
|
SuperiorPlayer |
getPlayer()
Get the player that changed the generator-rate.
|
boolean |
isCancelled() |
void |
setCancelled(boolean cancelled) |
void |
setGeneratorRate(int generatorRate)
Set the new generator-rate of the block.
|
getHandlerList, getHandlers, getIsland
public IslandChangeGeneratorRateEvent(@Nullable SuperiorPlayer superiorPlayer, Island island, Key block, org.bukkit.World.Environment environment, int generatorRate)
superiorPlayer
- The player that changed the generator-rate of an island.
If set to null, it means the rate was changed via the console.island
- The island that the generator-rate was changed for.block
- The block that the rate was changed for.environment
- The environment of the world that the rate was changed for.generatorRate
- The new generator-rate of the block.@Nullable public SuperiorPlayer getPlayer()
public Key getBlock()
public org.bukkit.World.Environment getEnvironment()
public int getGeneratorRate()
public void setGeneratorRate(int generatorRate)
generatorRate
- The new generator-rate to set.public boolean isCancelled()
isCancelled
in interface org.bukkit.event.Cancellable
public void setCancelled(boolean cancelled)
setCancelled
in interface org.bukkit.event.Cancellable