Package dev.kitteh.factions
Interface Faction.Zone
- All Known Implementing Classes:
MemoryFaction.Zone
- Enclosing interface:
Faction
public static interface Faction.Zone
An individual zone.
-
Method Summary
Modifier and TypeMethodDescriptionbooleancanPlayerManage(FPlayer fPlayer) Gets if the given player can manage this zone, meaning they have the ZONE permission for specifically this zone (if not overridden).net.kyori.adventure.text.Componentgreeting()Gets the zone's greeting.voidSets the zone's greeting in MiniMessage format.@Nullable StringGets the zone's raw MiniMessage greeting.intid()Gets the zone's internal ID.name()Gets the zone's name.voidSets the zone's name.Gets the zone's permissions.
-
Method Details
-
id
int id()Gets the zone's internal ID.- Returns:
- zone id
-
name
String name()Gets the zone's name.- Returns:
- zone name
-
name
Sets the zone's name.- Parameters:
name- new name
-
greeting
net.kyori.adventure.text.Component greeting()Gets the zone's greeting.- Returns:
- greeting
-
greetingString
@Nullable String greetingString()Gets the zone's raw MiniMessage greeting.- Returns:
- MiniMessage greeting or null if the zone uses the main zone's greeting
-
greeting
Sets the zone's greeting in MiniMessage format. Takes the 'tag' placeholder to inject the faction tag. If null, will default to the main zone's greeting.- Parameters:
greeting- new greeting- Throws:
IllegalArgumentException- if sending null for the main zone
-
permissions
Faction.Permissions permissions()Gets the zone's permissions.- Returns:
- zone permissions
-
canPlayerManage
Gets if the given player can manage this zone, meaning they have the ZONE permission for specifically this zone (if not overridden).- Parameters:
fPlayer- player- Returns:
- true if can manage
-