Whisper script
#3

After adding Cjgogo's code my other commands are not working.These are my commands.When I type /mycommand it shows SERVER:Unknown command.I removed Cjgogo's code from my script but it still don't works please help
Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/kill", cmdtext, true, 10) == 0)
	{
	    ClearAnimations(playerid,5);
		SetPlayerHealth(playerid,0);
		SendClientMessage(playerid,COLOR_YELLOW,"You have commited a sucide");
		SetPlayerScore(playerid, GetPlayerScore(playerid) - 2);
		new msg[128],
		suicider[MAX_PLAYER_NAME];
		GetPlayerName(playerid, suicider, sizeof suicider);
		format(msg, sizeof(msg), "%s has commited suicide!", suicider);
		SendClientMessageToAll(COLOR_RED, msg);
		return 1;
	}
	if (strcmp("/sync", cmdtext, true, 10) == 0)
	{
		ClearAnimations(playerid,5);
		SendClientMessage(playerid,COLOR_YELLOW,"If you are still bugged then ask adminis to help you.If there is not admins then please relog and report about the bug in forums.");
	}
	if (strcmp("/bodyguard", cmdtext, true, 10) == 0)
    {
       ShowPlayerDialog(playerid, 1, DIALOG_STYLE_MSGBOX, "Bodyguard", "Bodyguard's job is to protect a player who called for a bodyguard.You will get money for this from the player who called you", "Ok", "Cancle");
    }
	//Animations
    if (strcmp("/handsup", cmdtext, true, 10) == 0)
    {
    	SetPlayerSpecialAction(playerid,SPECIAL_ACTION_HANDSUP);
    }
    if (strcmp("/sit", cmdtext, true, 10) == 0)
    {
        SetPlayerSpecialAction(playerid,SPECIAL_ACTION_SITTING);
    }
    if (strcmp("/smoke", cmdtext, true, 10) == 0)
    {
        SetPlayerSpecialAction(playerid,SPECIAL_ACTION_SMOKE_CIGGY);
    }
    if (strcmp("/anims", cmdtext, true, 10) == 0)
    {
        SendClientMessage(playerid,COLOR_YELLOW,"/handsup /sit /call /smoke");
    }
	return 0;
}
Reply


Messages In This Thread
Whisper script - by MichaelProPlayer - 07.04.2012, 12:50
Re: Whisper script - by Cjgogo - 07.04.2012, 12:55
Re: Whisper script - by MichaelProPlayer - 08.04.2012, 05:25
Re: Whisper script - by Reklez - 08.04.2012, 05:28
Re: Whisper script - by MichaelProPlayer - 08.04.2012, 05:31
Re: Whisper script - by Reklez - 08.04.2012, 05:44

Forum Jump:


Users browsing this thread: 1 Guest(s)