http://sampforum.hu/index.php?topic=18349.msg200969#msg200969
rádiókat nemtok :D
Stop parancs:
COMMAND:player(playerid, params[])
{
StopAudioStreamForPlayer(playerid); // ha minden igaz:D
return true;
}
#include a_samp
#include zcmd
#define Radio_Dialog 678 //Dialog ID
#define Msg(%0) SendClientMessage(playerid, -1, %0)
CMD:radio(playerid) ShowPlayerDialog(playerid,Radio_Dialog,DIALOG_STYLE_LIST,\"Rádió\",\"Neo FM\\nClass FM\\nRádió 1\\nDream Rádió\",\"Hallgat\", \"Kikapcsol\");
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) {
if(dialogid == Radio_Dialog) {
if(!response) return StopAudioStreamForPlayer(playerid), Msg(\"{FFFF00}Sikeresen kikapcsoltad a {FFFFFF}rádiót{FFFF00}.\");
if(listitem == 0) PlayAudioStreamForPlayer(playerid, \"http://www.xhosting.hu/NeoFM/128_kbs_mp3.m3u\"), Msg(\"{FFFF00}Jelenleg a {FFFFFF}Neo FM{FFFF00}-et hallgatod.\");
if(listitem == 1) PlayAudioStreamForPlayer(playerid, \"http://www.sztarnet.hu/ClassFM/mp3_adas_1.m3u\"), Msg(\"{FFFF00}Jelenleg a {FFFFFF}Class FM{FFFF00}-et hallgatod.\");
if(listitem == 2) PlayAudioStreamForPlayer(playerid, \"http://195.70.35.172:8000/radio1.mp3\"), Msg(\"{FFFF00}Jelenleg a {FFFFFF}Rádió 1{FFFF00}-et hallgatod.\");
if(listitem == 3) PlayAudioStreamForPlayer(playerid, \"http://stream.dream-radio.eu:8100/listen.pls\"), Msg(\"{FFFF00}Jelenleg a {FFFFFF}Deram Rádiót{FFFF00}-t hallgatod.\");
}
return 1;
}
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
mivel:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { //ebben
[] ezt erre : [] átkell írni :D
E: és ha nem [pawn]pawn,/pawn[/pawn] ba teszitek hanem
code,/code
ba akkor jó lesz
City nincs benne...
#include <a_samp>
#include <zcmd>
#define CARRADIO 200
#define COLOR_BLUE 0x0000FFAA
CMD:radio(playerid, params[]) {
ShowPlayerDialog(playerid, 200, DIALOG_STYLE_LIST, \"{09ff00}Autó Rádiók\", \"{0019fc}NeoFM\\n{FF0000}MixRadio\\n{FF00FF}DiscoShit\\n{00FF00}ClassFM\\n{0019fc}DJ\\n{00FFFF}Rock\\n{1E90FF}Hardcore\\nRádió1 \\n{FFFF00}STOP\", \"Választ\", \"Mégse\");
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == 200)
{
if(response == 1)
{
switch(listitem)
{
case 0: PlayAudioStreamForPlayer(playerid,\"http://91.82.85.41:8080/;stream\");
case 1: PlayAudioStreamForPlayer(playerid,\"http://savetofile.net:8450/;stream\");
case 2: PlayAudioStreamForPlayer(playerid,\"http://212.108.220.144:1039/stream.mp3\");
case 3: PlayAudioStreamForPlayer(playerid,\"http://91.82.85.41:9216/;stream\");
case 4: PlayAudioStreamForPlayer(playerid,\"http://streaming.virtualpro.hu:9080/;stream\");
case 5: PlayAudioStreamForPlayer(playerid,\"http://94.199.181.124:8800/rockvilag2\");
case 6: PlayAudioStreamForPlayer(playerid,\"http://shoutcast.rotterdamterror.com:8390/\");
case 7: PlayAudioStreamForPlayer(playerid,\"http://195.70.35.172:8000/radio1.mp3.m3u\");
case 8: StopAudioStreamForPlayer(playerid);
}
}
else
{
SendClientMessage(playerid, 0xF97804FF, \"Kiléptél menüböl!\");
}
}
return 1;
}