17.07.2011, 07:12
(
Last edited by Meta; 17/07/2011 at 09:45 AM.
)
Little Snippet:
pawn Code:
stock GetRadioStationName(stationid)
{
new station[20];
switch(stationid)
{
case 0: station = "Radio Off";
case 1: station = "Playback FM";
case 2: station = "K-Rose";
case 3: station = "K-DST";
case 4: station = "Bounce FM";
case 5: station = "SF-UR";
case 6: station = "Radio Los Santos";
case 7: station = "Radio X";
case 8: station = "CSR 103.9";
case 9: station = "K-Jah West";
case 10: station = "Master Sounds 98.3";
case 11: station = "WCTR";
case 12: station = "User Track Player";
default: station = "Unknown";
}
return station;
}
public Audio_OnRadioStationChange(playerid, station)
{
new string[60];
if(GetPVarType(playerid, "RadioStation") == 0) { SetPVarInt(playerid, "RadioStation", -1); }
format(string, sizeof(string), "Old: %s, New: %s", GetRadioStationName(GetPVarInt(playerid, "RadioStation")), GetRadioStationName(station));
SendClientMessage(playerid, 0xFFFFFFFF, string);
SetPVarInt(playerid, "RadioStation", station);
}