Speletaju Tagu komanda

Ja kas neizprotams.

Moderator: Moderatori

Post Reply
User avatar
Ingusss20
Jauniņais
Jauniņais
Posts: 31
Joined: 02 Oct 2010, 22:19

Speletaju Tagu komanda

Post by Ingusss20 »

Code: Select all

if(strcmp(cmd, "/playertagsoff", true) == 0)
{
 if(IsPlayerConnected(playerid))
{
if (PlayerInfo[playerid][pAdmin] >= 6 || IsPlayerAdmin(playerid))
			{
SendClientMessage(playerid, COLOR_RED, "Speletaja vardi izslegti!");
ShowNameTags(0);
}
}
eturn 1;
}
if(strcmp(cmd, "/playertagson", true) == 0) 
{
if(IsPlayerConnected(playerid))
{
if (PlayerInfo[playerid][pAdmin] >= 6 || IsPlayerAdmin(playerid))
{
SendClientMessage(playerid, COLOR_RED, "Speletaja vardi ieslegti!");
ShowNameTags(1);

}
}
return 1;
}
kapec man neiet si komanda errorus nemet tad kad ieiet spele neiet
User avatar
Macluawn
Jauniņais
Jauniņais
Posts: 124
Joined: 07 Feb 2009, 23:16

Re: Speletaju Tagu komanda

Post by Macluawn »

ShowNameTags funkciju var izmantot tikai OnGameModeInit callbackā. Aizvieto to rindiņu ar šo kodu. Tas izskries cauri visiem spēlētāju slotiem un uzstādīs, ka nametags nerādīsies.

Code: Select all

for (new slots = GetMaxPlayers(), i; i < Slots; i++)
{
    ShowPlayerNameTagForPlayer(playerid, i, false / true);
}
Post Reply