[Pedido] Anti Db drive
#6

Fiz esse bem rбpido aqui use como base acho que й oque procura:

Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
{


if(GetPlayerState(issuerid) == PLAYER_STATE_DRIVER){
	if(weaponid == WEAPON_VEHICLE)
	{
		
		static dbname[MAX_PLAYER_NAME], vname[MAX_PLAYER_NAME];
		static Float:X, Float:Y, Float:Z, Float:Health, Float:Armour;
		static str[128];
		GetPlayerName(issuerid, dbname, MAX_PLAYER_NAME);
		GetPlayerName(playerid, vname, MAX_PLAYER_NAME);
		GetPlayerPos(issuerid, X, Y, Z);
		GetPlayerPos(playerid, X, Y, Z);
		SetPlayerPos(playerid, X, Y, Z+4); //Tira o player debaixo do carro
		SetPlayerPos(issuerid, X, Y, Z+5); //Ejeta o motorista
		GetPlayerHealth(issuerid, Health);
		GetPlayerArmour(issuerid, Armour);
		SetPlayerHealth(issuerid, Health - 30); //Tira -30 de HP do motorista
		SetPlayerArmour(issuerid, Armour - 30); //Tira -30 de Colete do motorista
		format(str, sizeof(str), "INFO: %s fez DB em %s | Foi ejetado do seu veнculo e perdeu Vida e Colete |", dbname,vname);
		SendClientMessageToAll(0xFFFF00FF, str);
	}
}


	return 1;
}
Reply


Messages In This Thread
Anti Db drive - by galazoiadria - 02.10.2016, 18:24
Re: Anti Db drive - by GuilhermeW - 02.10.2016, 18:33
Re: Anti Db drive - by GuilhermeW - 02.10.2016, 19:09
Re: Anti Db drive - by galazoiadria - 02.10.2016, 19:12
Re: Anti Db drive - by GuilhermeW - 02.10.2016, 19:13
Re: Anti Db drive - by ViDaLoKa1 - 02.10.2016, 19:16
Re: Anti Db drive - by RedMF - 02.10.2016, 19:47
Re: Anti Db drive - by ViDaLoKa1 - 02.10.2016, 19:53
Re: Anti Db drive - by galazoiadria - 02.10.2016, 20:13
Re: Anti Db drive - by ViDaLoKa1 - 02.10.2016, 20:18

Forum Jump:


Users browsing this thread: 1 Guest(s)