-
Notifications
You must be signed in to change notification settings - Fork 32
IsPlayerPaused
iFarbod edited this page Jun 28, 2014
·
4 revisions
Detects Player paused or not.
This function is available since R8. Not works in earlier versions.
Parameters:
- playerid : Player ID To check pause status.
Return Values:
- Returns 0 if server version unknown.
- Returns 1 if player paused (accuracy : 100%).
- Returns 0 also else if player NOT paused (accuracy : 100%).
Example Usage :
CMD:ispaused(playerid, params[])
{
new
targetid;
if(!IsPlayerAdmin(playerid)) return 0; // Change this to whatever.
if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, -1, "Syntax: /ispaused [Player ID/Player Name/Part of Player Name]");
if(!IsPlayerConnected(targetid) && targetid == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "That player isn't connected!");
switch(IsPlayerPaused(targetid))
{
case 0: SendClientMessage(playerid, -1, "Not-PAUSED!");
case 1: SendClientMessage(playerid, -1, "PAUSED!");
}
return 1;
}
- Home
-
Natives
- Execute
- File functions
- Directory functions
- Max player/npc change at runtime
- Filterscript functions
- Server rule modifications
- Server settings
- Player position sync bounds
- Modifying RCON commands
- Per AMX function calling
- Broadcasting console messages
- YSF Settings
- Nickname
- Classes
- Timers
- Per player functions
- Actors
- Scoreboard manipulation
- Pause functions
- Objects get - global
- Objects get - player
- Special for attached objects
- RakNet ban functions
- RakNet
- Exclusive RPC broadcast
- Vehicle functions
- Gangzones - Global
- Gangzones - Player
- Textdraws - Global
- Textdraws - Player
- 3DTexts - Global
- 3DTexts - Player
- Menu
- Pickups - Global
- Y_Less's model sizes inc
- Developer functions
- Formatting
- Callbacks
- Definitions
- Enumerators
- YSF.cfg