public class ShopUtils extends Object
Constructor and Description |
---|
ShopUtils() |
Modifier and Type | Method and Description |
---|---|
static void |
addShop(Shop shop,
boolean addToDatabase)
Add a shop
|
static Shop |
getShop(org.bukkit.Location location)
Get the shop at a given location
|
static int |
getShopAmount(org.bukkit.OfflinePlayer p)
Get the amount of shops of a player
|
static int |
getShopLimit(org.bukkit.entity.Player p)
Get the shop limits of a player
|
static Shop[] |
getShops()
Get all Shops
|
static boolean |
isShop(org.bukkit.Location location)
Checks whether there is a shop at a given location
|
static int |
reloadShops()
Reload the shops
|
static void |
removeShop(Shop shop,
boolean removeFromDatabase)
Remove a shop
|
public static Shop getShop(org.bukkit.Location location)
location
- Location of the shoppublic static boolean isShop(org.bukkit.Location location)
location
- Location to checkpublic static Shop[] getShops()
public static void addShop(Shop shop, boolean addToDatabase)
shop
- Shop to addaddToDatabase
- Whether the shop should also be added to the databasepublic static void removeShop(Shop shop, boolean removeFromDatabase)
shop
- Shop to removeremoveFromDatabase
- Whether the shop should also be removed from the databasepublic static int getShopLimit(org.bukkit.entity.Player p)
p
- Player, whose shop limits should be returnedpublic static int getShopAmount(org.bukkit.OfflinePlayer p)
p
- Player, whose shops should be countedConfig.exclude_admin_shops
is true, admin shops won't be counted)public static int reloadShops()
Copyright © 2016. All rights reserved.