Interface KonquestRuinManager
public interface KonquestRuinManager
A manager for ruins in Konquest.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Adds a new ruin at the given location with the given name.Gets a ruin by the given name.org.bukkit.Material
Gets the ruin critical block material.A convenience method for getting all ruin names.Collection<? extends KonquestRuin>
getRuins()
Gets all ruins.boolean
isLocInsideRuin
(KonquestRuin ruin, org.bukkit.Location loc) Checks whether the given location is inside of the given ruin.boolean
Checks whether the given name is a ruin.boolean
removeRuin
(String name) Removes a ruin by the given name.
-
Method Details
-
isRuin
Checks whether the given name is a ruin.- Parameters:
name
- The name of the ruin, case-insensitive- Returns:
- True when the name matches a ruin, else false
-
isLocInsideRuin
Checks whether the given location is inside of the given ruin.- Parameters:
ruin
- The ruin to checkloc
- The location- Returns:
- True when the location is inside of the ruin, else false
-
addRuin
Adds a new ruin at the given location with the given name. The chunk of the location will be the initial claim of the new ruin.- Parameters:
loc
- The center location of the new ruinname
- The name of the new ruin- Returns:
- True when the ruin is successfully created, else false
-
removeRuin
Removes a ruin by the given name.- Parameters:
name
- The ruin name- Returns:
- True when the ruin is successfully removed, else false
-
getRuin
Gets a ruin by the given name.- Parameters:
name
- The ruin name- Returns:
- The corresponding ruin instance
-
getRuins
Collection<? extends KonquestRuin> getRuins()Gets all ruins.- Returns:
- A collection of all ruin instances
-
getRuinNames
A convenience method for getting all ruin names.- Returns:
- A set of all ruin names
-
getRuinCriticalBlock
org.bukkit.Material getRuinCriticalBlock()Gets the ruin critical block material. This is the block type that must be destroyed within ruins in order to earn rewards.- Returns:
- The critical material
-