Interface Faction.Zone

All Known Implementing Classes:
MemoryFaction.Zone
Enclosing interface:
Faction

public static interface Faction.Zone
An individual zone.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    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.Component
    Gets the zone's greeting.
    void
    greeting(@Nullable String greeting)
    Sets the zone's greeting in MiniMessage format.
    @Nullable String
    Gets the zone's raw MiniMessage greeting.
    int
    id()
    Gets the zone's internal ID.
    Gets the zone's name.
    void
    name(String name)
    Sets 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

      void name(String 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

      void greeting(@Nullable String 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

      boolean canPlayerManage(FPlayer fPlayer)
      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