Somethings not working....
#1

Hello guys, I just came back to samp and started scripting again Although i was making a command but it didnt seem to work..


Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
	dcmd(msg, 3, cmdtext);
	return 0;
}

dcmd_msg(playerid, params[])
{
	new
		input[21],
		string[60];
	if (sscanf(params, "s", input)) SendClientMessage(playerid, 0xFF0000AA, "Usage: /msg [msg]");
	else
	{
		Msg[playerid] = input[0];
		Created[playerid] = 1;
	}
	return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
	new string[60];
	if(Created[playerid] == 1)
	{
		format(string,sizeof(string), "%s", Msg[playerid]);
		GameTextForPlayer(playerid, string, 5000, 6);
	}
	return 1;
}
mmhmm, anyone know whats wrong with the code? What im simply saying here is that when i set my msg and then kill my self (IG) it only shows the first letter of the msg when it should show the whole msg...
I knew how to do this before but now i forgot, hmm

-Lorenc
Reply


Messages In This Thread
Somethings not working.... - by Lorenc_ - 25.10.2010, 19:59
Re: Somethings not working.... - by randomkid88 - 25.10.2010, 20:32
Re: Somethings not working.... - by Fj0rtizFredde - 25.10.2010, 20:32
Re: Somethings not working.... - by Lorenc_ - 26.10.2010, 05:52
Re: Somethings not working.... - by Calgon - 26.10.2010, 06:04
Re: Somethings not working.... - by Lorenc_ - 26.10.2010, 06:24
Re: Somethings not working.... - by Calgon - 26.10.2010, 06:26

Forum Jump:


Users browsing this thread: 1 Guest(s)