Class HouseUtilities

java.lang.Object
games.stendhal.server.maps.quests.houses.HouseUtilities

public class HouseUtilities extends Object
  • Method Details

    • clearCache

      public static void clearCache()
      clears the house cache
    • getPlayersHouse

      protected static HousePortal getPlayersHouse(Player player)
      Get the house owned by a player.
      Parameters:
      player - the player to be examined
      Returns:
      portal to the house owned by the player, or null if he does not own one.
    • playerOwnsHouse

      protected static boolean playerOwnsHouse(Player player)
      Check if a player owns a house.
      Parameters:
      player - the player to be checked
      Returns:
      true if the player owns a house, false otherwise
    • getHousePortal

      protected static HousePortal getHousePortal(int houseNumber)
      Find a portal corresponding to a house number.
      Parameters:
      houseNumber - the house number to find
      Returns:
      the portal to the house, or null if there is no house by number id
    • getHousePortals

      protected static List<HousePortal> getHousePortals()
      Get a list of all house portals available to players.
      Returns:
      list of all house portals
    • findChest

      protected static StoredChest findChest(HousePortal portal)
      Find a chest corresponding to a house portal.
      Parameters:
      portal - the house portal of the house containing the chest we want to find
      Returns:
      the chest in the house, or null if there is no chest in the zone which the house portal leads to (Note, then, that chests should be on the 'ground floor')
    • getUnboughtHousesInLocation

      protected static List<String> getUnboughtHousesInLocation(String location)