MP3 Player
#1

FIXED!
Reply
#2

Uh, show about 10 lines above the one you've posted please; there's no error on that line according to my eyes...
Reply
#3

Код:
CMD:radio(playerid, params[])
{
    if(!IsPlayerInAnyVehicle) return SendClientMessage(playerid, -1, "You need to be in a vehicle to use this command!");
    ShowPlayerDialog(playerid, DIALOG_MUSICPLAYER, DIALOG_STYLE_LIST, "Radio Vinewood", "Chicosci - Raspberry Girl\nI Like That - Richard Vission & Static\nAsking Alexandria- Not The American Average\nChamillionaire - Ridin' ft. Krayzie Bone\nKid Frost ft Big Tank - I'm a Bad Ass\nChris Brown - Should've Kissed You", "Play", "Close");
    return 1;
}
If i remove no error if i have this command above i get 1 error
Reply
#4

I have also added
Код:
#define DIALOG_MUSICPLAYER  1
and
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == DIALOG_MUSICPLAYER) // This checks to see if the dialog the players viewing is the music player one
    {
          if(response) // If the player clicked a song
          {
               if(listitem == 0) // Since this is a list, we check if they clicked the first song on the list.
               {
                       PlayAudioStreamForPlayer(playerid, "URL"); // Play the song 
               }
               if(listitem == 1) // We now check if the player clicked the second song
               {
                       PlayAudioStreamForPlayer(playerid, "URL"); // Play the song
               }
               if(listitem == 2) // or the third song.
               {
                       PlayAudioStreamForPlayer(playerid, "URL"); // Play the song
               }
           }
      }
    return 1;
}
Reply
#5

it should be
pawn Код:
...
if(!IsPlayerInAnyVehicle(playerid)) // and the rest of the code
...
PS sorry, i'm from my phone
Reply
#6

Quote:
Originally Posted by MarTaTa
Посмотреть сообщение
it should be
pawn Код:
...
if(!IsPlayerInAnyVehicle(playerid)) // and the rest of the code
...
PS sorry, i'm from my phone
Thank you very much
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)