Class PlayerCreativeTerrainEditEvent

All Implemented Interfaces:
Cancellable

public final class PlayerCreativeTerrainEditEvent extends PlayerWorldEditEvent
Called when a player uses the creative terrain edit tools (F5) to edit the terrain (e.g remove, place, smooth etc).
  • Method Details

    • getTerrainID

      public int getTerrainID()
      Gets the terrain id the player wants to place.
      Returns:
      the terrain id.
    • setTerrainID

      public void setTerrainID(int terrainID)
      Changes the terrain id to another id.
      Parameters:
      terrainID - the new terrain id.
    • getCreativeEditMode

      public PlayerCreativeTerrainEditEvent.EditMode getCreativeEditMode()
      Gets the edit mode, i.e the terrain edit sub tool (Add, Subtract, Paint, Smooth etc).
      Returns:
      the creative mode terrain edit tool.
    • getBrushSize

      public int getBrushSize()
      Gets the size of the brush.
      Returns:
      the brush size.