SA-MP Forums Archive
Problem with FS - 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: Problem with FS (/showthread.php?tid=135614)



Problem with FS - [EnergY] - 21.03.2010

Hi. Today I run my server on Linux. And found one problem. One of Fs is not work correctly. It's a duel system. It works like this: I write command /duel id weapon id ammo and another player writes command /yes id. After that duel started. Then one of players wins the duel FS Must Send Messsage " You won the duel with player (NickName)" and they returned to spawn. But when FS runs on Linux, duel never ends. FS runs incorrectly. Help me plz. Sorry of my bad English (I am Russian).


Re: Problem with FS - jameskmonger - 21.03.2010

It's nothing to do with it being run on Linux.

(Hint: It's to do with OnPlayerDeath)


Re: Problem with FS - [EnergY] - 21.03.2010

Quote:
Originally Posted by jameskmonger
It's nothing to do with it being run on Linux.

(Hint: It's to do with OnPlayerDeath)
Код:
public OnPlayerDeath(playerid, killerid, reason)
{
new killername[MAX_PLAYER_NAME];
new playername[MAX_PLAYER_NAME];
new string[256];
GetPlayerName(killerid, killername, sizeof(killername));
GetPlayerName(playerid, playername, sizeof(playername));
if(BbI3oB[playerid] == 1 && BbI3oB[killerid] == 1 && duelstart == 1)
{
SpawnPlayer(killerid);
BbI3oB[playerid] = 0;
BbI3oB[killerid] = 0;
duelstart = 0;
format(string, sizeof(string), "*You won duel with %s",playername);
SendClientMessage(killerid,COLOR_YELLOW, string);
format(string, sizeof(string), " *You loose duel with %s",killername);
SendClientMessage(playerid,COLOR_YELLOW, string);
format(string, sizeof(string), " %s won duel with %s",killername,playername);
SendClientMessageToAll(COLOR_YELLOW, string);
}
return 0;
}
this is my OnPlayerDeath. But I can't find the error



Re: Problem with FS - jameskmonger - 21.03.2010

I'm not on about that. The duel system is not checking if the player died.


Re: Problem with FS - [EnergY] - 21.03.2010

Quote:
Originally Posted by jameskmonger
I'm not on about that. The duel system is not checking if the player died.
Can you write/say how does the check should look?

And on Windows this FS Works correctly.