Interface SpawnLocation

All Known Implementing Classes:
Government, Nation, Town

public interface SpawnLocation
Provides the spawn location and access to setter for spawn locations.
  • Method Summary

    Modifier and Type
    Method
    Description
    @NotNull org.bukkit.Location
    Get the spawn location of this object.
    default @Nullable org.bukkit.Location
     
    default boolean
    Checks whether a spawn point exists.
    void
    setSpawn(@Nullable org.bukkit.Location spawn)
    Sets the spawn point of this object.
  • Method Details

    • getSpawn

      @NotNull @NotNull org.bukkit.Location getSpawn() throws TownyException
      Get the spawn location of this object.
      Returns:
      The spawn location
      Throws:
      TownyException - If no location is found.
    • hasSpawn

      default boolean hasSpawn()
      Checks whether a spawn point exists.
      Returns:
      A boolean indicating if the spawn exists.
    • setSpawn

      void setSpawn(@Nullable @Nullable org.bukkit.Location spawn) throws TownyException
      Sets the spawn point of this object.
      Parameters:
      spawn - The Location of the new spawn.
      Throws:
      TownyException - If the spawn could not be set.
    • getSpawnOrNull

      @Nullable default @Nullable org.bukkit.Location getSpawnOrNull()