Create explotion OnPlayerDeath victim
#1

As you red the title create explotion onplayerdeath who got killed or let say victim.

Its just my idea maybe it might be usefull for some fun server.

Now my idea is:

If player1(killer) killed player2(victim) then create an explotion exactly on player2 body right before he fall on the floor/ground. Much better if the last bullet that will kill him will explode. So basically if player2(victim) died then make a explotion to him.

Also the explode should not damage any people around the victim.
Reply
#2

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
   
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z); //Gets players(victims in your case) position
   
    CreateExplosion(x, y, z, 1, 10.0);//Creates an explosion, at the victims position, with a radius of 10, it shouldn't damage other people, but the fire might.
    return 1;
}
Useful links:
https://sampwiki.blast.hk/wiki/Explosion_List
https://sampwiki.blast.hk/wiki/CreateExplosion
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)