21.11.2013, 00:24
hello guys how can i check if player is muted or forzen or jailed etc!
if(GetPVarInt(playerid,"Jailed") == 1)
{
//Your Code Here
return 1;
}
if(PlayerInfo[playerid][muted] > 0)
{
// return what you want here....
return 1;
}
if(muted[playerid] > 0)
{
// return what you want here....
return 1;
}
if(GetPVarInt(playerid,"muted") == 1)
{
// return what you want here....
return 1;
}
if(PlayerInfo[playerid][muted] == 1) // This line checks if the player is muted if so it does something. { // this what it will return if the player is muted. return 1; } if(PlayerInfo[playerid][injail] == 1) // This line checks if the player is in jail if so it does something. { // this what it will return if the player is muted. return 1; } if(PlayerInfo[playerid][frozen] == 1) // This line checks if the player is frozen if so it does something. { // this what it will return if the player is muted. return 1; }
if(PlayerInfo[playerid][injail] == 1) // We have cheked that the player is in prison. { SendClientMessage(playerid, RED, "You can't use that command in jail"); // After we found out he is in prison we tell him that the command he is using is forrbiden in prison. return 1; }