SetPlayerDrunkLevel
From SA-MP Wiki
(Difference between revisions)
Revision as of 00:47, 30 January 2014 Smithy (Talk | contribs) ← Previous diff |
Revision as of 17:54, 4 February 2014 Connor Mead (Talk | contribs) Next diff → |
||
Line 32: | Line 32: | ||
[[Category:Scripting Functions]] | [[Category:Scripting Functions]] | ||
+ | |||
+ | [[fr:SetPlayerDrunkLevel]] |
Revision as of 17:54, 4 February 2014
Description:
Sets the drunk level of a player which makes the player's camera sway and vehicles hard to control.
(playerid, level)
playerid | The ID of the player to set the drunkenness of. |
level | The level of drunkenness to set. |
Return Values:
This function does not return any specific values.
if (strcmp(cmdtext, "/drunk", true) == 0) { SetPlayerDrunkLevel (playerid, 4000); SendClientMessage(playerid, 0xFFFFFFAA, "You are now drunk; don't drink and drive!"); return 1; }
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- GetPlayerDrunkLevel: Returns the current drunk level of a player.