SA-MP Forums Archive
[FilterScript] Music Instrumental [0.3D ONLY] - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+--- Thread: [FilterScript] Music Instrumental [0.3D ONLY] (/showthread.php?tid=282890)



Music Instrumental [0.3D ONLY] - Kitten - 12.09.2011

Music Instrumental Only for 0.3D
Description: this is a test script i made with new sa-mp natives in 0.3d i used my own host and uploaded some mp3 files with instrumentals and created dialogs and streaming the mp3 files from my FTP i hope this helps you out with the new native in samp 0.3d it includes 10 songs.

Song lists:

Aggro Santos - Candy
Linking Park - Breaking the habit
Cassie - Lets get crazy
Unknown - Drop it low
E-40 - On Oil
Eminem - Beautiful
Audio Push - Teach me how to jerk
Jamie Foxx - Digital Girl
Pitbull - Blanco
Various Artist - Tokyo drift

Features:

- my own host for the mp3 files : www.pamp3.site40.net
- dialog
- 10 songs
- custom textdraw saying what song you listening to
- using 0.3d PlayAudioStreamForPlayer native.
- etc.

Pictures:




Download:

http://pastebin.com/zUyVpBg3

or:

pawn Код:
#include <a_samp>

//---Variables---//
new Text:Box;
new Text:ListeningTo[MAX_PLAYERS];

//---Defines---//
#define PADIALOG 2050

public OnFilterScriptInit() {
    Box = TextDrawCreate(0.000000, 430.000000, "~n~");
    TextDrawBackgroundColor(Box, 255);
    TextDrawFont(Box, 1);
    TextDrawLetterSize(Box, 0.500000, 1.700000);
    TextDrawColor(Box, -1);
    TextDrawSetOutline(Box, 0);
    TextDrawSetProportional(Box, 1);
    TextDrawSetShadow(Box, 1);
    TextDrawUseBox(Box, 1);
    TextDrawBoxColor(Box, 838881380);
    TextDrawTextSize(Box, 640.000000, 50.000000);

    for(new i; i < MAX_PLAYERS; i ++) {
        ListeningTo[i] = TextDrawCreate(1.000000, 430.000000, "~b~Current Music: ~w~None ");
        TextDrawBackgroundColor(ListeningTo[i], 255);
        TextDrawFont(ListeningTo[i], 1);
        TextDrawLetterSize(ListeningTo[i], 0.500000, 1.599999);
        TextDrawColor(ListeningTo[i], -1);
        TextDrawSetOutline(ListeningTo[i], 0);
        TextDrawSetProportional(ListeningTo[i], 1);
        TextDrawSetShadow(ListeningTo[i], 1);
    }
   
    return 1;
}

public OnPlayerCommandText(playerid, cmdtext[]) {
    if (strcmp("/musicins", cmdtext, true, 10) == 0) {
        ShowPlayerDialog(playerid, PADIALOG , DIALOG_STYLE_LIST, "Pick a music", "Aggro Santos - Candy\nLinkin Park - Breaking the habit\nCassie - Lets get crazy\nUnknown - Drop it low\nE-40 - On Oil\nEminem - Beautiful\nAudio Push - Teach me how to jerk\nJamie Foxx - Digital Girl\nPitbull - Blanco\nVarious Artist - Tokyo Drift", "Play", "Cancel");
        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
        TextDrawShowForPlayer(playerid,Box);
        return 1;
    }
    return 0;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) {
    if(response) {
        switch(dialogid == PADIALOG)
        {
            case 1: {
                switch(listitem)
                {
                    case 0: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/aggrosantoscandy.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Aggro Santos - Candy");
                    }
                    case 1: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/breakinghabit.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Linkin Park - Breaking the habit");
                    }
                    case 2: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/cassieletsgetcrazy.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Cassie - Lets get crazy");
                    }
                    case 3: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/dropitlow.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Unknown - Drop it low");
                    }
                    case 4: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/e40onoil.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ E-40 - On oil");
                    }
                    case 5: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/eminembeautiful.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Eminem - Beautiful");
                    }
                    case 6: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/howtojerk.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Audio Push - Teach me how to jerk");
                    }
                    case 7: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/jamiefoxxdigitalgirl.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Jameie Fox - Digital Girl");
                    }
                    case 8: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/pitbullblanco.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Pitbull - Blanco");
                    }
                    case 9: {
                        StopAudioStreamForPlayer(playerid);
                        PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/tokyodrift.mp3");
                        TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                        TextDrawSetString(ListeningTo[playerid],"~n~");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Various Artist - Tokyo Drift");
                    }
                }
            }
        }
    }
    return 0;
}

Reminder:

You can always request for songs



Upcoming Versions:

Dubstep Dialog
Techno
Hip Hop
Pop



Re: Music Instrumental [0.3D ONLY] - COD - 12.09.2011

omg this is awesome thanks kitten you mind if i can edit this script?


Respuesta: Music Instrumental [0.3D ONLY] - Manuel7284 - 12.09.2011

Nice FS!!!!


Re : Music Instrumental [0.3D ONLY] - Naruto_Emilio - 12.09.2011

Good job............:P


Re: Music Instrumental [0.3D ONLY] - Kitten - 12.09.2011

Quote:
Originally Posted by COD
Посмотреть сообщение
omg this is awesome thanks kitten you mind if i can edit this script?
yeah sure , but do not re-release it without permission.


Re: Music Instrumental [0.3D ONLY] - =WoR=G4M3Ov3r - 12.09.2011

Awesome


Re: Music Instrumental [0.3D ONLY] - The_$ - 13.09.2011

This is AWESOME. i luv 0.3d .

Offtopic: http://www.pamp3.site40.net/samp/intro.mp3
Whats the name of this song?

// Edit i have the song: Dj Fresh - Dust


Re: Music Instrumental [0.3D ONLY] - Michalec - 13.09.2011

http://pastebin.com/DWU7Uvje

My own better editing

Enjoy !


Re: Music Instrumental [0.3D ONLY] - laag - 13.09.2011

Why do you add this in every case?
Код:
         StopAudioStreamForPlayer(playerid);
         PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
         TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
         TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
         TextDrawSetString(ListeningTo[playerid],"~n~");
I'd rather do it in such way:
Код:
            case 1: {
                switch(listitem)
                {
                    StopAudioStreamForPlayer(playerid);
                    PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
                    TextDrawHideForPlayer(playerid,ListeningTo[playerid]);
                    TextDrawShowForPlayer(playerid,ListeningTo[playerid]);
                    TextDrawSetString(ListeningTo[playerid],"~n~");
                    case 0: {
                        PlayAudioStreamForPlayer(playerid, "http://pamp3.site40.net/sampfs/aggrosantoscandy.mp3");
                        TextDrawSetString(ListeningTo[playerid],"~b~Current Music: ~w~ Aggro Santos - Candy");
                    }
                    case n: {
                    }
....



Re: Music Instrumental [0.3D ONLY] - Michalec - 13.09.2011

@UP See my script. You can use it


Re: Music Instrumental [0.3D ONLY] - Joe Staff - 13.09.2011

Quote:
Originally Posted by The_$
Посмотреть сообщение
This is AWESOME. i luv 0.3d .

Offtopic: http://www.pamp3.site40.net/samp/intro.mp3
Whats the name of this song?

// Edit i have the song: Dj Fresh - Dust
Gold Dust remix by Flux Pavilion

Atleast it sounds like it