Created By: Garrett Krutilla
eMail: krutillg@weir.net
Difficulty Scale: Easy


Intro
First off this tutorial changes the grenade launcher to throw 3 grenades in the same place, but each grenade explodes at a different time making it look like a grenade that explodes 3 times in a row! All changes are made in weapons.qc, so open it up NOW! Next go to W_FireGrenade. This is where all changes are made.:)


Step 1
Make a line that looks like this: local entity missile2, missile3; put it under the line that looks like this: local entity missile, mpuff;


Step 2
Copy the whole function of W_FireGrenade, you need to paste it so that there are 3 of the same funtions. It should look like this:
/*
================
W_FireGrenade
================
*/
void() W_FireGrenade =
{
        local   entity missile, mpuff;
        local entity missile2, missile3;

        self.currentammo = self.ammo_rockets = self.ammo_rockets - 0;
        
        sound (self, CHAN_WEAPON, "weapons/grenade.wav", 1, ATTN_NORM);

        self.punchangle_x = -2;

        missile = spawn ();
        missile.owner = self;
        missile.movetype = MOVETYPE_BOUNCE;
        missile.solid = SOLID_BBOX;
        missile.classname = "grenade";
                
// set missile speed    

        makevectors (self.v_angle);

        if (self.v_angle_x)
                missile.velocity = v_forward*600 + v_up * 200 + crandom()*v_right*10 + crandom()*v_up*10;
        else
        {
                missile.velocity = aim(self, 10000);
                missile.velocity = missile.velocity * 600;
                missile.velocity_z = 200;
        }

        missile.avelocity = '300 300 300';

        missile.angles = vectoangles(missile.velocity);
        
        missile.touch = GrenadeTouch;
        
// set missile duration
        missile.nextthink = time + 0.75;
        missile.think = GrenadeExplode;

        setmodel (missile, "progs/grenade.mdl");
        setsize (missile, '0 0 0', '0 0 0');            
        setorigin (missile, self.origin);

        missile2 = spawn ();
        missile2.owner = self;
        missile2.movetype = MOVETYPE_BOUNCE;
        missile2.solid = SOLID_BBOX;
        missile2.classname = "grenade";
               
// set missile speed    

        makevectors (self.v_angle);
       
        if (self.v_angle_x)
                missile2.velocity = v_forward*600 + v_up * 200 + crandom()*v_right*10 + crandom()*v_up*10;
        else
        {
                missile2.velocity = aim(self, 10000);
                missile2.velocity = missile.velocity * 600;
                missile2.velocity_z = 200;
        }

        missile2.avelocity = '300 300 300';

        missile2.angles = vectoangles(missile.velocity);
        
        missile2.touch = GrenadeTouch;
        
// set missile duration
        missile2.nextthink = time + 1.0;
        missile2.think = GrenadeExplode;

        setmodel (missile2, "progs/grenade.mdl");
        setsize (missile2, '0 0 0', '0 0 0');     
        setorigin (missile2, self.origin);

        missile3 = spawn ();
        missile3.owner = self;
        missile3.movetype = MOVETYPE_BOUNCE;
        missile3.solid = SOLID_BBOX;
        missile3.classname = "grenade";
                
// set missile speed    

        makevectors (self.v_angle);
       
        if (self.v_angle_x)
                missile3.velocity = v_forward*600 + v_up * 200 + crandom()*v_right*10 + crandom()*v_up*10;
        else
        {
                missile3.velocity = aim(self, 10000);
                missile3.velocity = missile.velocity * 600;
                missile3.velocity_z = 200;
        }              

        missile3.avelocity = '300 300 300';

        missile3.angles = vectoangles(missile.velocity);
        
        missile3.touch = GrenadeTouch;
        
// set missile duration
        missile3.nextthink = time + 1.25;
        missile3.think = GrenadeExplode;

        setmodel (missile3, "progs/grenade.mdl");
        setsize (missile3, '0 0 0', '0 0 0');     
        setorigin (missile3, self.origin);

};



Step 3
This last step makes the each grenade do 3 times less damage to make your new gun a little more fair in dm.:) Go to the line that says: void() GrenadeExplode = Then 2 lines below it has: T_RadiusDamage (self, self.owner, 120, world); change it to: T_RadiusDamage (self, self.owner, 40, world); (Note: this will not gib zombies - make it 60+ for that)