Jump to content
Sign in to follow this  
TheGuardianAngel

[REL] Audio Plugin by Incognito

Recommended Posts

Ce este?

Acest plugin te lasa sa asculti melodii pe un server de SA-MP.
Vor auzi melodia care va fi pornita de unul dintre administratorii/useri serverului (in functie de scripting), doar cei ce au instalat si clientul audio in San Andreas-ul lor.

*Server de test: samp.src-clan.net:7777  (instalati audio client mai intai , apoi in joc va dati /play garcea 0  sau /radio (/radio 0  /radio1 )

Ce Contine?/Download

Client Plugin (Windows) (Mirror)
Server Plugin (Windows and Linux) (Mirror)
Client Plugin Source Code (Windows) (Mirror)
Server Plugin Source Code (Cross-Compatible) (Mirror)

Daca serverul tau este pe windows atunci ai nevoie de Microsoft .NET Framework 3.5 SP1 minim sau mai mare, altfel pluginul nu va functiona!


Tutorial De Instalare!

http://forum.sa-mp.ro/index.php?topic=4623.0



Date Importante:

Natives


Audio_CreateTCPServer(port);
Creates the TCP server (done automatically—no need to use unless restarting); note that this must be on the same port that the SA-MP server is using


Audio_DestroyTCPServer();
Destroys the TCP server (no need to use unless restarting)


Audio_SetPack(const audiopack[], bool:transferable = true);
Maps audio files specified under the pack name in audio.ini, and sets whether the pack should be transferable (if it is not, then only CRC checks—or, if the files are remote, file size checks, and if it is an archive, file count checks—will take place)


Audio_CreateSequence();
Creates a sequence (returns the sequenceid)


Audio_DestroySequence(sequenceid);
Destroys a sequence


Audio_AddToSequence(sequenceid, audioid);
Adds a mapped audio file to a sequence


Audio_RemoveFromSequence(sequenceid, audioid);
Removes all instances of a mapped audio file from a sequence


Audio_Play(playerid, audioid, bool:pause = false, bool:loop = false, bool:downmix = false);
Plays a mapped audio file for a client and specifies whether it should start paused, whether it should be looped, and whether the audio stream should be downmixed to mono (returns the handleid)


Audio_PlaySequence(playerid, sequenceid, bool:pause = false, bool:loop = false, bool:downmix = false);
Plays a sequence for a client and specifies whether it should start paused, whether it should be looped, and whether the audio stream should be downmixed to mono (returns the handleid)


Audio_PlayStreamed(playerid, const url[], bool:pause = false, bool:loop = false, bool:downmix = false);
Streams a URL for a client and specifies whether it should start paused, whether it should be looped, and whether the audio stream should be downmixed to mono (returns the handleid)


Audio_Pause(playerid, handleid);
Pauses playback for an audio stream assigned to a player's handleid


Audio_Resume(playerid, handleid);
Resumes playback for an audio stream assigned to a player's handleid


Audio_Stop(playerid, handleid);
Stops playback for an audio stream assigned to a player's handleid


Audio_Restart(playerid, handleid);
Restarts playback for an audio stream assigned to a player's handleid


Audio_Seek(playerid, handleid, seconds);
Seeks playback in seconds for an audio stream assigned to a player's handleid


Audio_SetVolume(playerid, handleid, volume);
Adjusts volume (0-100) for an audio stream assigned to a player's handleid


Audio_Set3DPosition(playerid, handleid, Float:x, Float:y, Float:z, Float:distance);
Sets the 3D position (game world coordinates) of an audio stream assigned to a player's handleid


Audio_Set3DOffsets(playerid, handleid, Float:x, Float:y, Float:z);
Sets the 3D offsets of an audio stream assigned to a player's handleid (audio stream must be downmixed or encoded in mono)


Audio_SetFX(playerid, handleid, type);
Applies a sound effect an audio stream assigned to a player's handleid (audio stream must be downmixed or encoded in mono); valid values are as follows:
0: Chorus
1: Compression
2: Distortion
3: Echo
4: Flanger
5: Gargle
6: I3DL2 Reverb
7: Parametric Equalizer
8: Reverb


Audio_RemoveFX(playerid, handleid, type);
Removes a sound effect from an audio stream assigned to a player's handleid (audio stream must be downmixed or encoded in mono); valid values are listed above


Audio_SetEAX(playerid, environment);
Sets the client's EAX environment for both all active audio streams (must be downmixed or encoded in mono) and the game itself; valid values are as follows (note: this setting will not work in Windows Vista or higher as Microsoft dropped support for DirectSound and DirectSound3D hardware acceleration):
0: Generic
1: Padded Cell
2: Room
3: Bathroom
4: Living Room
5: Stone Room
6: Auditorium
7: Concert Hall
8: Cave
9: Arena
10: Hangar
11: Carpeted Hallway
12: Hallway
13: Stone Corridor
14: Alley
15: Forest
16: City
17: Mountains
18: Quarry
19: Plain
20: Parking Lot
21: Sewer Pipe
22: Underwater
23: Drugged
24: Dizzy
25: Psychotic


Audio_RemoveEAX(playerid);
Removes the EAX environment for the player


Audio_IsClientConnected(playerid);
Returns the player's TCP server connection status


Audio_TransferPack(playerid);
Transfers the currently set audio pack to a player


Callbacks


Audio_OnClientConnect(playerid);
Called when a player connects to the TCP server


Audio_OnClientDisconnect(playerid);
Called when a player disconnects from the TCP server


Audio_OnSetPack(audiopack[]);
Called when an audio pack is set


Audio_OnTransferFile(playerid, file[], current, total, result);
Called when a player completes the transfer of a file; the result can be one of the following:
0: Local file downloaded successfully
1: Remote file downloaded successfully
2: Archive extracted successfully
3: File passed CRC check, file size check, or file count check
4: File could not be downloaded, file did not pass the CRC or file size check, or archive could not be extracted (if the audio pack is non-transferable)


Audio_OnPlay(playerid, handleid);
Called when a player starts an audio file


Audio_OnStop(playerid, handleid);
Called when a player stops an audio file (including when the file finishes playing on its own)


Audio_OnTrackChange(playerid, handleid, track[]);
Called when a track change occurs in an online station

Share this post


Link to post
Share on other sites

tare dar :P am o intrebare :D daca vrei sa imi raspunzi :D

muzica pe care o pun sa asculte jucatori se aude doar la cei care au pluginsul instalat ? sau doar serverul trebuie sa aiba instalat pluginsul ?

creeaza lag mare ?

Share this post


Link to post
Share on other sites

RuNix" post="30473" timestamp="1273436239"]

tare dar :P am o intrebare :D daca vrei sa imi raspunzi :D

muzica pe care o pun sa asculte jucatori se aude doar la cei care au pluginsul instalat ? sau doar serverul trebuie sa aiba instalat pluginsul ?

creeaza lag mare ?

Guardian Angel link=topic=4622.msg30467#msg30467 date=1273433955]

Vor auzi melodia care va fi pornita de unul dintre administratorii/useri serverului (in functie de scripting), doar cei ce au instalat si clientul audio in San Andreas-ul lor.

oh si nu creeaza lag, ma rog mie eu nu am probleme am incercat si merge perfect :)

deci este facut din 2 parti, clientul (pe care trebuie sa il aibe fiecare jucator care vrea sa auda melodiile) si pluginul pentru server :)

Share this post


Link to post
Share on other sites
Guest farse

Vorba vine...macar daca era facut de tine...

[me=Farse]swear Guard...[/me]

Share this post


Link to post
Share on other sites
Guest farse

A fost publicat in "June 16, 2009, 04:12:51 pm"...si daca am vazut 2 servere care aveau pluginu asta..(Crash'n'Burn si Ro-zOnE :P )

[me=Farse]acclaim Farse[/me]

Share this post


Link to post
Share on other sites
Guest farse

Aud doar cei care au si clientul instalat

http://files.uploadffs.com/d/0/0a44028c/audio_client_plugin_v04_install.exe

Share this post


Link to post
Share on other sites

RuNix" post="30473" timestamp="1273436239"]

tare dar :P am o intrebare :D daca vrei sa imi raspunzi :D

muzica pe care o pun sa asculte jucatori se aude doar la cei care au pluginsul instalat ? sau doar serverul trebuie sa aiba instalat pluginsul ?

creeaza lag mare ?

E foarte bun plugin-ul, bravo cat despre tine @RuNix nu creeaza lag ca si eu l-am folosit :P

Share this post


Link to post
Share on other sites

lol = ))

asta nu e tutorial ma

e doar prezentarea unui plug-in

pai asa e, citeste cu atentie:

Tutorial De Instalare!

http://forum.sa-mp.ro/index.php?topic=4623.0

;), si asta e postat in plug-in :P

Share this post


Link to post
Share on other sites
Guest Darkye

Nu in Delphi ...<.<

Sigur ca in c++,toate pluginurile se fac in c++ :D

Poate intr-o zi o sa invat si eu C++ asa incat sa pot sa fac programe, ca la scoala ne invata numai cum (cenzurat) sa rezolvam probleme.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×

Important Information

This site uses cookies. By continuing browsing, you agree to the use of this information. For more details, see Terms of Use and Privacy Policy.