|
Veteran Member
|
05-13-2013
, 03:01
Re: How can i change the shot animation
|
#22
|
#pragma semicolon 1
Connor,this is your new style? ?) :p
Ham_CS_Weapon_SendWeaponAnim - The first argument is entiti weapons
fix:
PHP Code:
#include < amxmodx > #include < engine > #include < fakemeta_stocks > #include < hamsandwich >
#pragma semicolon 1
#define PLUGIN "Change M4a1 shot animation" #define VERSION "0.0.1"
new g_iEventM4A1;
new g_iOurCustomShotAnimationM4A1 = 7; // whatever
const m_pActiveItem = 373;
public plugin_init() { register_plugin( PLUGIN, VERSION, "ConnorMcLeod" );
g_iEventM4A1 = EF_PrecacheEvent(1, "events/m4a1.sc"); }
public pfn_playbackevent(flags, id, eventid /* , Float:delay, Float:Origin[3], Float:Angles[3], Float:fparam1, Float:fparam2, iparam1, iparam2, bparam1, bparam2 */ ) { if( eventid == g_iEventM4A1 ) { new pEntity = get_pdata_cbase( id , m_pActiveItem , 5 ); ExecuteHamB(Ham_CS_Weapon_SendWeaponAnim, pEntity, g_iOurCustomShotAnimationM4A1, 0); // make sure last param is 0. } }
But it is still not work.
Change fire sound possible only with CD_flNextAttack\CD_ID
__________________
Last edited by Bos93; 05-13-2013 at 03:07.
|
|
|
|