Player Details

Overview
Player details allow you to display custom information about players in the pause menu. This feature is highly customizable and can show various player statistics like money, bank balance, job information, or any other server-specific data.
1. Defining Player Details in Customize.lua
Edit the PlayerDetails
section in the Customize.lua
file to adjust how you want to display player details.
PlayerDetails = {
icon = 'money.svg', -- icon file path (resources/images/PlayerDetails)
header = 'Money', -- header (e.g., "Money")
event = 'GetMoney' -- event to be called (defined in server/function.lua)
}
Configuration Parameters
icon
String
Icon filename (stored in resources/images/PlayerDetails
)
header
String
Display name/title for this detail
event
String
Function name in server/function.lua
to fetch the data
Important: The event name in PlayerDetails
must match the function name in server/function.lua
exactly.
2. Defining the Function in server/function.lua
Add the relevant function to the server/function.lua
file to define how to obtain player details on the server side.
GetMoney = function(Player, data)
return '$ ' .. Player?.PlayerData?.money?.cash
end
Function Parameters
Player
Object
Player object containing all player data
data
Object
Content of PlayerDetails
(icon, header, event)
Example Functions
GetMoney = function(Player, data)
return '$ ' .. Player?.PlayerData?.money?.cash
end
3. Multiple Player Details
You can display multiple player details by creating an array of detail objects:
PlayerDetails = {
{
icon = 'money.svg',
header = 'Cash',
event = 'GetMoney'
},
{
icon = 'bank.svg',
header = 'Bank',
event = 'GetBank'
},
{
icon = 'job.svg',
header = 'Job',
event = 'GetJob'
}
}
Pro Tip: You can add as many player details as needed. Each will be displayed as a separate section in the pause menu.
4. Icon Customization
Icon Requirements
Format: SVG (recommended) or PNG
Size: 24x24 pixels or larger
Location:
resources/images/PlayerDetails/
Style: Simple, clean icons work best
Available Default Icons
money.svg
Cash/Money display
bank.svg
Bank balance
job.svg
Job information
level.svg
Player level
health.svg
Health status
5. Testing Your Customizations
After making all the adjustments, verify in-game that the information is displayed correctly.
Troubleshooting Steps
Check Console: Look for any Lua errors
Verify Function Names: Ensure event names match function names
Test Data: Make sure the player data structure is correct
Icon Paths: Verify icon files exist in the correct directory
Example Debugging Function
GetMoney = function(Player, data)
print('Player Data:', json.encode(Player?.PlayerData))
local cash = Player?.PlayerData?.money?.cash or 0
print('Cash Amount:', cash)
return '$ ' .. cash
end
Related Pages
Custom PagesSocial Online TimeLast updated
Was this helpful?