Raised This Month: $ Target: $400
 0% 

emit_sound


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
addons_zz
Veteran Member
Join Date: Aug 2015
Location: Dreams, zz
Old 12-22-2015 , 14:10   Re: emit_sound
Reply With Quote #1

Quote:
Originally Posted by abdobiskra View Post
When i add more than 3 sounds become Random !
Does not make sense that. Could you show your full code? (attach the file)


Update:

If you want to save a function call, use this:
Code:
#include <amxmodx> #include <fun> #define VERSION "1.0" #define NEXT_SOUND_TO_PLAY() \     g_current_sound = ( g_current_sound + 1 ) % sizeof Sounds new Sounds[ 3 ][ 64 ] = { "son/sound0.wav", "son/sound1.wav", "son/sound2.wav" } new g_current_sound = -1 public plugin_init() {     register_plugin( "Test", VERSION, "Addons zz" );         register_concmd( "amx_next", "next", ADMIN_CFG, "Test" ) } public next() {     NEXT_SOUND_TO_PLAY()     server_print( "^n^n^nHERE: %s^n^n^n", Sounds[ g_current_sound ] ) }
Attached Files
File Type: sma Get Plugin or Get Source (next_sound_sequencial.sma - 474 views - 1.3 KB)
__________________
Plugin: Sublime Text - ITE , Galileo
Multi-Mod: Manager / Plugin / Server

Support me on Patreon, Ko-fi, Liberapay or Open Collective

Last edited by addons_zz; 12-22-2015 at 15:48. Reason: spelling fixes
addons_zz is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:05.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode