Код:
dcmd_shake(playerid, params[])
{
if(!strlen(params))
{
SendClientMessage(playerid, COLOR_ERROR, "Использование: /shake [ID]");
}
else
{
ID = strval(params);
if(robtime[playerid] == 0)
{
if(ID != playerid)
{
if(IsPlayerConnected(ID))
{
new oname[MAX_PLAYER_NAME];
GetPlayerName(ID, oname, sizeof(oname));
if(GetDistanceBetweenPlayers(playerid, ID) <= DISTANCE_BETWEEN_PLAYERS)
{
ApplyAnimation(playerid,"GANGS","hndshkfa_swt",4.0,0,0,0,0,0);
ApplyAnimation(ID,"GANGS","hndshkfa_swt",4.0,0,0,0,0,0);
}
}
}
}
}
return 1;
}