Jail System

JailPlayer

Use following export to jail some player.

exports['p_policejob']:JailPlayer(officerId, data)
  • officerId: number

    • Existing officer id

  • data: table

    • player: number

    • jail: number

    • fine: number

    • reason: string

    • offenses?: { [string]: offenseData }

offenseData

  • fine: number

  • label: string

  • jail: number

  • count: number

Return:

  • state: boolean or nil


JailPlayers

Use following export to jail few players at the same time.

  • officerId: number

    • Existing officer id

  • data: table

    • players: { [index]: { identifier: string } }

    • jail: number

    • fine: number

    • reason: string

    • offenses?: { [string]: offenseData }

offenseData

  • fine: number

  • label: string

  • jail: number

  • count: number

Return:

  • state: boolean or nil


Jail Command

Use following command to jail player [required permissions in config]

  • targetId: number

    • Existing player server id

  • months: number

    • Amount of months in jail


Unjail Player

Use following export to unjail player.

  • playerId: number or nil

    • Existing player server id

  • targetId: number

    • Existing player server id in jail


Unjail Command

Use following command to unjail player [required permissions in config].

  • targetId: number

    • Existing player server id in jail


Shorten Jail

Use following export to shorten player jail.

  • playerId: number or nil

    • Existing player server id

  • targetId: number

    • Existing player server id in jail

  • months: number

    • Amount of months to shorten


Shorten Jail Command

Use following command to shorten jail player [required permissions in config].

  • targetId: number

    • Existing player server id in jail

  • months: number

    • Amount of months to shorten


inJail

Check if player is currently in jail.

  • playerId: number

    • Existing player server id

Return:

  • state: boolean

getPlayerJudgment

Check player remaining amount of months in jail.

  • playerId: number

    • Existing player server id

Return:

  • months: number or 0

Last updated