Server Reach Player(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)
+--- Thread: Server Reach Player(FS) (
/showthread.php?tid=642507)
Server Reach Player(FS) -
Seyed - 01.10.2017
Hi
What Is This FS Name?
Re: Server Reach Player(FS) -
Seyed - 02.10.2017
UP
Re: Server Reach Player(FS) -
MasterCodez - 02.10.2017
Код:
new playersJoined;
forward CheckReachPlayers();
{
new string[128];
format(string, sizeof(string), "Now player reached at %d players", playersJoined);
SendClientMessage(playerid, -1, string);
//Your other code give player money and bla bla bla as you want.
return 1;
}
public OnGameModeInit() {
SetTimer("CheckReachPlayers", 5000, true); //Your time to check reach players
playersJoined = 0;
return true;
}
public OnPlayerConnect(playerid) {
playersJoined += 1;
return true;
}
public OnPlayerDisconnect(playerid, reason) {
playersJoined -= 1;
return true;
}
Re: Server Reach Player(FS) -
Dayrion - 02.10.2017
Код:
new playersJoined;
public OnPlayerConnect(playerid) {
if(++playersJoined >= 20)
{
new string[128];
format(string, sizeof(string), "Now player reached at %d players", playersJoined);
SendClientMessage(playerid, -1, string);
//Your other code give player money and bla bla bla as you want.
}
return true;
}
public OnPlayerDisconnect(playerid, reason) {
playersJoined --;
return true;
}