20.05.2014, 16:25
A Scarf object
Код:
if (strcmp("/scarf", cmdtext, true, 10) == 0)
{
if(maramawearg[playerid] == 0)
{
SetPlayerAttachedObject(playerid, 3, 18912, 2, -0.08, 0.03, 0.0, 90, -180, -90); //marama
maramawearg[playerid] = 1;
SendClientMessage(playerid, WHITE, "{37F906}INFO:{FFFFFF}You have put the scarf on your face.");
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* %s takes the scarf and puts it on his face", sendername);
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
}
else
{
SendClientMessage(playerid, WHITE, "{FF0000}GRESKA:{FFFFFF}Ne ste clen na banda/mafija!");
}
return 1;
}
if (strcmp("/takescarf", cmdtext, true, 10) == 0)
{
if(maramawearg[playerid] == 1)
{
RemovePlayerAttachedObject(playerid,3);
maramawearg[playerid] = 0;
SendClientMessage(playerid, WHITE, "{37F906}INFO:{FFFFFF}You have take out the scarf from your face.");
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* %s puts out the scarf from his face.", sendername);
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
}
return 1;
}


