From 5a076887fc2ec19f017d7198a376b395d5d99244 Mon Sep 17 00:00:00 2001 From: Linden <65407488+thelindat@users.noreply.github.com> Date: Tue, 29 Nov 2022 17:09:50 +1100 Subject: [PATCH] Update methods.md --- docs/ox_core/Player/Server/methods.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/docs/ox_core/Player/Server/methods.md b/docs/ox_core/Player/Server/methods.md index 9eeb40d3..5726f204 100644 --- a/docs/ox_core/Player/Server/methods.md +++ b/docs/ox_core/Player/Server/methods.md @@ -96,6 +96,30 @@ The filter can be a string, array, or object where key is the group, and value i player.hasGroup(filter) ``` +## player.setStatus + +Set the current value for a status (i.e. hunger, thirst). + +```lua +player.setStatus(name, value) +``` + +## player.addStatus + +Add the given amount to the total value for a status (i.e. hunger, thirst). + +```lua +player.addStatus(name, value) +``` + +## player.removeStatus + +Remove the given amount from the total value for a status (i.e. hunger, thirst). + +```lua +player.removeStatus(name, value) +``` + - filter: `string | string[] | { [string]: number }` ## player.getPlayersInScope