SendDeathMessage ? Fast please
#1

Hey guys im working on a DM gamemode
i would like when a player ram player show up the :
Driver Name: [RAM ICON] Ramed player
_____________________________________
NOTE: I searched around but cant find what i search
Reply
#2

Use the death reason parameter given by OnPlayerDeath(...), having a simple system that handles the death list, already comes with it. Have a look at the wiki, this is something super, super simple and there is no need for anyone to provide code when you can do this in a breeze.
Reply
#3

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{  
     if(GetPlayerWeapon(killerid) == WEAPON_VEHICLE) SendDeathMessage(killerid, playerid, WEAPON_VEHICLE); //vehicle Ram icon when rammed
     return 1;
}
it should work
Reply
#4

You could use OnPlayerGiveDamage or OnPlayerTakeDamage, but it can't be detected for your vehicle, only if it's done by vehicle to ped...
Reply
#5

https://sampforum.blast.hk/showthread.php?tid=490436
Using Emmet's include and the callback "OnPlayerRamPlayer

Код:
public OnPlayerRamPlayer(playerid, driverid, vehicleid, Float:damage)
{
	if(damage > 10) SendDeathMessage(driverid, playerid, 49); // damage can be adjusted
	return 1;
}
Reply
#6

Quote:
Originally Posted by JaydenJason
Посмотреть сообщение
https://sampforum.blast.hk/showthread.php?tid=490436
Using Emmet's include and the callback "OnPlayerRamPlayer

Код:
public OnPlayerRamPlayer(playerid, driverid, vehicleid, Float:damage)
{
	if(damage > 10) SendDeathMessage(driverid, playerid, 49); // damage can be adjusted
	return 1;
}
What is the originaly Car damage ?
i think each car got each damage
example: BMX or a Line runer who runs 100 mph :/
im confused with that codes
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)