Raised This Month: $ Target: $400
 0% 

Deagle nail Launcher 2 questions


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
avril-lavigne
Banned
Join Date: Apr 2009
Old 07-27-2011 , 12:44   Deagle nail Launcher 2 questions
Reply With Quote #1

In this plugin http://forums.alliedmods.net/showthread.php?p=717029

I want to remove explosion sound.

Code:
what this func do

stock nail_take_damage(victim,damage,origin[3],bit)
{
	message_begin(MSG_ONE_UNRELIABLE, gMsgID,{0,0,0}, victim);
	write_byte(21);
	write_byte(20);
	write_long(bit);
	write_coord(origin[0]);
	write_coord(origin[1]);
	write_coord(origin[2]);
	message_end();
	
	message_begin(MSG_BROADCAST, SVC_TEMPENTITY); 
	write_byte(TE_LAVASPLASH); 
	write_coord(origin[0]); 
	write_coord(origin[1]); 
	write_coord(origin[2]); 
	message_end(); 
	
	fm_set_user_health(victim, get_user_health(victim) - damage);
}
and here
Code:
nail_radius_damage(ptr);
				
				message_begin(MSG_BROADCAST,SVC_TEMPENTITY,iOrigin);
				write_byte(TE_EXPLOSION);
				write_coord(iOrigin[0]);
				write_coord(iOrigin[1]);
				write_coord(iOrigin[2]);
				write_short(explode2);
				write_byte(30);
				write_byte(15);
				write_byte(0);
				message_end();
			
				message_begin(MSG_BROADCAST, SVC_TEMPENTITY);
				write_byte(TE_SMOKE);
				write_coord(iOrigin[0]);
				write_coord(iOrigin[1]);
				write_coord(iOrigin[2]);
				write_short(smokesZ2);
				write_byte(40);
				write_byte(5);
				message_end();
				
				engfunc(EngFunc_RemoveEntity, ptr);
I need to remove explosion sound. not a sprite effect.....I have my own sound
__________________
VDS in Europe 1 gb/s unmetered.Any configurations.
I accept Paypal, Moneybookers,etc
avril-lavigne is offline
avril-lavigne
Banned
Join Date: Apr 2009
Old 07-27-2011 , 15:35   Re: Deagle nail Launcher 2 questions
Reply With Quote #2

ok or just here

Code:
public pfn_touch(ptr, ptd)
{	
	
		if(pev_valid(ptr))
		{	
			new classname[32];
			pev(ptr, pev_classname, classname, 31);
		
			if(equal(classname, nail_classname))
			{	
				new Float:fOrigin[3];
				new iOrigin[3];
				pev(ptr, pev_origin, fOrigin);
				FVecIVec(fOrigin,iOrigin);
			
				nail_radius_damage(ptr);
				
				message_begin(MSG_BROADCAST,SVC_TEMPENTITY,iOrigin);
				write_byte(TE_EXPLOSION);
				write_coord(iOrigin[0]);
				write_coord(iOrigin[1]);
				write_coord(iOrigin[2]);
				write_short(explode2);
				write_byte(30);
				write_byte(15);
				write_byte(0);
				message_end();			
				
                        emit_sound(0, CHAN_WEAPON, snd_hitwall[random_num(0, sizeof snd_hitwall - 1)], VOL_NORM, ATTN_NORM, 0, PITCH_NORM)

   How to determine  if  Entity touches (only) THE WALL & FLOOR




        		engfunc(EngFunc_RemoveEntity, ptr);
			        
                }
	       
	  }
       
	
}
__________________
VDS in Europe 1 gb/s unmetered.Any configurations.
I accept Paypal, Moneybookers,etc
avril-lavigne is offline
avril-lavigne
Banned
Join Date: Apr 2009
Old 07-27-2011 , 17:39   Re: Deagle nail Launcher 2 questions
Reply With Quote #3

ok found this

Code:
//-----------------------------------------------------------------------------
#define TE_EXPLOSION    3    //additive sprite, 2 dynamic lights, flickering particles, explosion sound, move vertically 8 pps

message_begin(MSG_ ,SVC_TEMPENTITY) //message begin
write_byte(TE_)
write_coord() // start position
write_coord()
write_coord() //
write_short() // sprite index
write_byte() // scale in 0.1's
write_byte() // framerate
write_byte() // flags
message_end()
//The Explosion effect has some flags to control performance/aesthetic features:
#define TE_EXPLFLAG_NONE    0  // all flags clear makes default Half-Life explosion
#define TE_EXPLFLAG_NOADDITIVE  1  // sprite will be drawn opaque ensure that the sprite you send is a non-additive sprite
#define TE_EXPLFLAG_NODLIGHTS 2 // do not render dynamic lights
#define TE_EXPLFLAG_NOSOUND   4  // do not play client explosion sound
#define TE_EXPLFLAG_NOPARTICLES 8  // do not draw particles
__________________
VDS in Europe 1 gb/s unmetered.Any configurations.
I accept Paypal, Moneybookers,etc
avril-lavigne 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 00:54.


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