Hallo,
Irgendwie ist die Makse immer weg wenn man in einem Interrior geht. weiß jemand warum
new Maske[MAX_PLAYERS];
Maske[playerid] = 0;
if(Maske[playerid] == 1)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
ShowPlayerNameTagForPlayer(i, playerid, 1);
}
}
if(strcmp(cmdtext, "/maske", true) == 0)
{
if(IsPlayerInFrac(playerid, 1) && PlayerInfo[playerid][pRank] >= 8)
{
if(Maske[playerid] == 1)
{
for(new i = 0; i < MAX_PLAYERS; i++) ShowPlayerNameTagForPlayer(i, playerid, 1);
Maske[playerid] = 0;
SendClientMessage(playerid, COLOR_LIGHTBLUE, "*Du hast deine Maske abgenommen.");
}
else if(Maske[playerid] == 0)
{
for(new i = 0; i < MAX_PLAYERS; i++) ShowPlayerNameTagForPlayer(i, playerid, 0);
Maske[playerid] = 1;
SendClientMessage(playerid, COLOR_LIGHTBLUE, "*Du hast deine Maske aufgesetzt.");
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du kannst keine Maske aufsetzen!");
}
return 1;
}