Skip to main content

PlayerHasClockEnabled

Description

Checks whether the player has their in-game clock enabled. (TogglePlayerClock)

NameDescription
playeridThe player whose clock you want to check.

Returns

true - The clock is enabled.

false - The clock isn't enabled, or the specified player does not exist.

Examples

public OnPlayerConnect(playerid)
{
TogglePlayerClock(playerid, true); // Show the clock

if (PlayerHasClockEnabled(playerid))
{
SendClientMessage(playerid, COLOR_WHITE, "The clock is enabled.");
}
return 1;
}

Notes

tip

Time is not synced with other players! Time can be synced using SetPlayerTime.