Title    : AntiLag Q3 MOD
Version  : Beta 2
Date     : 11/09/01
Author   : Thomas "Calv-1" Cramaro <tcramaro@club-internet.fr>
Web Page : http://www.shadow-star.net or http://www.planetquake.com/shadowstar

//------//
//Intro://
//------//
Welcome to AntiLag Q3 MOD. 

//-----------------//
//Goal of this MOD://
//-----------------//
This mod has been a long time coming ... really painfull coding during summer 2001.
I hope you guys will love it ...
This MOD was first done to prove that you can predict bullets in quake3.
But now, I've been able to predict projectile weapons too : 
AntiLag Q3 MOD works with ALL weapons !
AntiLag Q3 MOD can give modem players much better gameplay with a client-side hitscan. 

AntiLag Q3 MOD is a modification that replaces Quake 3 arena normal, server-side hit test 
with client-side code. Since AntiLag Q3 MOD checks to see if your shot was a hit 
on your own side, your weapons will fire instantly since it doesn't need to tell it 
to the server...
It will be much easier to aim.
You'll still see a lag between your shot and your enemy's death, 
but that won't affect your accuracy at all. 

Yeah, you ear me, AntiLag Q3 MOD works with ALL weapons !
All weapons will fire when you press fire, no matter what your ping is...
If someone is in your crosshair at the moment you pressed the attack button,
they'll get hit (only for hit scan weapons, projectiles will appear 
at the moment you pressed the attack button).
As accurate as in a LAN !!!

Notice : Rocket, Grenade, BFG, Plasmajump are still like in vanilla q3a !

//---------------------------//
//How to Install Antilag MOD://
//---------------------------//
-ZIP VERSION:

IMPORTANT : IF YOU GOT A PREVIOUS ZIP VERSION INSTALLED, REMOVE PAK1.PK3 FROM THE FOLDER !!!
	    AND THE MOST BETTER THING IS TO ERASE ALL THAT IS IN THAT DIRECTORY, EXCEPT .CFG

Unzip the antilag_Q3_mod_beta_2.zip in the root Quake3/ directory, with folders enabled.
You should have a newly created directory named "antilag" with that inside :

-ReadMe.txt			(this file)
-pak0.pk3			(all needed mod filez)
-server.cfg			(configuration file for running a dedicated server)
-antilag.bat			(a batch file to launch the mod on windows98)
-Antilag_Dedicated_Server.bat	(a batch file used to start a dedicated server on windows98)

READ : IF YOU GOT a PAK1.PK3 in the "antilag" directory, REMOVE IT !!!

-INSTALL VERSION EXE:

No problem with that ;)

//---------------------------------------//
//To start up a DEDICATED ANTILAG server://
//---------------------------------------//
quake3 +set dedicated 2 +set com_hunkmegs <n> +set sv_pure 1
       +set fs_game antilag +exec server.cfg

The value for com_hunkmegs really depends on how many clients you want
to support.

I suggest you to look at OSP documents if you're not sure about something.
They've done an impressive documentation work that i can't afford.
I hope they'll not blame me about that :)
OSP url : http://www.OrangeSmoothie.org --> rhea@OrangeSmoothie.org
Thanks guyz !

//---------------------------//
//Available antilag commands://
//---------------------------//

  -----------
- Client side :
  -----------
cg_bulletprediction      <0/1> 	// 0 - Bullet prediction off.
			       	// 1 - Bullet prediction on (default).

cg_projectileprediction  <0/1> 	// 0 - Projectile prediction off.
			       	// 1 - Projectile prediction on (default).

players                        	// Displays all player id's and settings on the server.

referee                 <pass> 	// Enables Referee status.

lock				// Lock your team (team play only).

unlock				// Unlock your team (team play only).

  -----------
- Server side :
  -----------
g_allowbulletcorrection : Ensures that a brush (or any other solid object) isn't 
		   	  in the way of a shot (hit-scan weapons only).
			
			 <0/1> 	// 0 - Bullet correction disabled (default).
			       	// 1 - Bullet correction enabled.

g_allowweaponprediction  <0/1> 	// 0 - Weapon prediction disabled.
			       	// 1 - Allow weapon prediction (default).

match_hurtself           <0/1> 	// 0 - Player can't inflict splash damage to himself.
			       	// 1 - Player can inflict splash damage to himself (default).

match_instagib           <0/1> 	// 0 - Normal DM (default).
			       	// 1 - Instagib gameplay, only railgun with 500 damage.

vote_allow_falling       <0/1> 	// 0 - Falling damage disabled.
			       	// 1 - Falling damage enabled (default).

ref_password            <pass> 	// Enables you to set a referee pasword for ref status in game.

  --------
- Voteable :
  --------
Use "/callvote" and a word from this list. (for example : callvote instagib 1).
Type /callvote to see all available commands.

bulletcorrection : Ensures that a brush (or any other solid object) isn't 
		   in the way of a shot (hit-scan weapons only).

			 <0/1> 	// 0 - Bullet correction disabled (default).
			       	// 1 - Bullet correction enabled.

fallingdamage :		 <0/1> 	// 0 - Falling damage disabled.
			       	// 1 - Falling damage enabled (default).

hurtself           	 <0/1> 	// 0 - Player can't inflict splash damage to himself.
			       	// 1 - Player can inflict splash damage to himself (default).

instagib :       	 <0/1> 	// 0 - Normal DM (default).
			       	// 1 - Instagib gameplay, only railgun with 500 damage.

  -----------------
- Referee commands :
  -----------------
You need to be a referee to use those commands.
To become referee, you need to type "/referee <ref_password>" if the option is enabled on the server.
Use "/ref" and a word from this list. (for example : ref kick 1).
Type "/ref help" to see all available commands.

fraglimit <value> :	Set fraglimit to specified value.
help :			List available commands.
kick <player_id> :	Kick selected player, type "/players" to get a list of players ID.
			You cannot kick another referee.
lock :			Locks both teams to allow more players to join.
map <mapname>:		Change the map to the one specified.
map_restart <seconds> :	Restart the map.
mode <value> :		Change the gametype to the one specified.
timelimit <value> :	Set timelimit to specified value.
unlock :		Unlocks both teams to allow more players to join.
unreferee :		Used to disable your referee status.

//-----------//
//Known bugs://
//-----------//
-When trying to rocketjump while looking at the maximum down, players will see your rocket go behind.
-Modem players will get "connection interrupted" message with the plasmagun while wall-climbing
 or while using it at close range.
-Can't get "cl_maxpackets" cvar in player ID .
-While spectating through a player the shots fired will not appear to be accurate,
 this is due to lag in between you and the other client.
-Grenade will sometime get stuck into jumpads, well it depends from where the shot was fired.

//-------------//
//Improvements://
//-------------//
-beta 2:
--------
	-Added Grenade Launcher support.
	-Added Rocket Launcher support.
	-Added Plasma Gun support.
	-Added BFG support.
	-Fixed the "message of dead" when two players were killing each other 
	 at the same time in instagib.
	-Added Bullet Correction support, g_allowbulletcorrection, if on, server check 
	 the shot to ensure that a brush isn't in the way of it.
	-Added g_allowweaponprediction cvar, now admins can allow players to use 
	 antilag prediction, or force it to 0.
	-Added match_instagib cvar, if on, instagib gameplay, only railgun with 500 damage.
	-Added vote_allow_falling cvar, if off, falling damage is disabled.
	-Added match_hurtself cvar, if off, player can't inflict splash damage to himself.
	-Instagib is voteable to be enabled/disabled, and not a gametype any longer.
	-Falling damage is voteable to be enabled/disabled.
	-Hurt self is voteable to be enabled/disabled.
	-Bullet Correction is voteable to be enabled/disabled.
        -Added a referee status accessable through a password.
        -Added a "/players" command that allows poeple to view a players id number and settings.        
-beta 1:
--------
	-Added Instagib game mode.
	-Added a simple zoom feature for railgun in instagib.
	-Fixed the double railtrail for bots... cause of the cg_bulletprediction cvar 
	 not set for them.
-alpha 9:
---------
	-Added a cg_bulletprediction Vmcvar_t ( 1 is on, 0 is off ).
	 now clients can turn bullet prediction on and off in game. 
	-Fixed the non opening door bug (when firing at it with a predicted weapon).
	-Fixed the bullet in water effect for predicted bullet weapons
	 (shotgun and machinegun).
-alpha 8.1:
-----------
	-Removed some annoying debug messages.
	-Fixed some spell errors.
-alpha 8:
---------
	-Fixed lightning gun bolt prediction.
	-Fixed the bug that was happening when two players 
	 were trying to damage each other with the lightning gun.
	-Fixed the marks on wall for the gauntlet.
	-Fixed the railgun color dot.
	-Fixed the shotgun.
	-Added a g_version Vmcvar_t so people know if they've got the good
	 version when connecting to a server.
-alpha 7:
---------
	-Added Gauntlet antilag support.
	-Added Shotgun antilag support.
	-Added Lightning gun antilag support.
	-Fixed the "blood on doors and platform objects" bug.
	-Fixed the "bullet impact on sky" bug.
	-Fixed the "Sank like a rock" bug (killing a player when you're dead, 
	 cause of the lag).
-alpha 6:
---------
	-New method, got to find bugs ...
	-works more accuratly.
-alpha 5:
---------
	-Finally removed the ugly "blood but no hit" bug ...
-alpha 4:
---------
	-Added a filter when searching for a server, you'll only search for antilag server.
	-I've done an installer.
-alpha 3:
---------
	-prediction is only done with machinegun and railgun for the moment ...
-alpha 2 :
----------
	-succesfully implemented a random pattern on predicted bullets ...
	in the first version i was just testing the trace function and its accuracy.
	-I've added the railtrail ...
-alpha 1 : 
----------
	-none :)

//----------------//
//Version history://
//----------------//
-07/17/01 : Launching of the test version.
-08/13/01(morning) : test version 2.
-08/13/01(night) : Alpha realease 3.
-08/14/01 : Alpha release 4.
-08/15/01 : Alpha release 5.
-08/28/01 : Alpha release 6.
-08/31/01 : Alpha release 7.
-09/03/01 : Alpha release 8.
-09/03/01 : Alpha release 8.1.
-10/26/01 : Alpha release 9.
-10/27/01 : Beta 1.
-11/09/01 : Beta 2.

//-------//
//Thanks://
//-------//
I'd like to thank my brother Tony, Voodoo, Epox, IceQream (Ogoun :p), Encryption, 
Stonefish, Wmlacovl and all i forgot for helping me to test the MOD.
I'd like to thank StoneFish, Nobody0 and all admins that host antilag servers.

--------------------------------------------------------------------------------------------
Calv-1 coder of Shadowstar Conflict Q3 TC MOD http://www.planetquake.com/shadowstar 

