SA-MP Forums Archive
OnPlayerDeath - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: OnPlayerDeath (/showthread.php?tid=343364)



OnPlayerDeath - Kudoz - 17.05.2012

Hey all! I have this script:

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    SendDeathMessage(playerid,killerid,reason);
    SendClientMessage(killerid, COLOR_RED, ".:: NO Deathmatching is Tolerated! ::.");
    SetPlayerHealth(playerid, 100);
    SetPlayerArmour(playerid, 100);
    SetPlayerPos(playerid, 1182.2816,-1324.0585,13.5799);
    SetPlayerPos(killerid, 1760.0499,-1538.4115,9.3113);
    SendClientMessage(killerid, COLOR_RED, ".:: You have been teleported to Prison, but you're free to teleport! ::.");
    SendClientMessage(killerid, COLOR_RED, ".:: You lost $35'000,- for DM'ing ::.");
    GivePlayerMoney(killerid,-35000);
    return 1;
}
and instead of this as an example: " Cir.Cuz [AK47 SIGN] Random_Dude " " It says Random_Dude [AK47 SIGN] Cir.Cuz "

(thats when I kill randomdude...) Need help!


Re: OnPlayerDeath - Face9000 - 17.05.2012

Just a mistake at SendDeathMessage:

pawn Код:
SendDeathMessage(killerid, playerid, reason);
First killerid,after playerid.


Re: OnPlayerDeath - Kudoz - 17.05.2012

aah LOL! Didn't noticed that.. thanks alot mate!


Re: OnPlayerDeath - sniperwars - 17.05.2012

pawn Код:
SendDeathMessage(killerid, playerid, reason);
Not

pawn Код:
SendDeathMessage(playerid, killerid, reason);