• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Pawn] Death spam bug
#5
(2019-05-28, 10:26 AM)mouiz Wrote: A temporary fix:









Code:
new player_spawned [MAX_PLAYERS];



public OnPlayerSpawn (playerid)

{

? ? if (player_spawned [playerid] == 1) return 0;

? ? player_spawned = 1;

? ? SetTimerEx ("ResetSpawnVar", 1000, false, "i", playerid);

? ??return 1;

}



forward ResetSpawnVar (playerid);

public ResetSpawnVar (playerid)

{

? ? player_spawned [playerid] = 0;

? ? return 1;

}



Thanks, I'll try this temp fix.





(2019-05-28, 05:53 PM)Markski Wrote: Uberanwar, long time no see.



The code inside of "OnPlayerDeath" is only called upon, as the name implies, a player death. None of the code you have inside that callback should be causing a loop. My suggestion to you is to assert no parts of your code are purposefully killing the player or calling the OnPlayerDeath callback.



Likewise, you should also be sure these players aren't trolls using illegitimate clients to fake deaths in order to mess with you, as this is a rather common thing for some to do.



Hi! I am sure that I don't have anything inside the callback that causes loop. Regarding the fake deaths, yes I have a detection for that but in this case, it is not a fake death. OT: What's was your name on SA-MP forum?



(2019-05-30, 08:34 PM)Expert* Wrote: Or health anti cheat sets health to 0.

That would make sense when we talk about lagging?players.



Yes, I use weapon-config include and it has an health anti-cheat mechanism. Could be it!
  Reply


Messages In This Thread
Death spam bug - by Uberanwar - 2019-05-28, 03:39 AM
RE: Death spam bug - by mouiz - 2019-05-28, 10:26 AM
RE: Death spam bug - by Markski - 2019-05-28, 05:53 PM
RE: Death spam bug - by Expert* - 2019-05-30, 08:34 PM
RE: Death spam bug - by Uberanwar - 2019-05-30, 10:21 PM

Forum Jump: