Class PressurePlate
java.lang.Object
me.block2block.hubparkour.api.plates.PressurePlate
- Direct Known Subclasses:
BorderPoint,Checkpoint,EndPoint,ExitPoint,RestartPoint,StartPoint
Represents a generic pressure plate.
WARNING: never create PressurePlate objects. Always extend this class.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThe location the pressure plate it located.Get the type of material the pressure plate has.Get the parkour the pressure plate belongs to.Retrieves the commands associated with the pressure plate.abstract intgetType()The type of pressure plate.voidPlaces the pressure plate material on the block the pressure plate is located at.voidRemove the material by setting it to air.voidsetParkour(IParkour parkour) Set the parkour the pressure plate belongs to.voidsetRewards(List<String> rewards) Sets the commands associated with the pressure plate.
-
Field Details
-
location
-
parkour
-
material
-
rewards
-
-
Constructor Details
-
PressurePlate
-
-
Method Details
-
setParkour
Set the parkour the pressure plate belongs to.WARNING: It is not recommended that you use this once the parkour has been setup.
- Parameters:
parkour- the parkour it belongs to.
-
getLocation
The location the pressure plate it located.- Returns:
- the location of the pressure plate.
-
getType
public abstract int getType()The type of pressure plate. This is just an arbitrary value.Default ID's: 0 - Start Point 1 - End Point 2 - Restart Point 3 - Checkpoint 4 - Border Point 5 - Exit Point
- Returns:
- the pressure plate type
-
getMaterial
Get the type of material the pressure plate has.- Returns:
- Material type.
-
placeMaterial
public void placeMaterial()Places the pressure plate material on the block the pressure plate is located at. -
removeMaterial
public void removeMaterial()Remove the material by setting it to air. -
getParkour
Get the parkour the pressure plate belongs to.- Returns:
- the parkour it belongs to.
-
getRewards
-
setRewards
-