[DUDA] Funcion - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Español/Spanish (
https://sampforum.blast.hk/forumdisplay.php?fid=29)
+---- Thread: [DUDA] Funcion (
/showthread.php?tid=635856)
[DUDA] Funcion -
Matyaas - 15.06.2017
Como puedo hacer que cada 30 minutos se realice una acciуn con 1 jugador al azar de todos los conectados en el servidor? alguna ayuda?
Respuesta: [DUDA] Funcion -
mcreed - 15.06.2017
No sй si te refieres a esto:
pawn Код:
new totJugadores = GetPlayerPoolSize(), RID;
RID = random(totJugadores);
if(IsPlayerConnected(RID))
{
// Acciуn a realizar
}
Respuesta: [DUDA] Funcion -
Matyaas - 16.06.2017
me toco hacerlo xd
Код:
stock RandomTank()
{
new count = 0;
new Random = Iter_Random(Player);
foreach(Player, i)
{
if(gTeam[i] == TEAM_HUMANOS) count++;
if(count == Iter_Count(Player))
{
ZombieSetting(Random);
}
}
return 1;
}