havoc [Sun, 18 Feb 2007 12:41:11 +0000 (12:41 +0000)]
a cosmetic change as suggested by div0:
renamed PRVM_GETEDICTFIELDVALUE to PRVM_EDICTFIELDVALUE
renamed PRVM_GETGLOBALFIELDVALUE to PRVM_GLOBALFIELDVALUE
havoc [Sun, 18 Feb 2007 11:53:09 +0000 (11:53 +0000)]
fixed a bug with png loading on x86_64 platforms caused by libpng retardedness (it defines png_uint_32 as unsigned long, which is 64bit on such architectures, AND to make it worse this can be modified in pngconf.h on a per platform basis, so we detect the problem on big endian 64bit architectures and fix it there too)
black [Sat, 17 Feb 2007 11:27:09 +0000 (11:27 +0000)]
Hopefully this fixes a bug introduced with the latest cleanup by LH.
Changed the menu code to always show the old quake menu if forceqmenu is set
(even if it lacks the gfx files).
havoc [Thu, 15 Feb 2007 00:13:49 +0000 (00:13 +0000)]
cleaned up client qc, menu qc, and server qc VM initialization a bit so they have shared field/global/function lookup code,
changed world.c to not be server specific, moved server-specific functions to sv_phys.c
havoc [Wed, 14 Feb 2007 21:22:16 +0000 (21:22 +0000)]
added a check for level changes which blocks prediction for 100ms at the beginning of the new level, and clears ping time and other information
refactored input parsing to buffer moves in sv_readmoves array, this means that it can now always trust the last move in the packet, never ignored like earlier ones (which are clearly repeats of earlier input)
havoc [Mon, 12 Feb 2007 23:38:01 +0000 (23:38 +0000)]
added cl_nettimesyncmode cvar to choose the method of synchronizing cl.time, it defaults to resetting the cl.time to the previous packet's time, but only when it is out of bounds (meaning it increases it if it is falling behind, and snaps it back to the previous packet time if it exceeds this packet's time, which eliminates accumulated error)
havoc [Sun, 11 Feb 2007 17:44:59 +0000 (17:44 +0000)]
modified Mod_LoadSkinFrame to set base = r_texture_notexture on failure, this reduced fallback code elsewhere
reworked Mod_BuildAliasSkinsFromSkinFiles, it no longer tries fallbacks if a skin texture fails to load
fixed a crash on missing meshes in a skin file (which are intentionally nodraw, just like in Quake3)
havoc [Sat, 10 Feb 2007 22:43:41 +0000 (22:43 +0000)]
added r_bloom_brighten modification in graphics options menu, this was already displayed but wasn't working, messing up all options after it
updated graphics options item count from 19 to 20
havoc [Fri, 9 Feb 2007 01:19:05 +0000 (01:19 +0000)]
fix Q3BSP map loader's sky surface detection so that it doesn't assume all submodels have sky if the base model does, this improves rendering performance a bit (by not scanning for sky in submodels that claim to have it but don't)
havoc [Thu, 8 Feb 2007 15:57:21 +0000 (15:57 +0000)]
removed CL_UpdateEntities call in CSQC rendering code
changed r_refdef.lights from dlight_t * to rtlight_t (no longer a pointer)
modified CL_UpdateLights to setup the r_refdef.lights[] entry instead of merely pointing to the rtlight_t in the dlight_t struct
changed csqc dlight handling to comply with the spec (R_ClearScene resets r_refdef.numlights, then VM_R_AddEntities adds all engine-based entities and lights)
moved single-frame dlight spawning for rocket glow and such from CL_UpdateNetworkEntity to CL_LinkNetworkEntity (which is called by VM_R_AddEntities)
replaced all single-frame uses of CL_AllocDLight with R_RTLight_Update(&r_refdef.lights[r_refdef.numlights++], ...) calls, this includes lights such as muzzleflash, rocket glow, .glow_size lights, tenebrae dlights, etc
renamed CL_AllocDlight to CL_AllocLightFlash
renamed CL_DecayLights to CL_DecayLightFlashes
renamed CL_UpdateLights to CL_RelinkLightFlashes
renamed CL_ParticleEffect to CL_ParticleTrail and added spawndlight/spawnparticles boolean parameters, then added a CL_ParticleEffect which calls this with true for both
removed cubemapnum field from dlight_t
havoc [Tue, 6 Feb 2007 08:18:50 +0000 (08:18 +0000)]
no longer sends moves if time is not moving forward, except when paused (this fixes some bugs causing cl_movement 0 to lose impulse/buttons)
no longer repeats old moves if cl_movement is off (because they would serve no purpose)
eliminated cl.movemessages (now uses cl.movesequence for the same purpose)
havoc [Mon, 5 Feb 2007 17:45:59 +0000 (17:45 +0000)]
redesigned input networking code (still same protocol) and did a lot of cleaning, now predicts movement even if server packets are lost
added cl_netinputpacketlosstolerance cvar (default 4, qw used 2, can be up to 16) to repeat old input messages in each packet so that they can only be lost by heavy packet loss
changed sv_clmovement_waitforinput default to 16 to match this capability
reworked a lot of timing code related to input networking
fixed some bugs when frametime is 0 in player physics
havoc [Sat, 3 Feb 2007 12:08:54 +0000 (12:08 +0000)]
made CL_SetInfo check for more forbidden characters (key now refuses any form of whitespace, value now refuses \r and \n) and refactored the checking code to make it a bit cleaner
havoc [Sat, 3 Feb 2007 08:49:02 +0000 (08:49 +0000)]
added r_shadow_frontsidecasting cvar (default 1), this allows switching to back-side casting instead, however this has proven buggy so it is not to be used yet
havoc [Sat, 3 Feb 2007 03:36:26 +0000 (03:36 +0000)]
fixed two bugs that caused a constant state of "player stuck" (one was that it always thought this was a q1bsp/hlbsp map, and the other was that the q1bsp/hlbsp corner checking was checking the wrong locations)
havoc [Sat, 3 Feb 2007 03:08:57 +0000 (03:08 +0000)]
fixed bug in AVI RIFF chunk 1GB size limiting code (it was not accounting for the index buffer size which will be written afterward) which was causing the chunk to often exceed 1GB
havoc [Mon, 29 Jan 2007 09:52:31 +0000 (09:52 +0000)]
fix very stupid bug in svbsp calls that made only the first triangle of an occluding surface polygon be inserted into the svbsp, and some other cleanup/corrections
havoc [Sun, 28 Jan 2007 02:57:51 +0000 (02:57 +0000)]
implemented Shadow Volume BSP based culling of lit surfaces, this is slightly better than the existing portal culling code (or much better in the case of detail brush terrain in q3bsp where little culling was performed previously), and is now the only culling method used by rtlight compilation
havoc [Sun, 28 Jan 2007 02:52:41 +0000 (02:52 +0000)]
patch from Tomaz adding a proper matrix inverter, it should be able to invert any matrix that is possible to invert, but is VERY slow, and consequently Matrix4x4_Invert_Simple has been kept for speed reasons
it is probably possible to optimize this function significantly, and it would also be possible to add non-uniform-scaling inversion to Matrix4x4_Invert_Simple to make it more flexible
havoc [Sun, 28 Jan 2007 02:50:32 +0000 (02:50 +0000)]
added Debug_Polygon functions for testing, these are currently abusing the CSQC polygon queue and have many stupid limitations which should be cleaned up at some point, but it is now possible to call these to draw things for debugging purposes
havoc [Fri, 26 Jan 2007 05:58:43 +0000 (05:58 +0000)]
changed sbar stats (Monsters/Secrets/Time/map title) around a bit, inspired by a patch from steven a but not directly based on it
specific changes: Monsters/Secrets are now on top row (rather than left side), map filename (minus path/extension) and map title are shown, time moved to far right of second row
havoc [Wed, 24 Jan 2007 21:27:06 +0000 (21:27 +0000)]
disabled use of Portal_PortalThroughPortalPlanes on triangles in exact triangle culling mode because it was falsely culling some polygons (particularly in start.bsp), this makes the culling less exact unfortunately
havoc [Wed, 24 Jan 2007 17:48:49 +0000 (17:48 +0000)]
some cleanup of shader permutation handling
expanded shader permutation system to allow multiple shader source files (not sure if this will ever be used) rather than just "glsl/default.glsl"
added code support for geometry shaders (not actually hooked up because there's no GL_ARB_geometry_shader extension yet)
added flagging of which shader objects are needed by a given permutation (to allow vertex-only shaders for shadow volume projection and such, also not implemented)
havoc [Wed, 24 Jan 2007 04:15:45 +0000 (04:15 +0000)]
redesigned tempstring system, now uses a fixed size buffer based on the prvm_tempstringmemory cvar (this is probably safe to automatically resize in the future but is not currently resized)
audited PRVM_G_STRING use in the engine (eliminated many NULL checks in functions because it never returns NULL)
added DP_QC_UNLIMITEDTEMPSTRINGS extension to indicate this new tempstring system's wonderous features (not yet documented)
havoc [Wed, 24 Jan 2007 03:56:16 +0000 (03:56 +0000)]
added r_hdr_range cvar (which just divides r_bloom_colorscale and multiplies r_bloom_brighten)
changed default r_bloom_brighten from 2 to 1 and r_bloom_colorsubtract from 0.125 to 0, this gives a more color-preserving bloom effect and actually seems brighter in many cases