Raised This Month: $ Target: $400
 0% 

Change pitch for all sounds


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 10-04-2009 , 15:31   Re: Change pitch for all sounds
Reply With Quote #3

PHP Code:
#include <amxmodx>
#include <fakemeta>

#define VERSION "0.0.1"

#define NEW_PITCH    80

#define SENDAUDIO_MESSAGE_PITCH_ARG 3

public plugin_init()
{
    
register_plugin("Sounds Pitch"VERSION"ConnorMcLeod")

    
register_forward(FM_EmitSound"EmitSound")
    
register_forward(FM_EmitAmbientSound"EmitAmbientSound")
    
register_message(get_user_msgid("SendAudio"), "Message_SendAudio")
}

public 
EmitSound(const iEnt, const iChan, const szSample[], const Float:fVol, const Float:fAttn, const iFlags, const iPitch)
{
    
emit_sound(iEntiChanszSamplefVolfAttniFlagsNEW_PITCH)
    return 
FMRES_SUPERCEDE
}

public 
EmitAmbientSound(const iEnt, const Float:vecPos[3], const szSample[], const Float:fVol, const Float:fAttn, const iFlags, const iPitch)
{
    
engfuncEngFunc_EmitAmbientSoundiEntvecPosszSamplefVolfAttniFlagsNEW_PITCH)
    return 
FMRES_SUPERCEDE
}

public 
Message_SendAudio(const iMsgId, const iMsgDest, const id)
{
    
set_msg_arg_int(SENDAUDIO_MESSAGE_PITCH_ARGARG_SHORTNEW_PITCH)

__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
 



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 22:42.


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