Client
This page lists all the available client-side events and exports.
Exports (States)
IsPlayerCuffed
Used for checking if player is cuffed
IsPlayerCuffed
Type:
boolean
Default value:
false
Check initiator if cuffed
Params:
None
Returns:
boolean
:true
if player is cuffed, otherwisefalse
.
Example:
-- return: boolean
local isCuffed = exports['rcore_police']:IsPlayerCuffed()
if isCuffed then
print('Player is cuffed')
else
print('Player is not cuffed or an error occurred:', statusOrErr)
end
Check any player on client
Params:
NameTypeDescriptionplayerId
number
ID of player which you want to get state of cuffed
Returns:
boolean
:true
if player is cuffed, otherwisefalse
.
Example:
-- playerId: number
-- return: boolean
local isCuffed = exports['rcore_police']:IsPlayerCuffed(playerId)
if isCuffed then
print('Player is cuffed')
else
print('Player is not cuffed or an error occurred:', statusOrErr)
end
IsPlayerEscorted
Used for checking if player is escorted
IsPlayerEscorted
Type:
boolean
Default value:
false
Check initiator if escorted
Params:
None
Returns:
boolean
:true
if player is escorted, otherwisefalse
.
Example:
-- return: boolean
local isEscorted = exports['rcore_police']:IsPlayerEscorted()
if isEscorted then
print('Player is escorted')
else
print('Player is not escorted')
end
Check any player on client
Params:
NameTypeDescriptionplayerId
number
ID of player which you want to get state of escorted
Returns:
boolean
:true
if player is escorted, otherwisefalse
.
Example:
-- playerId: number
-- return: boolean
local isEscorted = exports['rcore_police']:IsPlayerEscorted(playerId)
if isEscorted then
print('Player is escorted')
else
print('Player is not escorted')
end
IsPlayerHeadBagged
IsPlayerHeadBagged
Type:
boolean
Default value:
false
Check initiator if IsPlayerHeadBagged
Params:
None
Returns:
boolean
:true
if player is IsPlayerHeadBagged, otherwisefalse
.
Example:
-- return: boolean
local isHeadBagged = exports['rcore_police']:IsPlayerHeadBagged()
if isHeadBagged then
print('Player is IsPlayerHeadBagged')
else
print('Player is not IsPlayerHeadBagged')
end
Check any player on client
Params:
NameTypeDescriptionplayerId
number
ID of player which you want to get state of IsPlayerHeadBagged
Returns:
boolean
:true
if player is IsPlayerHeadBagged, otherwisefalse
.
Example:
-- playerId: number
-- return: boolean
local isHeadBagged = exports['rcore_police']:IsPlayerHeadBagged(playerId)
if isHeadBagged then
print('Player is IsPlayerHeadBagged')
else
print('Player is not IsPlayerHeadBagged')
end
Last updated
Was this helpful?