Page 1 of 1

Quake 3 bugs

Posted: Mon Aug 22, 2005 7:59 pm
by ^misantropia^
Please post here about buggy or strange behavior you've noticed in the VQ3 (no mods) 1.32 point-release. Including a demo, screenshot or condump would be very much appreciated. It'll give developers a lead as to what needs fixing in the source.

Posted: Mon Aug 22, 2005 10:05 pm
by dzjepp
'True' ping not displayed. (Well, the type of ping CPMA does, so the actuall ping display should not be dependent on the persons cl_maxpackets setting).

Posted: Mon Aug 22, 2005 10:07 pm
by dzjepp
Various overbounce 'bugs'.

Posted: Mon Aug 22, 2005 10:10 pm
by dzjepp
333+ frames per second gives 'unnatural appearing' (that would otherwise not be there) physics exploits and such. This one might be hard to actually judge as to how it should be categorized though. Personally, I would prefer ALL fps settings above 125 should perform the same.

Posted: Tue Aug 23, 2005 12:04 am
by Bacon
Fix JPEG screenshotting with custom resolutions, the images either come out as 21 Kb black images or images missing parts to the game.

Posted: Sat Aug 27, 2005 2:20 am
by ensiform
- CalculateRanks function in the server-side has a data overflow problem.

Fix: g_main.c ~ line 778

Code: Select all

	//fixed a data overflow problem here. 
	for ( i = 0; i < 2; i++ ) {
	//for ( i = 0; i < TEAM_NUM_TEAMS; i++ ) {
- G_RemoveRandomBot in g_bot.c has a tendency to kick spectators of bots instead of the bot upon changes in # of players when you have bot_minplayers set.

Fix: g_bot.c Function: G_RemoveRandomBot
(take out or comment the first two code blocks here:)

Code: Select all

char netname[36];

Code: Select all

strcpy(netname, cl->pers.netname);
Q_CleanStr(netname);
trap_SendConsoleCommand( EXEC_INSERT, va("kick %s\n", netname) );

Code: Select all

trap_SendConsoleCommand( EXEC_INSERT, va("clientkick \"%d\"\n", cl->ps.clientNum));
- Railgun impact mark uses color2 when it should be using color1.

Fix: cg_weapons.c ~ line 2006

Code: Select all

color = cgs.clientinfo[clientNum].color1; // was cgs.clientinfo[clientNum].color2
- Quad DLight not team colored, and quad weapon only blue.

Fix:
Part 1: cg_players.c:

CG_PlayerPowerUps function:

just replace the quad section with this:

Code: Select all

	// quad gives a dlight
	if ( powerups & ( 1 << PW_QUAD ) ) {
		if (cgs.gametype >= GT_TEAM) {
			if ( cgs.clientinfo[ cent->currentState.clientNum ].team == TEAM_RED ) {
				trap_R_AddLightToScene( cent->lerpOrigin, 200 + (rand()&31), 1.0, 0.2f, 0.2f ); // Red DLight
			} else if ( cgs.clientinfo[ cent->currentState.clientNum ].team == TEAM_BLUE ) {
				trap_R_AddLightToScene( cent->lerpOrigin, 200 + (rand()&31), 0.2f, 0.2f, 1 ); // Blue DLight
			} else {
				// uh free team is auto team in team games, and specs uhm no items for them...
			}
		} else {
			if ( cgs.clientinfo[ cent->currentState.clientNum ].team == TEAM_FREE ) {
				trap_R_AddLightToScene( cent->lerpOrigin, 200 + (rand()&31), 0.2f, 0.2f, 1 ); // Blue DLight
			} else {
				// uh no items for specs?
			}
		}
	}
Part 2: cg_weapons.c
Function: CG_AddWeaponWithPowerups

add the int team declaration like this:

Code: Select all

static void CG_AddWeaponWithPowerups( refEntity_t *gun, int powerups, int team ) {
just replace the quad section with this:

Code: Select all

		if ( powerups & ( 1 << PW_QUAD ) ) {
			if (cgs.gametype >= GT_TEAM) {
				if (team == TEAM_RED) {
					gun->customShader = cgs.media.redQuadWeaponShader;
					trap_R_AddRefEntityToScene( gun );
				} else if (team == TEAM_BLUE) {
					gun->customShader = cgs.media.quadWeaponShader;
					trap_R_AddRefEntityToScene( gun );
				} else {
					// dont do for other teams cause they not really team here
				}
			} else {
				if (team == TEAM_FREE) {
					gun->customShader = cgs.media.quadWeaponShader;
					trap_R_AddRefEntityToScene( gun );
				} else {
					// dont do for specs
				}
			}

			//trap_R_AddRefEntityToScene( gun );
		}
scroll down to this line in CG_AddPlayerWeapon:

Code: Select all

CG_AddWeaponWithPowerups( &gun, cent->currentState.powerups );
make it so that the team argument is there:

Code: Select all

CG_AddWeaponWithPowerups( &gun, cent->currentState.powerups, team );
and the same with:

Code: Select all

CG_AddWeaponWithPowerups( &barrel, cent->currentState.powerups );
becomes:

Code: Select all

CG_AddWeaponWithPowerups( &barrel, cent->currentState.powerups, team );
Part 3:

cg_local.h ~ around the other pw shader declarations:

Code: Select all

qhandle_t	redQuadShader; // might already be there
qhandle_t	redQuadWeaponShader;
cg_main.c ~ around the other pw shader register parts

Code: Select all

	cgs.media.redQuadShader = trap_R_RegisterShader("powerups/redquad" );
	cgs.media.redQuadWeaponShader = trap_R_RegisterShader("powerups/redquadWeapon" );
make sure you take the line out that looks like this:

Code: Select all

cgs.media.redQuadShader = trap_R_RegisterShader("powerups/blueflag" );
make ur shaders and if u want the image i can post it.

- trap_SendServerCommand crashes all clients when exceeding 1024 in length. (im not sure if we are allowed to use this fix or not)

From ET 2.60 + Chrunker's Project BugFix #001:

Code: Select all

void trap_SendServerCommand( int clientNum, const char *text ) {
	// rain - #433 - commands over 1022 chars will crash the
	// client engine upon receipt, so ignore them
	// CHRUKER: b001 - Truncating the oversize server command before writing it to the log
	if( strlen( text ) > 1022 ) {
		G_LogPrintf( "%s: trap_SendServerCommand( %d, ... ) length exceeds 1022.\n", GAMEVERSION, clientNum );
		G_LogPrintf( "%s: text [%.950s]... truncated\n", GAMEVERSION, text ); return;
	}
	syscall( G_SEND_SERVER_COMMAND, clientNum, text );
}
- "/where" command doesnt display correct current origin

Fix:

g_cmds.c ~ line 1245

change the trap send server command to this:

Code: Select all

trap_SendServerCommand( ent-g_entities, va("print \"%s\n\"", vtos( ent->r.currentOrigin ) ) );
- svf_bot is not set until below in ClientConnect.

Fix:

Code: Select all

if ( !( ent->r.svFlags & SVF_BOT ) && (strcmp(value, "localhost") != 0)) {
this should be:

Code: Select all

if ( !isBot && g_needpass.integer && (strcmp(Info_ValueForKey ( userinfo, "ip" ), "localhost") != 0)) {
thats about all i got for now.

Posted: Sat Aug 27, 2005 2:34 am
by ensiform
erm the send server command exploit (q3msgboom.cfg) still affects that fix like it did for me in jedi academy... im not real sure how they fixed it in ET 2.60. possibly engine side also?

Posted: Sat Aug 27, 2005 2:52 am
by ensiform
dzjepp wrote:333+ frames per second gives 'unnatural appearing' (that would otherwise not be there) physics exploits and such. This one might be hard to actually judge as to how it should be categorized though. Personally, I would prefer ALL fps settings above 125 should perform the same.
this can be fixed by putting a cap on com_maxfps ( ive seen 1 mod other than me do this which is ETF ).

they set a limit to 30-130.

Posted: Sat Aug 27, 2005 6:49 am
by ensiform
riddla wrote:the james model bugs
what bug(s) ?

Posted: Sat Aug 27, 2005 8:33 pm
by SCDS_reyalP
Fix LAN detection, or at least provide a client equivalent of sv_lanforcerate

The current system assumes you are on a LAN if you are in the same class A/B/C IP space as the server. This is obviously wrong, and will cause you to send 1 packet per frame regardless of your netsettings.

Posted: Sat Aug 27, 2005 9:35 pm
by inolen
I noticed a rather small and silly bug. Q3 will load up *.pk3*, not *.pk3. I haven't actually fixed it yet, I figured i'd just write it up here before I forgot.

Posted: Sun Aug 28, 2005 3:10 am
by dzjepp
ensiform wrote:
dzjepp wrote:333+ frames per second gives 'unnatural appearing' (that would otherwise not be there) physics exploits and such. This one might be hard to actually judge as to how it should be categorized though. Personally, I would prefer ALL fps settings above 125 should perform the same.
this can be fixed by putting a cap on com_maxfps ( ive seen 1 mod other than me do this which is ETF ).

they set a limit to 30-130.
Yeah but VQ3 does not cap it.

Posted: Sun Aug 28, 2005 5:15 am
by ensiform
beam / continuously firing / weapons with barrels spin when in noclip and the lightning beam draws while in noclip.

Fix: bg_pmove.c ~ line 1902

Code: Select all

&& ( pm->cmd.buttons & BUTTON_ATTACK ) && ( pm->ps->ammo[ pm->ps->weapon ] ) && (!pm->ps->pm_type == PM_NOCLIP)  ) {
and since most of u use the normal gauntlet code, you should make CheckGauntletAttack also check if ur in noclip:

Fix: g_weapon.c Function CheckGauntletAttack

below the following:

Code: Select all

	if ( tr.surfaceFlags & SURF_NOIMPACT ) {
		return qfalse;
	}
add this:

Code: Select all

	if ( ent->client->noclip ) {
		return qfalse;
	}
if u wanna do a check for the target being noclip also just add this below where traceEnt is set:

Code: Select all

	if ( traceEnt->client->noclip ) {
		return qfalse;
	}

Posted: Sun Aug 28, 2005 6:12 am
by ensiform
switching teams [to spectator] ( i think person who called the vote ) automatically passes the vote.

Posted: Mon Aug 29, 2005 6:50 pm
by ensiform
not really a bug that i know of but compiling gives me this:

Code: Select all

g:\q3ev\quake3-1.32b\code\win32\win_net.c(491): warning C4133: 'function' : incompatible types - from 'qboolean *' to 'u_long *'
which would be this:

Code: Select all

	// make it non-blocking
	if( ioctlsocket( newsocket, FIONBIO, &_true ) == SOCKET_ERROR ) {
		Com_Printf( "WARNING: UDP_OpenSocket: ioctl FIONBIO: %s\n", NET_ErrorString() );
		return 0;
	}

Posted: Mon Aug 29, 2005 10:41 pm
by ensiform
woot i finally found this.

teh bugs / undocumented features archive:

http://web.archive.org/web/200406170123 ... 06208.html

Q3 Documentation Project:

http://web.archive.org/web/200403250856 ... 05563.html

Usefull Links List:
http://web.archive.org/web/200406170123 ... 06066.html

:icon25:

Posted: Mon Aug 29, 2005 11:49 pm
by TTK-Bandit

Posted: Tue Aug 30, 2005 12:05 am
by ShrapnelCity
ensiform wrote:trap_SendServerCommand crashes all clients when exceeding 1024 in length. (im not sure if we are allowed to use this fix or not)
sadly, it doesn't work, because g_syscalls.c isn't used in a QVM build.

Posted: Tue Aug 30, 2005 12:07 am
by ensiform
and who said im using vm build. dll > vm.

Posted: Tue Aug 30, 2005 9:16 pm
by Timbo
ShrapnelCity wrote:
ensiform wrote:trap_SendServerCommand crashes all clients when exceeding 1024 in length. (im not sure if we are allowed to use this fix or not)
sadly, it doesn't work, because g_syscalls.c isn't used in a QVM build.
There is nothing stopping you simply wrapping trap_SendServerCommand and replacing every call to it though.

Posted: Tue Aug 30, 2005 9:18 pm
by Timbo
ensiform wrote:and who said im using vm build. dll > vm.
What makes you think a dll is automatically better than a vm? They both have their uses.

Posted: Wed Aug 31, 2005 4:30 pm
by ensiform
couldnt this section:

cg_weapons.c in CG_LightningBolt

Code: Select all

// FIXME: crouch
muzzlePoint[2] += DEFAULT_VIEWHEIGHT;
be:

Code: Select all

// FIXME: crouch
muzzlePoint[2] += cg.predictedPlayerState.viewheight;
because ps.viewheight is set in pmove i think depending on normal/crouch/dead viewheight and thus supporting crouch.