Phone
Common phone scripts are detected (list). Without one, only the framework’s
own number is shown and changed. src is nil while the player is offline.
| Entry | File | Receives | Returns |
|---|---|---|---|
phoneInfo | framework.lua | citizenId, src | Table below, or false, 'no_phone' |
phoneSetNumber | framework.lua | citizenId, src, number | true, or false, 'taken' / 'online' / text |
phoneAction | framework.lua | citizenId, src, action, args | true, false, 'reason', or nil to let the built-in handle it |
phoneReload | client.lua | system | true after your phone refreshed the number |
action is one of notify, message, mail, verify, block, setField, resetSecurity, factoryReset,
wipe. Only buttons turned on in features are shown.
EditableServer.phoneInfo = { custom = true, fn = function(citizenId, src) local number = exports['my_phone']:GetNumber(citizenId) if not number then return false, 'no_phone' end return { system = 'my_phone', online = src ~= nil, number = number, social = {}, features = { setNumber = true, notify = true }, fields = {}, } end,}