playerAduty
exports["RiP-Admin"]:playerAduty(callback)
This function returns if player is in aduty mode
Arguments
Name | Type | Optional | Explenation |
---|---|---|---|
callback | Function | Yes | retuns aduty state |
Returned Table
Name | Type | Explenation |
---|---|---|
source | Integer | player source |
identifier | String | player identifier |
aduty | Boolean | is in aduty mode |
time | Integer | aduty mode stated timestamp |
Example
exports["RiP-Admin"]:playerAduty(function(callback)
if callback and callback.aduty then
print("Player is in aduty mode since "..callback.time)
else
print("Player is not in aduty mode")
end
end)
local isAduty = exports["RiP-Admin"]:playerAduty()
if isAduty then
print("Player is in aduty mode")
else
print("Player is not in aduty mode")
end