15.04.2012, 04:58
Entonces seria de la primera forma que puse por que la funciуn es individual para cada jugador.
pawn Код:
//Arriba de todo
new CancionActual[MAX_PLAYERS];
public PlayVehicleRadioForPlayer(playerid,online)
{
if(online == 0)
{
StopAudioStreamForPlayer(playerid);
WaitForBuf[playerid] = true;
SetTimerEx("NonChangeRadio",1000,false,"i",playerid);
RadioInfo[playerid] = 0;
return 1;
}
StopAudioStreamForPlayer(playerid);
PlayAudioStreamForPlayer(playerid,RadioParams[online - 1][URL]);
WaitForBuf[playerid] = true;
RadioInfo[playerid] = 1;
CancionActual[playerid] = online-1; //linea agregada
SetTimerEx("NonChangeRadio",1000,false,"i",playerid);
return 1;
}
//En el comando
if (strcmp("/info", cmdtext, true, 10) == 0)
{
if(!IsPlayerInAnyVehicle(playerid)) return 0;
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return 0;
new veh = GetPlayerVehicleID(playerid);
if(IsAVel(veh)) return 0;
new string[124];
format(string, sizeof(string), "Tнtulo %s", RadioParams[CancionActual[playerid]][Titulo]);
SendClientMessage(playerid, -1, string);
return 1;
}

