Death Bug Problem SAMP
#1

Hello Guys ..

I have a prob, I'm still alive even if someone kill me !!

Here is a picture from my computer ..


How other players see me :
Reply
#2

give me the code of OnPlayerDeath and OnplayerSpawn
_______________

MY SERVER:

Server forum
-------
Be$t Host for your server : HostingTime Easy control panel with 1Euro for 20 slots.
Reply
#3

Yes, this is a known SA:MP bug. You have to rejoin to get rid of it.
Reply
#4

Try SetPlayerHealth(playerid,0) under OnPlayerDeath
Reply
#5

Quote:
Originally Posted by newbienoob
Посмотреть сообщение
Try SetPlayerHealth(playerid,0) under OnPlayerDeath
This would fuck it. The health is already 0. The player is bugged that's why OnPlayerDeath isn't being called for the player.
Reply
#6

Well from what i have experienced is if a player has this happen heal them, it makes the player respawn. (Thats what i do to fix it)
Reply
#7

to prevent this i have a method in OnPlayerDeath make an explosion then u will automatically fall in ground and respawn

or in OnPlayerDeath use if gTeam[playerid] = bla bla SpawnPlayer there is a code to spawn use that to prevent this
Reply
#8

It's kinda simple, all you have to do is jump from a place or let someone ram you, no need to rejoin as suggested above.
Reply
#9

Quote:

Try SetPlayerHealth(playerid,0) under OnPlayerDeath

That Wouldn't Do any thong because the player health is already 0,
Try This code:
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    new Float:X;
    new Float:Y;
    new Float:Z;
    GetPlayerPos(playerid, X, Y, Z);
    SetPlayerPos(playerid, X, Y, Z+50);
    return 1;
}
Reply
#10

Something like this (i'd add it onplayerupdate or onplayerdeath)

pawn Код:
new Float:hp;
GetPlayerHealth(playerid,hp);
if(hp <= 1.0) return SetPlayerHealth(playerid,-1.0);
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)