JRS COREDokumentacja
Dokumentacja API

core

API reference for core

Warning

This documentation is for developers who are making scripts for JRS Core Framework

Export#

GetCore is a shared export that returns the core table containing all the getters and setters for JRS Core. some of the getters and setters are client side only and some are server side only.

Note

Shared

GetCore#
returntable

The core table containing all the getters and setters.

lua
local Core = exports.jrs_core:GetCore()

Register Server Jobs#

Allowing you to only give correct jobs and grades to the players and to prevent them from using incorrect jobs and grades.

Note

Server Side

RegisterJobs#

Register jobs to the server, this will be stored in config/jobs.lua file in jrs core then can be registered automatically using the RegisterJobs function or manually by adding the jobs to the lua file.

jobsDatatablerequired

job data is a table with the following keys:

  • jobname: string job name as the key and the job data as the value.
  • groups: array optional, if you wish to set this job to only this group can give this job.
  • privateJob: boolean if true, the job will be private no one can give this job.
  • grades: table only add grades if you use grades
  • [grade]: table grade number as the key and the grade data as the value.
  • label: string the label of the grade
  • privateGrade: boolean if true, the grade will be private no one can give this grade.
resourceNamestringrequired

The resource name to register the jobs to for debug

lua
local jobsData <const> = {
    jobname = {
        groups = {"admin"} -- optional, if you wish to set this job to only this group can give this job.
        privateJob = true -- if true, the job will be private no one can give this job.
        grades = { -- only add grades if you use grades
            [1] = {
                label = "Grade Label"
                privateGrade = true -- if true, the grade will be private no one can give this grade.
            }
        }
    }
}

if Core.RegisterJobs then
    Core.RegisterJobs(jobsData, GetCurrentResourceName())
else
    print("Core.RegisterJobs is not available update jrs core to the latest version")
end

Notifications#

notifications can also accept -1 as duration to always stay on screen and to clear them you need to use UiFeedClearChannel

Note

Shared

NotifyLeft#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationnumberrequired

Duration in milliseconds

colorstringrequired

Color of the notification

lua
Core.NotifyLeft("title", "subtitle", "dict", "icon", 4000, "color")
NotifyTip#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyTip("title", 4000)
NotifyRightTip#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyRightTip("title", 4000)
NotifyObjective#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyObjective("title", 4000)
NotifyTop#
titlestringrequired

The title of the notification

locationstringrequired

The location to display

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyTop("title", "location", 4000)
NotifySimpleTop#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifySimpleTop("title", "subtitle", 4000)
NotifyAvanced#
titlestringrequired

The title of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

colorstringrequired

Color of the notification

durationnumberrequired

Duration in milliseconds

qualitynumberrequired

enables the stars for quality like animal pelt stars

showQualitybooleanrequired

shows the quality of the notification

lua
Core.NotifyAvanced("title", "dict", "icon", "color", 4000, quality, showQuality)
NotifyCenter#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyCenter("title", 4000)
NotifyBottomRight#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyBottomRight("title", 4000)
NotifyFail#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyFail("title", "subtitle", 4000)
NotifyDead#
titlestringrequired

The title of the notification

audiorefstringrequired

The audio reference

audionamestringrequired

The audio name

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyDead("title", "audioref", "audioname", 4000)
NotifyUpdate#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyUpdate("title", "subtitle", 4000)
NotifyWarning#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

audiorefstringrequired

The audio reference

audionamestringrequired

The audio name

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyWarning("title", "subtitle", "audioref", "audioname", 4000)
NotifyLeftRank#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationnumberrequired

Duration in milliseconds

colorstringrequired

Color of the notification

lua
Core.NotifyLeftRank("title", "subtitle", "dict", "icon", 4000, "color")
NotifyOneSimpleTop#
titlestringrequired

The title of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyOneSimpleTop("title", 4000)
NotifyThreeSimpleTop#
titlestringrequired

The title of the notification

descriptionstringrequired

The description of the notification

second_descriptionstringrequired

The second description of the notification

durationnumberrequired

Duration in milliseconds

lua
Core.NotifyThreeSimpleTop("title","description","second_description", 4000)
NotifyLeftInteractive#
titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationnumberrequired

Duration in milliseconds or -1 for infinite

colorstringrequired

Color of the notification

lua
Core.NotifyLeftInteractive("title", "subtitle", "dict", "icon", 4000, "color")
NotifyTip#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyTip(source, "title", 4000)
NotifyLeft#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationintegerrequired

Duration in milliseconds

colorstringrequired

Color of the notification

lua
Core.NotifyLeft(source, "title", "subtitle", "dict", "icon", 4000, "color")
NotifyRightTip#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyRightTip(source, "title", 4000)
NotifyObjective#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyObjective(source, "title", 4000)
NotifyTop#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

locationstringrequired

The location to display

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyTop(source, "title", "location", 4000)
NotifySimpleTop#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifySimpleTop(source, "title", "subtitle", 4000)
NotifyAvanced#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

colorstringrequired

Color of the notification

durationintegerrequired

Duration in milliseconds

showQualitybooleanrequired

Show the quality of the notification

qualitynumberrequired

The quality of the notification max 3

lua
Core.NotifyAvanced(source, "title", "dict", "icon", "color",showQuality,quality, 4000)
NotifyCenter#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyCenter(source, "title", 4000)
NotifyBottomRight#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyBottomRight(source, "title", 4000)
NotifyFail#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyFail(source, "title", "subtitle", 4000)
NotifyDead#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

audiorefstringrequired

The audio reference

audionamestringrequired

The audio name

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyDead(source, "title", "audioref", "audioname", 4000)
NotifyUpdate#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyUpdate(source, "title", "subtitle", 4000)
NotifyWarning#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

audiorefstringrequired

The audio reference

audionamestringrequired

The audio name

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyWarning(source, "title", "subtitle", "audioref", "audioname", 4000)
NotifyLeftRank#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationintegerrequired

Duration in milliseconds

colorstringrequired

Color of the notification

lua
Core.NotifyLeftRank(source, "title", "subtitle", "dict", "icon", 4000, "color")
NotifyOneSimpleTop#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyOneSimpleTop(source, "title", 4000)
NotifyThreeSimpleTop#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

descriptionstringrequired

The description of the notification

second_descriptionstringrequired

The second description of the notification

durationintegerrequired

Duration in milliseconds

lua
Core.NotifyThreeSimpleTop(source, "title","description","second_description", 4000)
NotifyLeftInteractive#
sourceintegerrequired

The player ID

titlestringrequired

The title of the notification

subtitlestringrequired

The subtitle of the notification

dictstringrequired

The dictionary for the icon

iconstringrequired

The icon name

durationintegerrequired

Duration in milliseconds or -1 for infinite

colorstringrequired

Color of the notification

lua
Core.NotifyLeftInteractive(source, "title", "subtitle", "dict", "icon", 4000, "color")

Characters#

Get the character data to access getters and setters

Note

Server

getUsedCharacter#
sourceintegerrequired

The player ID

lua
    local user = Core.getUser(source) --[[@as User]]  
    if not user then return end -- is player in session?
    local character = user.getUsedCharacter --[[@as Character]]
identifier#
returnstring

The unique identifier of the character

lua
local identifier = character.identifier
charIdentifier#
returnstring

The unique character identifier

lua
local charIdentifier = character.charIdentifier
group#
returnstring

The group the character belongs to

lua
local group = character.group
multiJobs#
returntable

The multiJobs of the character

lua
local multijobs = character.multiJobs
for _, job in pairs(multiJobs) do   
    print(job.job, job.grade, job.label)
end
job#
returnstring

The job of the character

lua
local job = character.job
jobGrade#
returninteger

The job grade of the character

lua
local jobGrade = character.jobGrade
jobLabel#
returnstring

The job label of the character

lua
local jobLabel = character.jobLabel
money#
returnnumber

The amount of money the character has

lua
local money = character.money
gold#
returnnumber

The amount of gold the character has

lua
local gold = character.gold
rol#
returnnumber

The amount of rol the character has

lua
local rol = character.rol
xp#
returnnumber

The amount of experience points the character has

lua
local xp = character.xp
firstname#
returnstring

The first name of the character

lua
local firstname = character.firstname
lastname#
returnstring

The last name of the character

lua
local lastname = character.lastname
status#
returntable

The status of the character

lua
local status = character.status
coords#
returntable

The coordinates of the character

lua
local coords = character.coords
isdead#
returnboolean

Whether the character is dead or not

lua
local isDead = character.isdead
skin#
returntable

The skin details of the character

lua
local skin = character.skin
comps#
returntable

The component details of the character

lua
local comps = character.comps
age#
returnnumber

The age of the character

lua
local age = character.age
gender#
returnstring

The gender of the character

lua
local gender = character.gender
charDescription#
returnstring

The description of the character

lua
local charDescription = character.charDescription
nickname#
returnstring

The nickname of the character

lua
local nickname = character.nickname
invCapacity#
returnnumber

The inventory capacity of the character

lua
local invCapacity = character.invCapacity
skills#
returntable

The skills of the character

lua
local skills = character.skills
local skill = skills.Crafting
if not skill then return print("skill not found in core config or it doesn't exist") end
local skillExp = skill.Exp
local skillLevel = skill.Level
setJob#
jobstringrequired

The job name to set

flagboolean

If true, the job change event won't be triggered

lua
 character.setJob("job", flag)
setMultiJob#
Warning

Exists for compatibility only: it always returns false. Use exports.jrs_core:AddJob. Use the JRS equivalent from the JRS API page.

multijobs can be added to users and they can switch between them using the switch command in jrs core listen for job change events to know when the user switches jobs

jobstringrequired

The job name to set

gradenumberrequired

The job grade to set

labelstringrequired

The job label to set

lua
character.setMultiJob("job", 1, "label")
removeMultiJob#
Warning

Exists for compatibility only: it always returns false. Use exports.jrs_core:RemoveJob. Use the JRS equivalent from the JRS API page.

jobstringrequired

The job name to remove

lua
character.removeMultiJob("job")
getMultiJobsCount#
returnnumber

The number of multijobs the character has

lua
local multiJobCount = character.getMultiJobsCount()
setJobGrade#
gradenumberrequired

The job grade to set

flagboolean

If true, the job change event won't be triggered

lua
character.setJobGrade(1, flag)
setJobLabel#
labelstringrequired

The job label to set

lua
character.setJobLabel("Label")
setGroup#
groupstringrequired

The group to set

flagboolean

If true, the group change event won't be triggered

lua
character.setGroup("admin", false)
setXp#
amountnumberrequired

Set the amount of XP of the character

lua
character.setXp(5000)
setFirstname#
firstnamestringrequired

Set the first name of the character

lua
character.setFirstname("Sadie")
setLastname#
lastnamestringrequired

Set the last name of the character

lua
character.setLastname("Adler")
addCurrency#
typenumberrequired

The currency type (0 = money, 1 = gold, 2 = rol)

amountnumberrequired

The amount to add to character

lua
character.addCurrency(0, 1000)
removeCurrency#
typenumberrequired

The currency type (0 = money, 1 = gold, 2 = rol)

amountnumberrequired

The amount to remove from character

lua
character.removeCurrency(0, 1000)
addXp#
amountnumberrequired

The amount of XP to add

lua
character.addXp(100)
removeXp#
amountnumberrequired

The amount of XP to remove

lua
character.removeXp(100)
updateInvCapacity#
Warning

Exists for compatibility only: it does nothing in JRS Core. Use the JRS equivalent from the JRS API page.

changenumberrequired

The amount to change the inventory capacity by (can be positive or negative) its also incremental so 1000 will be 1000 + what you already have

lua
character.updateInvCapacity(1) 
setSkills#
skillNamestringrequired

The name of the skill to set, these skillNames will be in JRS Core config skills

valuenumberrequired

the Exp value to be set to the skillName you passed values are incremental so 1000 exp will be 1000 + what you already have

lua
character.setSkills("skillName", 10) -- skillname exp

Users#

Get the user data to access getters and setters

getUser#
sourcenumberrequired

The player ID

lua
local user = Core.getUser(source) --[[@as User]]  
if not user then return end -- is player in session?
getUserByCharId#
charidnumberrequired

The character ID

lua
local user = Core.getUserByCharId(charid) --[[@as User]]
getGroup#
returnstring

The user group (not character group)

lua
local userGroup = user.getGroup
source#
returninteger

The user's source (player ID)

lua
local userSource = user.source
maxJobsAllowed#
returnnumber

The maximum number of jobs allowed for the user

lua
local maxJobsAllowed = user.maxJobsAllowed
SetGroup#
groupstringrequired

The group to set for the user

lua
user.SetGroup(group)
getIdentifier#
returnnumber

The steam ID of the user

lua
local steam = user.getIdentifier()
getUserCharacters#
returntable

All characters of the user

lua
local data = user.getUserCharacters()
getPlayerwarnings#
Warning

Exists for compatibility only: it always returns 0. Use the JRS equivalent from the JRS API page.

returninteger

The warning status of the user

lua
local warnstatus = user.getPlayerwarnings()

Whitelist#

Note

Server

getEntry#
identifierstringrequired

The identifier of the whitelist entry

lua
local data = Core.Whitelist.getEntry(identifier)
print(json.encode(data),{ident = true})
whitelistUser#
identifierstringrequired

The identifier of the whitelist entry

lua
Core.Whitelist.whitelistUser(identifier)
unWhitelistUser#
identifierstringrequired

The identifier of the whitelist entry

lua
Core.Whitelist.unWhitelistUser(identifier)

Webhooks#

Note

Shared

AddWebhook#
Warning

Exists for compatibility only: it does nothing on the client. Use the JRS equivalent from the JRS API page.

titlestringrequired

The title of the webhook

webhookstringrequired

The webhook link

descriptionstringrequired

The description of the webhook

colornumberrequired

The color of the webhook

namestringrequired

The name of the webhook

logostring

The logo of the webhook

footerlogostring

The footerlogo of the webhook

avatarstring

The avatar of the webhook

lua
Core.AddWebhook("title", "webhook", "description", 12345678, "name", "logo", "footerlogo", "avatar")

Instancing#

Note

Client

to add a players to different instances use his server id + instance number to add players to same instance use only the instanceNumber

lua
local instanceNumber = 54123 -- any number
JRScore.instancePlayers(GetPlayerServerId(PlayerId())+ instanceNumber)

remove players from instance

lua
JRScore.instancePlayers(0)

Player#

Available through core export

Note

Server Side
when using these functions you will benefit of the event listeners OnPlayerDeath OnPlayerRevive OnPlayerRespawn

Heal#
sourceintegerrequired

The player ID

lua
Core.Player.Heal(source)
Revive#
sourceintegerrequired

The player ID

lua
Core.Player.Revive(source)
Respawn#
sourceintegerrequired

The player ID

lua
Core.Player.Respawn(source)

Callbacks#

Callbacks are available through core export or single exports

if you need only the call back system

lua
local ServerRPC = exports.jrs_core:ServerRpcCall() --[[@as ServerRPC]] -- for intellisense
TriggerAwait#

trigger a synchronous callback from client to server

namestringrequired

The name of the callback

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
local result =  Core.Callback.TriggerAwait(name,...)
print(result)
TriggerAsync#

trigger an asynchronous callback from client to server

namestringrequired

The name of the callback

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
Core.Callback.TriggerAsync(name, function(result)
  print(result)
 end, ...)
Register#

register a callback on the server to receive a client callback

namestringrequired

The name of the callback

callbackfunctionrequired

The callback function

sourceinteger

The source of the callback

callbackfunction

The callback function

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
Core.Callback.Register(name, function(source,callback,...)
   callback(...)
 end)

if you need only the call back system

lua
local ClientRPC = exports.jrs_core:ClientRpcCall() --[[@as ClientRPC]] -- for intellisense
TriggerAwait#

trigger a server to client callback synchronously

namestringrequired

The name of the callback

sourceinteger

The source of the callback

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
local result = Core.Callback.TriggerAwait(name,source,...)
print(result)
TriggerAsync#

trigger an asynchronous callback from client to server

namestringrequired

The name of the callback

sourceinteger

The source of the callback

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
Core.Callback.TriggerAsync(name, source, function(result)
  print(result)
 end, ...)
Register#

register a callback on the client to receive a server callback

namestringrequired

The name of the callback

callbackfunctionrequired

The callback function

...any

The parameters to pass to the callback

returnany

The result of the callback

lua
Core.Callback.Register(name, function(callback,...)
 callback(...)
end)        

Events#

Event Listeners to detect changes in the player state

when player job and group changes these events are triggered

Note

Server Side

onGroupChange#

lua
AddEventHandler("jrs:playerGroupChange",function(source, newgroup,oldgroup) end)

onJobChange#

lua
AddEventHandler("jrs:playerJobChange", function(source, newjob,oldjob) end)

onJobGradeChange#

lua
AddEventHandler("jrs:playerJobGradeChange",function(source, newjobgrade,oldjobgrade) end)

onPlayerDeath#

when player dies this event is triggered

lua
--CLIENT
AddEventHandler("jrs_core:Client:OnPlayerDeath",function(killerserverid,causeofdeath) end)

--SERVER
RegisterNetEvent("jrs_core:Server:OnPlayerDeath",function(killerserverid,causeofdeath) end)

onPlayerRevive#

when player is revived through JRS Core export this event will trigger

lua
--SERVER
AddEventHandler("jrs_core:Server:OnPlayerRevive",function(source)end)

--CLIENT
RegisterNetEvent("jrs_core:Client:OnPlayerRevive")

onPlayerRespawn#

when player respawns through JRS Core export this event will trigger

lua
--SERVER
AddEventHandler("jrs_core:Server:OnPlayerRespawn"function(source)end)

--CLIENT
RegisterNetEvent("jrs_core:Client:OnPlayerRespawn")

onPlayerHeal#

when player is healed through JRS Core export this event will trigger

lua
--SERVER
AddEventHandler("jrs_core:Server:OnPlayerHeal",function(source) end)
--CLIENT
RegisterNetEvent("jrs_core:Client:OnPlayerHeal")

onSkillLevelChanged#

triggered when a skill (character skills, job levels) goes up or down

lua
--SERVER
AddEventHandler("jrs_core:server:skillLevelChanged", function(source, skillName, newLevel, oldLevel) end)
--CLIENT
RegisterNetEvent("jrs_core:client:skillLevelChanged", function(skillName, newLevel, oldLevel) end)

onCharacterReady#

triggered when the player selected a character and the character is fully loaded. This is the event to use instead of waiting on a spawn

lua
--SERVER
AddEventHandler("jrs_core:server:characterReady", function(source, character) end)
--CLIENT
RegisterNetEvent("jrs_core:client:characterReady", function(charId) end)

onCharacterUnloaded#

triggered when the character is unloaded (logout, character switch, disconnect)

lua
--SERVER
AddEventHandler("jrs_core:server:characterUnloaded", function(source, previousCharacter, reason) end)
--CLIENT
RegisterNetEvent("jrs_core:client:characterUnloaded", function(reason) end)

Dataview#

call dataview in your script fxmanifest

lua
 client_scripts {
    '@jrs_core/client/dataview.lua'
 }

Statebags#

statebag getters that allow you to get the character data

Note

Shared

IsInSession#

is player in session? this will return true when player choose his character

returnboolean

The IsInSession of the character

lua
LocalPlayer.state.IsInSession
FirstName#

get the first name of the character

returnstring

The first name of the character

lua
LocalPlayer.state.Character.FirstName
LastName#

get the last name of the character

returnstring

The last name of the character

lua
LocalPlayer.state.Character.LastName
Job#

get the job of the character

returnstring

The job of the character

lua
LocalPlayer.state.Character.Job
JobLabel#

get the job label of the character

returnstring

The job label of the character

lua
LocalPlayer.state.Character.JobLabel
Grade#

get the grade of the character

returninteger

The grade of the character

lua
LocalPlayer.state.Character.Grade
Group#

get the group of the character

returnstring

The group of the character

lua
LocalPlayer.state.Character.Group
Gender#

get the gender of the character

returnstring

The gender of the character

lua
LocalPlayer.state.Character.Gender
NickName#

get the nickname of the character

returnstring

The nickname of the character

lua
LocalPlayer.state.Character.NickName
Money#

get the money of the character

returninteger

The money of the character

lua
LocalPlayer.state.Character.Money
Gold#

get the gold of the character

returninteger

The gold of the character

lua
LocalPlayer.state.Character.Gold
Rol#

get the rol of the character

returninteger

The rol of the character

lua
LocalPlayer.state.Character.Rol
CharId#

get the charid of the character

returninteger

The charid of the character

lua
LocalPlayer.state.Character.CharId
IsInSession#

is player in session? this will return true when player choose his character

returnboolean

The IsInSession of the character

lua
Player(source).state.IsInSession
FirstName#

get the first name of the character

returnstring

The first name of the character

lua
Player(source).state.Character.FirstName
LastName#

get the last name of the character

returnstring

The last name of the character

lua
Player(source).state.Character.LastName
Job#

get the job of the character

returnstring

The job of the character

lua
Player(source).state.Character.Job
JobLabel#

get the job label of the character

returnstring

The job label of the character

lua
Player(source).state.Character.JobLabel
Grade#

get the grade of the character

returninteger

The grade of the character

lua
Player(source).state.Character.Grade
Group#

get the group of the character

returnstring

The group of the character

lua
Player(source).state.Character.Group
Gender#

get the gender of the character

returnstring

The gender of the character

lua
Player(source).state.Character.Gender
NickName#

get the nickname of the character

returnstring

The nickname of the character

lua
Player(source).state.Character.NickName
Money#

get the money of the character

returninteger

The money of the character

lua
Player(source).state.Character.Money
Gold#

get the gold of the character

returninteger

The gold of the character

lua
Player(source).state.Character.Gold
Rol#

get the rol of the character

returninteger

The rol of the character

lua
Player(source).state.Character.Rol
CharId#

get the charid of the character

returninteger

The charid of the character

lua
Player(source).state.Character.CharId
JRS Core · Darmowy framework RedM open source · stworzony przez JRS TEAM