Configuration
There are lots of configuration options available in PointShop. The page below describes the options and what they're used for. All configuration options are required.
PS.Config.DataProvider
Type: String
Description: Sets the Data Provider to use.
PS.Config.DataProvider = 'pdata'
PS.Config.Branch
Type: String
Description: Sets the url to check for updates from.
PS.Config.Branch = 'https://raw.github.com/adamdburton/pointshop/master/'
PS.Config.CheckVersion
Type: Boolean
Description: Sets whether to check for updates.
PS.Config.CheckVersion = true
PS.Config.ShopKey
Type: String
Description: Sets the key to use for opening the PointShop menu.
PS.Config.ShopKey = 'F3'
PS.Config.ShopCommand
Type: String
Description: Sets the console to opening the PointShop menu.
PS.Config.ShopCommand = 'ps_shop'
PS.Config.ShopChatCommand
Type: String
Description: Sets the chat command to open the PointShop menu.
PS.Config.ShopChatCommand = '!shop'
PS.Config.NotifyOnJoin
Type: Boolean
Description: Sets whether to nofify players how to open the PointShop menu when the join.
PS.Config.NotifyOnJoin = true
PS.Config.PointsOverTime
Type: Boolean
Description: Sets whether to give points to player whilst they are in the server, on a timer.
PS.Config.PointsOverTime = true
PS.Config.PointsOverTimeDelay
Type: Number
Description: Sets the delay between giving points to connected players, in minutes.
PS.Config.PointsOverTimeDelay = 1
PS.Config.PointsOverTimeAmount
Type: Number
Description: Sets the number of points to give after the PS.Config.PointsOverTimeDelay.
PS.Config.PointsOverTimeAmount = 1
PS.Config.AdminCanAccessAdminTab
Type: Boolean
Description: Sets whether Admins can access the administration tab in the PointShop menu.
PS.Config.AdminCanAccessAdminTab = true
PS.Config.SuperAdminCanAccessAdminTab
Type: Boolean
Description: Sets whether Super Admins can access the administration tab in the PointShop menu.
PS.Config.SuperAdminCanAccessAdminTab = true
PS.Config.CanPlayersGivePoints
Type: Boolean
Description: Sets whether players can give their points to other players.
PS.Config.CanPlayersGivePoints = true
PS.Config.DisplayPreviewInMenu
Type: Boolean
Description: Sets whether the hovering items in the PointShop menu shows a preview.
PS.Config.DisplayPreviewInMenu = true
PS.Config.PointsName
Type: String
Description: Sets the name of points. Used in the PointShop menu and all notifications.
PS.Config.PointsName = 'Points'
PS.Config.SortItemsBy
Type: String
Description: Sets the field to sort items by in the PointShop menu.
PS.Config.SortItemsBy = 'Name'
PS.Config.CalculateBuyPrice
Arguments: Player ply, ITEM item
Realm: Server
Type: Function
Description: Calculate the price a player should be charged to buy an item.
PS.Config.CalculateBuyPrice = function(ply, item)
return item.Price
end
PS.Config.CalculateSellPrice
Arguments: Player ply, ITEM item
Realm: Server
Type: Function
Description: Calculate the price a player can sell an item for.
PS.Config.CalculateSellPrice = function(ply, item)
return math.Round(item.Price * 0.75)
end