Mask is bugged O_O
#2

PHP код:
CMD:mask(playerid, params[])
{
    if(
pInfo[playerid][pLevel] == 0)  //If you don't want all player use it change this line 
    
if(isStranged[playerid] == 0) //If your maks is put on
    
{
        new 
randomID = random(200);
        new 
string[35];
        
isStranged[playerid] = true; 
        
GetPlayerName(playerid, string, sizeof(string));
        
strmid(OldUsername[playerid], string, 0, strlen(string), 64);
        
format(string,sizeof(string), "Stranger", randomID);
        
SetPlayerName(playerid, string);
        
SetPlayerAttachedObject(playerid, 1, 19037, 2, 10, 4.7, 0.0, 90, 90, 0);//You can change this however you want, use sa-mp wiki for more info, right now is HockeyMask2
        
SendClientMessage(playerid, COLOR_WHITE, "You have put on a mask! (/mask to romove it)");
        for(new 
i = 0; i < MAX_PLAYERS; i++)
        {
            
ShowPlayerNameTagForPlayer(i, playerid, 0); // ShowPlayerNameTagForPlayer(i, playerid, 0) hide name for all players
        
}
    }
    else
    {
        
SetPlayerName(playerid, OldUsername[playerid]);  // SetPlayerName back your Roleplay name
        
isStranged[playerid] = false; // When is isStranged = false you speake normaly
        
SendClientMessage(playerid, COLOR_WHITE, "You have removed your mask!"); // This is message what was send when you remove your mask
        
if(IsPlayerAttachedObjectSlotUsed(playerid, 1)) RemovePlayerAttachedObject(playerid, 1); // This line is for Object what we attached, when you write /mask this remove it.
        
for(new i = 0; i < MAX_PLAYERS; i++)
        {
            
ShowPlayerNameTagForPlayer(i, playerid, 1); // ShowPlayerNameTagForPlayer(i, playerid, 1) show name back.
        
}
    }
    return 
1;
} 
Reply


Messages In This Thread
Mask is bugged O_O - by D3vin - 05.05.2014, 18:56
Re: Mask is bugged O_O - by GeasyW - 05.05.2014, 18:59
Re: Mask is bugged O_O - by Konstantinos - 05.05.2014, 18:59
Re : Mask is bugged O_O - by D3vin - 05.05.2014, 19:02
Re : Mask is bugged O_O - by D3vin - 05.05.2014, 20:14

Forum Jump:


Users browsing this thread: 1 Guest(s)