Callback don't works - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Callback don't works (
/showthread.php?tid=73411)
Callback don't works -
Danut - 14.04.2009
Hey guys. I've got a problem , dunno why ^^. My callback , OnPlayerDeath , don't works anymore ... Does somebady knows why?
Here's the begin of callback
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
new name[MAX_PLAYER_NAME];
new string[256];
new playercash;
new victimteam;
new Float:px,Float:py,Float:pz;
new killerteam;
new killer[MAX_PLAYER_NAME];
IsInShamal[playerid] = 0;
victimteam = gTeam[playerid];
killerteam = gTeam[killerid];
gPlayerSpawned[playerid] = 0;
GetPlayerName(playerid, name, sizeof(name));
PlayerInfo[playerid][pLocal] = 255;
GetPlayerPos(playerid, px, py, pz);
PlayerInfo[playerid][pTrain] = 0;
SendDeathMessage(killerid, playerid, reason);
FadePlayerScreen(playerid, 0xE60000FF, 6, 192);
GameTextForPlayer(playerid, "~n~~n~~n~~n~~r~Wasted", 2000, 2);
When i die , he don't show me the Death Message , the FadePlayerScreen , the GameTextForPlayer ...
Why?
*
Maybe because i use PLAYER_STATE_WASTED under OnPlayerStateChange ?
Re: Callback don't works -
Rks25 - 14.04.2009
for what u use that state on the change()?
Re: Callback don't works -
Danut - 14.04.2009
when a Cop kills a civil / a faction member , to jail it
Re: Callback don't works -
gtachile - 14.04.2009
Maybe because you're not fucking returning any value, or even closing it?
That's what your code is missing, at least for what I see from here.
Re: Callback don't works -
ICECOLDKILLAK8 - 14.04.2009
Quote:
|
Originally Posted by GtaChile!
Maybe because you're not fucking returning any value, or even closing it?
That's what your code is missing, at least for what I see from here.
|
Obviously he has done that already, Otherwise it wouldnt compile and he wouldnt have been able to test it to know that it didnt work