Semi-auto Firing
Created By: CheapAlert
eMail: cheapalert@planetquake.com
Difficulty Scale: Easy


You probably have played Counter-Strike and fired the pistol, that you have to keep clicking rapidly to start the usual everyday argue fight on a CS server. Well today we're gonna make the shotgun fire like a pistol from CS. It's easy. It'll take Quake a step closer to the worst game in the history of games. Except that this turns the shotgun into a trustworthy riotgun.

Step 1.

First break into DEFS.QC, drop down to the bottom edge of the file, hit enter several times, then type in:

.float semi; // CHP - Semiauto 

Save and close DEFS.QC.

Step 2.

Open WEAPONS.QC.

Go to W_Attack function

find:

	else if (self.weapon == IT_SHOTGUN)
	{
		player_shot1 ();
		W_FireShotgun ();
		self.attack_finished = time + 0.5;
	}

change to:

	else if (self.weapon == IT_SHOTGUN)
	{
         if(!self.semi){
                         player_shot1 ();
                         W_FireShotgun ();
                         self.semi = 1; // chpsemiauto
                         self.attack_finished = time + 0.1; // faster
                       }
	}

What you see above is the place where once you hold the trigger, it fires once. Pretty much the same way ID did to stop the Quake guy from pogo-stick jumping.


Step 3.

Scroll down to W_WeaponFrame, at this part of the function:

// check for attack
	if (self.button0)
	{
		SuperDamageSound ();
		W_Attack ();
	}

Above the first line, add:

// CHP - Semi Auto Tutorial
        if (!self.button0)
                self.semi = 0; // CHP - Semi Auto Trigger

Save, compile and run. Now pump them with pellets. Repeatedly. Until you get your carpal tunnel syndrome. Enjoy.