|
|
#1 |
|
Huge Clucker
![]() ![]() ![]() Join Date: May 2006
Posts: 284
|
Audio Plugin v0.4
This plugin creates a TCP server that can communicate with external clients to transfer and play back audio files, stream audio files from the Internet, and extract audio archives from the game. The concept is based on hansen111's Sound Unlimited project. It has several features, including:
Changelog v0.4: - Ported the external client to an ASI plugin that loads automatically with SA-MP - Fixed several bugs and optimized a lot of code in both the client plugin and the server plugin - Added support for real 3D playback (Audio_Set3DPosition now accepts game world coordinates) - Added support for downmixing so that Audio_SetFX, Audio_SetEAX, and Audio_Set3DOffsets will work with any audio stream - Made the TCP server start automatically (using same port as the SA-MP server) when a script containing the include file is loaded - Removed limitations on files, sequence IDs, and handle IDs Refer to readme.txt in the server package for the full changelog. Natives
Callbacks
Download Client Plugin (Windows) (Mirror) Server Plugin (Windows and Linux) (Mirror) Client Plugin Source Code (Windows) (Mirror) Server Plugin Source Code (Cross-Compatible) (Mirror) If you are running Windows, you must install the Microsoft .NET Framework 3.5 SP1 or higher. Last edited by Incognito; 05/07/2010 at 05:20 PM. |
|
|
|
|
|
#2 |
|
Huge Clucker
![]() ![]() ![]() Join Date: May 2006
Posts: 284
|
Tutorial
Client: Installation and use of the client plugin is simple—just run the installer and extract the files to your GTA: San Andreas directory. The ASI plugin detects when SA-MP is loaded and obtains your current player name, server address, and server port automatically. It will then attempt to connect to the TCP server (if there is one) some time after the game has started. By default, there will be a total of five retry attempts with a delay of twenty seconds each. To adjust these numbers, along with a few other settings, you need to edit audio.ini. To locate this file, go to Start, click Run, and type in the following: Code:
%APPDATA%\SA-MP Audio Plugin Server: First, create a folder called plugins in your server directory if it doesn't already exist. Place audio.dll in it if you're using Windows, or audio.so if you're using Linux. Add the following line to server.cfg so that the plugin will load the next time the server starts: Windows: Code:
plugins audio Code:
plugins audio.so pawn Code:
The server log should also indicate that the TCP server was created successfully on the same port that the SA-MP sever is using. Ensure that both the audiopacks folder and the audio.ini file are in the root directory of the server. Open audio.ini and add a section for your audio pack name. For demonstration purposes, this will be called "default_pack": Code:
[default_pack] Code:
[default_pack] 1 = test.wav pawn Code:
You can also map remote files that don't need to be in your audiopacks directory. They must start with http:// or ftp://. Here's an example: Code:
[default_pack] 1 = test.wav 2 = http://www.website.com/example.mp3 Code:
[default_pack] 1 = test.wav 2 = http://www.website.com/example.mp3 archive = AMBIENCE pawn Code:
That will ensure that audio packs are set and transferred correctly (more information is available in the example filterscript). Alternatively, you can just completely ignore audio.ini and use the Audio_PlayStreamed native. The choice is yours. Audio Archives There are 63915 audio files from 25 archives that can be extracted. Of these, 1922 are streams from 16 archives and 61993 are sound effects from 9 archives. It is also worth noting that the streams are OGG Vorbis files, and the sound effects are WAV files. The following are valid archives that can be extracted: Streams: AA Police radio messages (1001-1066) ADVERTS Advertisements for radio stations (1067-1135) AMBIENCE Background environment sounds (1136-1175) BEATS Beats and various other dance tracks (1176-1185) CH Playback FM (1186-1315) CO K-Rose (1316-1470) CR K-DST (1471-1626) CUTSCENE Mission cutscenes (1627-1767) DS Bounce FM (1768-1946) HC SF-UR (1947-2061) MH Radio Los Santos (2062-2213) MR Radio X (2214-2360) NJ CSR 103.9 (2361-2490) RE K-JAH (2491-2651) RG Master Sounds 98.3 (2652-2821) TK WCTR (2822-2922) Sound effects: FEET Running and walking sounds (2923-2960) GENRL Vehicle and weapon sounds (2961-3612) PAIN_A Pain sounds from player (3613-4013) SCRIPT Scripted voice clips and other sounds (4014-10864) SPC_EA Emergency service speech (10865-14509) SPC_FA Girlfriend and clerk speech (14510-17250) SPC_GA Normal pedestrian speech (17251-48484) SPC_NA Gang member and special character speech (48485-60807) SPC_PA Non-mission speech from CJ (60808-64915) Refer to saat\mappings.ini in the client package for a complete list of reserved audio IDs. To see how streams are sequenced in the game, refer to saat\metadata-full.ini. Last edited by Incognito; 05/07/2010 at 05:16 PM. |
|
|
|
|
|
#3 | |
|
Huge Clucker
![]() ![]() ![]() Join Date: Nov 2007
Posts: 450
|
Quote:
Great job! |
|
|
|
|
|
|
#4 |
|
Gangsta
![]() ![]() ![]() ![]() Join Date: Nov 2007
Location: Shenzhen,China
Posts: 704
|
Wow,great development!
|
|
|
|
|
|
#5 |
|
High-roller
![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Posts: 1,005
|
OMG nice job!!!
|
|
|
|
|
|
#6 |
|
Big Clucker
![]() ![]() Join Date: Feb 2008
Posts: 147
|
niiiiiiiiiiiiiiiiiiiiice !!!!!
|
|
|
|
|
|
#7 |
|
Gangsta
![]() ![]() ![]() ![]() Join Date: Feb 2008
Posts: 619
|
Nice job, but I think I'll use Punk kids when it comes out, I'v supported his project this far.
I'm still going to tets though, sound sinteresting. |
|
|
|
|
|
#8 |
|
Godfather
![]() ![]() ![]() ![]() ![]() ![]() Join Date: May 2009
Location: Croatia at the time of King Tomislav
Posts: 6,937
|
This is amazing! Good work.
|
|
|
|
|
|
#9 |
|
Big Clucker
![]() ![]() Join Date: Oct 2007
Posts: 67
|
It's really cool !!!!!
Small suggestion: add GetPluginVersion to simplify the comparison of the client version and version of plugin |
|
|
|
|
|
#10 |
|
Huge Clucker
![]() ![]() ![]() Join Date: Nov 2007
Posts: 450
|
Is there a program or some other way to fill audio.inc with names of all the files existed in audiopacks(or only some folders there) folder?
I mean, it's pretty annoying to copy/paste file names, especially if it's about 30 of them.. P.S. Testing, works great |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Ïðîáëåìà ñ Audio Plugin îò Incognito | Xotab | Русский/Russian | 4 | 09/07/2010 09:58 AM |
| Radio ingame mit Audio Plugin | GooMan | Scripting Diskussion und Showroom | 3 | 09/07/2010 04:31 AM |
| Problem audio plugin | Terminator3 | Polski/Polish | 0 | 18/06/2010 03:01 PM |
| Audio Plugin | haering | Deutsch/German | 0 | 07/06/2010 07:09 PM |
| [REL] ScriptPlayer 1.2 by Pghpunkid - Custom Audio Plugin/Filterscript | Pghpunkid | Filter Scripts and Includes | 31 | 06/07/2009 06:39 AM |