25.10.2010, 18:06
humm how can i make this when he changes the it sends a string to the player
who changed the fighting style, it may be easy but i cant figure it out how.
iv tryed but :/ no luck
who changed the fighting style, it may be easy but i cant figure it out how.
iv tryed but :/ no luck
Код:
dcmd_fightstyle(playerid,params[])
{
new string[100];
if(PInfo[playerid][Level] < 3) return SendClientMessage(playerid, red, "ERROR: You must be level 3");
if(strlen(params) == 0) return SendClientMessage(playerid, ORANGE, "USAGE: /fightstyle [normal/boxing/kungfu/kneehead/grabkick/elbow]");
if(!strcmp(params, "normal", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_NORMAL);
}
if(!strcmp(params, "boxing", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_BOXING);
}
if(!strcmp(params, "kungfu", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_KUNGFU);
}
if(!strcmp(params, "kneehead", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_KNEEHEAD);
}
if(!strcmp(params, "grabkick", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_GRABKICK);
}
if(!strcmp(params, "elbow", true))
{
SetPlayerFightingStyle(playerid, FIGHT_STYLE_ELBOW);
}
return 1;
}



