cmd /kill with time
#2

Example

Код:
#include <a_samp>

#define COLOR_RED 0xFF0000FF

public OnPlayerCommandText(playerid, cmdtext[])
{
	if(strcmp("/kill", cmdtext, true, 5) == 0)
	{
		SendClientMessage(playerid, COLOR_RED, "You will be dead after 15 seconds");
		SetTimerEx("kill", 15000, false, "i", playerid);
		return 1;
	}
	return 0;
}

forward kill(id);
public kill(id)
{
    SetPlayerHealth(id, 0.0);
    SendClientMessage(id, COLOR_RED, "15 seconds passed, you are dead");
    return 1;
}
Reply


Messages In This Thread
cmd /kill with time - by BenStar - 10.03.2018, 12:24
Re: cmd /kill with time - by David (Sabljak) - 10.03.2018, 12:37
Re: cmd /kill with time - by RxErT - 10.03.2018, 12:40
Re: cmd /kill with time - by BenStar - 10.03.2018, 12:45
Re: cmd /kill with time - by RxErT - 10.03.2018, 12:52

Forum Jump:


Users browsing this thread: 1 Guest(s)