havoc [Wed, 17 Oct 2007 04:51:47 +0000 (04:51 +0000)]
implemented a fixed function fallback for water, but it is disabled
because of extreme distortion artifacts (it would need to use a cubemap
for perspective correction)
implemented two-pass rendering of water and refraction surfaces, this
enables blendfunc of the first layer to work properly, the old path is
still present but disabled
havoc [Mon, 15 Oct 2007 12:07:28 +0000 (12:07 +0000)]
implemented MATERIALFLAG_REFRACTION
changed syntax of dp_refract, dp_reflect, added dp_water
moved SHADERPERMUTATION and friends to gl_rmain.c
eliminated SHADERPERMUTATION_MASK by separating out SHADERTYPE_USES
other cleanup
divverent [Thu, 11 Oct 2007 22:08:05 +0000 (22:08 +0000)]
- fix SEGFAULT when a .shader file has more layers than allowed
- reduce number of layers from 8 to 2 to save memory (increase it later when additional layers are actually USED)
- parse ALL layers, even those behind the limit, to check for lightmap references and similar stuff
- when looking up a shader, only look through the actually DEFINED layers (not through all ALLOCATED ones), this means that the OS won't allocate pages more shaders than actually used
- increase maximum number of tcmods from 4 to 8 for Nexuiz
net: 1300MB -> 900MB vsize, and less RSS used too; so it won't swap any more on a 1GB system
divverent [Thu, 11 Oct 2007 14:06:13 +0000 (14:06 +0000)]
only print the "missing texture for missing shader" message for developer or Q3BSP (as other formats contain their own textures, and don't NEED the actual texture file)
divverent [Sun, 7 Oct 2007 09:04:05 +0000 (09:04 +0000)]
changed reflect/refract keywords to
dp_reflect <r> <g> <b>
dp_refract <reflectmin> <reflectmax> <distort> <r> <g> <b>
made dp_reflect work additively again (so perfect mirrors shall use a black texture)
divverent [Sat, 6 Oct 2007 19:24:44 +0000 (19:24 +0000)]
make bestweapon customizable using a new register_bestweapon command (DP_CON_BESTWEAPON); add a new cycleweapon command that works similarily to bestweapon, but cycles among the weapons in the list
havoc [Mon, 1 Oct 2007 03:39:40 +0000 (03:39 +0000)]
implemented support for more than 32768 clipnodes (again a case of
arguire qbsp producing files that violate the q1bsp format), this fixes
large monsters falling out of levels in warpspasm
havoc [Mon, 1 Oct 2007 03:37:39 +0000 (03:37 +0000)]
r_showtris/r_shownormals/r_showcollisionbrushes are no longer obscured
by bmodels and things that are drawn later, they now get their own
rendering stage, and have been moved after transparencies, also changed
them to use alpha blend, where their value controls the opacity
havoc [Mon, 1 Oct 2007 03:12:19 +0000 (03:12 +0000)]
added support for arguire's strange protocols that expand
modelindex/soundindex to 16bit (sometimes), these protocols are
not recommended for mods as the more standard QUAKEDP protocol already
supported 16bit indices by use of additional svc_ codes and additional
entity update bits, however these protocols are used in the warpspasm
demos, so this makes them play
implemented pvs support in water reflection rendering, greatly improving
performance with r_glsl_water 1
implemented some checks to shut off r_glsl_water if texture creation
fails
fix a bug where map becomes invisible (just sky) when the nearclip plane
culls a portal, this bug was introduced by recent water shader rendering
features (using an extra clip plane for culling, accidentally activated
the view's nearclip plane as well, which culls portals accidentally)
changed q1bsp loader to allow more than 32768 nodes, as long as the
total of nodes+leafs is <= 65536, it also attempts to fix corrupt BSP
trees by changing invalid references to instead use the solid leaf (so
you can't walk into a corrupt area), this was done to allow loading of
maps compiled with arguire's qbsp utility that can produce corrupt bsp
files
revised water shader, less refraction, more focus on reflections
added MODE_LIGHTMAP shader permutation flag, this simplified the shader
some other cleanup (q3 vertex shaded surfaces should now properly
respond to r_ambient)
implemented internal support for reflection surfaces (as opposed to full
refraction+reflection water effects)
moved resource.h and darkplaces.rc from Source Files group to Resource
Files group
added resource.h which was missing in some projects
renamed project configurations to be named darkplaces-sdl and
darkplaces-dedicated rather than merely sdl and dedicated
reduced default value of sv_clmovement_waitforinput from 16 to 4,
limiting the potential of lag-burst cheats, and causing lagging players
to start moving again a bit sooner
Added optional CSQC function CSQC_Event_Sound with the following parameters : float entitynum, float channel, string soundname, float volume, float attenuation, vector position . This function, if provided, is called whenever a sound packet arrives from the server. If the function returns true, the sound call is skipped in the engine, otherwise it is played as normal. Function intention is to provide additional feedback on sound events (without touching the packet stream).
For now, ground snd_restart and snd_unloadallsounds if the client is still connected, because DP keeps references to the sfx_t * that are being freed in the precache list. A real fix however would be ditching snd_unloadallsounds completely, and making a snd_reload command that unloads the sounds that are not being used at the moment, and reloads the sounds that are referenced.
Added optional float global sb_showscores to CSQC that represents the engine's +showscores state. To support this in your CSQC, simply add this :
float sb_showscores;
Added QC function drawcolorcodedstring (#326 CSQC, #467 MQC) which is similar to drawstring, instead it does not take in an RGB vector and instead colors the string based on the engine's coloring rules.
Useful for drawing colorized player names, centerprints, etc.
havoc [Wed, 29 Aug 2007 05:35:08 +0000 (05:35 +0000)]
fix intermission display on recorded singleplayer demos, it was checking
cl.islocalgame which is false on demo playback and thinking it should
draw multiplayer scoreboard instead of the intermission stats
havoc [Mon, 27 Aug 2007 11:12:19 +0000 (11:12 +0000)]
implemented snd_mutewhenidle cvar, defaults to 1, to allow people to
reenable sound when not the active window if they wish (such as when
watching demos)
havoc [Mon, 27 Aug 2007 11:10:41 +0000 (11:10 +0000)]
added a developer 1000 print for every key event received, attempting to
figure out why while watching the demo loop you can press the 1 key and
then escape and escape does nothing, pressing other keys reenables
escape again
dresk [Sun, 26 Aug 2007 19:02:29 +0000 (19:02 +0000)]
Added pointsound QC function to CL and SV VMs (extension DP_SV_POINTSOUND, #483). This function is very similar to sound, though instead of providing an entity, an origin is provided, and the channel parameter is omitted (since no entity is being tracked).
This function requires no modification to the protocol layer (since origin was always sent with sound calls, along with an entity).