17 years agosplit r_shadow_realtime into r_shadow_realtime_world (which requires stencil) and...
havoc [Mon, 7 Apr 2003 01:28:47 +0000 (01:28 +0000)]
split r_shadow_realtime into r_shadow_realtime_world (which requires stencil) and r_shadow_realtime_dlight (which works without stencil)
one bug remains with scissoring dlights without stencil, I'll try to figure out this problem soon

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2924 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoredesigned surfmesh allocation in brush model loader, in preparation for some more...
havoc [Sun, 6 Apr 2003 19:24:33 +0000 (19:24 +0000)]
redesigned surfmesh allocation in brush model loader, in preparation for some more drastic changes

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2920 d7cf8633-e32d-0410-b094-e92efae38249

17 years agorelease build optimizations changed - removed -funroll-loops, added -O9
havoc [Sun, 6 Apr 2003 19:23:34 +0000 (19:23 +0000)]
release build optimizations changed - removed -funroll-loops, added -O9

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2919 d7cf8633-e32d-0410-b094-e92efae38249

17 years agorevised EntityFrame4 function prototypes (no I still haven't coded this)
havoc [Sun, 6 Apr 2003 00:23:21 +0000 (00:23 +0000)]
revised EntityFrame4 function prototypes (no I still haven't coded this)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2910 d7cf8633-e32d-0410-b094-e92efae38249

17 years agooptimized shadow volume generation a bit (only projects vertices that are necessary)
havoc [Sat, 5 Apr 2003 16:53:14 +0000 (16:53 +0000)]
optimized shadow volume generation a bit (only projects vertices that are necessary)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2909 d7cf8633-e32d-0410-b094-e92efae38249

17 years agopreparation for a new protocol upgrade to use partial frame updates
havoc [Thu, 3 Apr 2003 20:56:05 +0000 (20:56 +0000)]
preparation for a new protocol upgrade to use partial frame updates

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2901 d7cf8633-e32d-0410-b094-e92efae38249

17 years agogot rid of use of eye in entity database
havoc [Thu, 3 Apr 2003 20:55:08 +0000 (20:55 +0000)]
got rid of use of eye in entity database

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2900 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded MAX_NETRELIABLE define (currently same as MAX_DATAGRAM, but will change someday)
havoc [Thu, 3 Apr 2003 20:49:31 +0000 (20:49 +0000)]
added MAX_NETRELIABLE define (currently same as MAX_DATAGRAM, but will change someday)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2899 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoAdded support for JPEG screenshots. You can toggle that with the cvar "scr_screenshot...
molivier [Thu, 3 Apr 2003 08:02:14 +0000 (08:02 +0000)]
Added support for JPEG screenshots. You can toggle that with the cvar "scr_screenshot_jpeg" or the option menu. Note that you'll need the libjpeg library DLL.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2897 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix for server dying when someone times out
havoc [Thu, 3 Apr 2003 00:11:08 +0000 (00:11 +0000)]
fix for server dying when someone times out
some other cleanups (some Sys_Printf calls turned into Con_Printf, some comments added about DropClient calls)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2895 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix for incorrect rounding of vertex locations when using RENDER_LOWPRECISION (now...
havoc [Wed, 2 Apr 2003 18:51:59 +0000 (18:51 +0000)]
fix for incorrect rounding of vertex locations when using RENDER_LOWPRECISION (now it always rounds to nearest)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2894 d7cf8633-e32d-0410-b094-e92efae38249

17 years agocleaned up pr_builtins array (now uses NULL instead of PF_fixme) and now reports...
havoc [Wed, 2 Apr 2003 00:22:15 +0000 (00:22 +0000)]
cleaned up pr_builtins array (now uses NULL instead of PF_fixme) and now reports builtin number if an unknown builtin is called
fixed name of PF_setcolor (was setcolors)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2892 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofixed NET_SendToAll
havoc [Wed, 2 Apr 2003 00:20:10 +0000 (00:20 +0000)]
fixed NET_SendToAll

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2891 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded some commented out code to Image_HeightmapToNormalmap explaining how to do...
havoc [Mon, 31 Mar 2003 21:46:06 +0000 (21:46 +0000)]
added some commented out code to Image_HeightmapToNormalmap explaining how to do heightmap to normalmap conversion a little bit differently (very insignificant difference, purely code for those who care)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2890 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoQSG_FILE removed because some mods use the old builtin numbers and think that QSG_FIL...
havoc [Mon, 31 Mar 2003 21:43:50 +0000 (21:43 +0000)]
QSG_FILE removed because some mods use the old builtin numbers and think that QSG_FILE would provide them (FRIK_FILE remains, which uses the new numbers already)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2889 d7cf8633-e32d-0410-b094-e92efae38249

17 years agodlights now cast shadows in realtime lighting mode again (actually they already did...
havoc [Sun, 30 Mar 2003 19:19:06 +0000 (19:19 +0000)]
dlights now cast shadows in realtime lighting mode again (actually they already did, but it wasn't working for world, because world didn't have the shadow flag set)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2888 d7cf8633-e32d-0410-b094-e92efae38249

17 years agono longer complains about missing ambient liquid sounds in nexuiz
havoc [Sun, 30 Mar 2003 19:18:05 +0000 (19:18 +0000)]
no longer complains about missing ambient liquid sounds in nexuiz

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2887 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoremoved a couple unused hz_bitstream_read functions
havoc [Sun, 30 Mar 2003 08:40:28 +0000 (08:40 +0000)]
removed a couple unused hz_bitstream_read functions

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2886 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix zym model rendering (wrong vertex padding)
havoc [Sat, 29 Mar 2003 20:02:11 +0000 (20:02 +0000)]
fix zym model rendering (wrong vertex padding)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2878 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoElric added deflated file support for pk3 archives (in other words: compressed pk3...
havoc [Sat, 29 Mar 2003 18:58:11 +0000 (18:58 +0000)]
Elric added deflated file support for pk3 archives (in other words: compressed pk3 now work), even with FS_Seek support, I'm amazed, thanks Elric! :)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2877 d7cf8633-e32d-0410-b094-e92efae38249

17 years agocorrected the misspelled name GAME_NEXIUZ (and related things) to GAME_NEXUIZ (and...
havoc [Fri, 28 Mar 2003 16:45:23 +0000 (16:45 +0000)]
corrected the misspelled name GAME_NEXIUZ (and related things) to GAME_NEXUIZ (and related things)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2875 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoUDP_StringToAddr did not work with less than full x.x.x.x:x specifications, now it...
havoc [Fri, 28 Mar 2003 15:47:33 +0000 (15:47 +0000)]
UDP_StringToAddr did not work with less than full x.x.x.x:x specifications, now it supports all the stuff PartialIPAddress supported (filling in most significant components with myAddr, etc)
UDP_Read and UDP_Write now log entire packets to console if developer_networking is on

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2873 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadd support for NAT fix in the client (by no longer checking the port a connection...
havoc [Fri, 28 Mar 2003 15:45:20 +0000 (15:45 +0000)]
add support for NAT fix in the client (by no longer checking the port a connection accepted came from)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2872 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded developer_networking cvar
havoc [Fri, 28 Mar 2003 15:43:52 +0000 (15:43 +0000)]
added developer_networking cvar

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2871 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoThanks to faded (of the tenebrae team) for provoking me to recite a lengthy explanati...
havoc [Fri, 28 Mar 2003 13:27:15 +0000 (13:27 +0000)]
Thanks to faded (of the tenebrae team) for provoking me to recite a lengthy explanation of NAT nightmares, and realize this very simple fix for NQ server support of clients behind NAT routers (send first message from the player socket instead of the accept socket)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2870 d7cf8633-e32d-0410-b094-e92efae38249

17 years agochanged behavior of SV_DropClient a bit (now calls ClientDisconnect QC function even...
havoc [Fri, 28 Mar 2003 13:24:11 +0000 (13:24 +0000)]
changed behavior of SV_DropClient a bit (now calls ClientDisconnect QC function even if crash is true, as it's the client being harshly dropped, not the server dying), and made the final svc_disconnect an unreliable message

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2869 d7cf8633-e32d-0410-b094-e92efae38249

17 years agorefactored NET_SendToAll, it is debatable whether it is more readable or not, but...
havoc [Fri, 28 Mar 2003 13:22:06 +0000 (13:22 +0000)]
refactored NET_SendToAll, it is debatable whether it is more readable or not, but it works the same, and is shorter, and I think it is slightly more understandable than the mess it used to be

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2868 d7cf8633-e32d-0410-b094-e92efae38249

17 years agonet_inetslist (and the corresponding menu as well) now work without being an active...
havoc [Fri, 28 Mar 2003 10:31:28 +0000 (10:31 +0000)]
net_inetslist (and the corresponding menu as well) now work without being an active server (dfunc.controlSock is now used for all transactions involved, and since there is always one of those...)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2867 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoMSG_ReadFloat now checks if the message has enough bytes for a float before trying...
havoc [Fri, 28 Mar 2003 10:29:42 +0000 (10:29 +0000)]
MSG_ReadFloat now checks if the message has enough bytes for a float before trying to decode it (why id forgot this I don't know)
added MSG_ReadBigShort, MSG_ReadBigLong, MSG_ReadBigFloat, MSG_ReadBytes
renamed MSG_ReadShort to MSG_ReadLittleShort, MSG_ReadLong to MSG_ReadLittleLong, and MSG_ReadFloat to MSG_ReadLittleFloat
added #defines for MSG_ReadShort, MSG_ReadLong, and MSG_ReadFloat to use their Little versions
optimized/cleaned up MSG_Read functions (some are now significantly shorter)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2866 d7cf8633-e32d-0410-b094-e92efae38249

17 years agonet_wins.c is gone, winsock support merged into net_udp.c
havoc [Fri, 28 Mar 2003 08:37:13 +0000 (08:37 +0000)]
net_wins.c is gone, winsock support merged into net_udp.c
numerous other cleanups/changes also done to net_udp.c (to try to simplify it, hopefully work better, that kind of stuff)
support for partial IP addresses has been removed (that is you say you can't simply type 'connect 1.123' and have it expand to xxx.xxx.1.123 where xxx.xxx came from your own IP address, however hostnames still work fine)
also the automatic changing of the hostname cvar according to internet hostname has been removed, so servers will be called "UNNAMED" if they don't set it, rather than using their internet hostname

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2865 d7cf8633-e32d-0410-b094-e92efae38249

17 years agorenamed all net_wins.c functions to UDP instead of WINS, this allows use of net_bsd...
havoc [Fri, 28 Mar 2003 03:33:18 +0000 (03:33 +0000)]
renamed all net_wins.c functions to UDP instead of WINS, this allows use of net_bsd.c and net_udp.h instead of net_win.c and net_wins.h

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2864 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoremoved winsock_initialized counter as there are no longer two things initializing...
havoc [Fri, 28 Mar 2003 03:23:13 +0000 (03:23 +0000)]
removed winsock_initialized counter as there are no longer two things initializing winsock (wins and wipx), only one

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2863 d7cf8633-e32d-0410-b094-e92efae38249

17 years agono longer dynamically loads portions of wsock32.dll (because it required static linki...
havoc [Fri, 28 Mar 2003 03:21:12 +0000 (03:21 +0000)]
no longer dynamically loads portions of wsock32.dll (because it required static linking anyway for other parts, no point)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2862 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoforgot to remove #include "net_wipx.h"
havoc [Fri, 28 Mar 2003 03:18:57 +0000 (03:18 +0000)]
forgot to remove #include "net_wipx.h"

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2861 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoremoved winsock ipx support
havoc [Fri, 28 Mar 2003 03:04:44 +0000 (03:04 +0000)]
removed winsock ipx support

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2860 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoFix for win32 dedicated servers (oh it still doesn't compile, other problems remain...
havoc [Thu, 27 Mar 2003 12:25:32 +0000 (12:25 +0000)]
Fix for win32 dedicated servers (oh it still doesn't compile, other problems remain with sys_win.c, but this one thing has been annoying me long enough)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2858 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoElric's pk3 support (no support for compressed files yet, that's still to come)
havoc [Thu, 27 Mar 2003 08:58:58 +0000 (08:58 +0000)]
Elric's pk3 support (no support for compressed files yet, that's still to come)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2857 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoElric added BuffBigLong, BuffBigShort, BuffLittleLong, and BuffLittleShort functions...
havoc [Thu, 27 Mar 2003 08:58:07 +0000 (08:58 +0000)]
Elric added BuffBigLong, BuffBigShort, BuffLittleLong, and BuffLittleShort functions intended for reading from misaligned locations in file memory buffers (these read as bytes rather than entire numbers, so memory misalignments are not a problem on Sparc and certain other CPUs)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2856 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded FRIK_FILE (aka QSG_FILE) extension, this brings string handling and text file...
havoc [Thu, 27 Mar 2003 08:04:27 +0000 (08:04 +0000)]
added FRIK_FILE (aka QSG_FILE) extension, this brings string handling and text file access to the QuakeC support (note: files go in gamedir/data/)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2855 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded Math_atov function (ascii to vector), tries to parse any imaginable vector...
havoc [Thu, 27 Mar 2003 08:02:43 +0000 (08:02 +0000)]
added Math_atov function (ascii to vector), tries to parse any imaginable vector (even badly formatted ones with varying numbers of spaces)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2854 d7cf8633-e32d-0410-b094-e92efae38249

17 years agocreate directories when opening any file for writing, because it's a real pain having...
havoc [Thu, 27 Mar 2003 08:01:33 +0000 (08:01 +0000)]
create directories when opening any file for writing, because it's a real pain having to do it elsewhere

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2853 d7cf8633-e32d-0410-b094-e92efae38249

17 years agogot rid of R_NewMap, directly calls R_Modules_NewMap instead
havoc [Sat, 22 Mar 2003 10:23:38 +0000 (10:23 +0000)]
got rid of R_NewMap, directly calls R_Modules_NewMap instead

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2848 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix decals bug introduced by transition to matrix use
havoc [Sat, 22 Mar 2003 10:22:53 +0000 (10:22 +0000)]
fix decals bug introduced by transition to matrix use

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2847 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded more SV_CheckVelocity calls on players for safety sake
havoc [Fri, 21 Mar 2003 21:54:43 +0000 (21:54 +0000)]
added more SV_CheckVelocity calls on players for safety sake

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2846 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoThanks to IceDagger for pointing out this important optimization to multipass specula...
havoc [Fri, 21 Mar 2003 21:52:04 +0000 (21:52 +0000)]
Thanks to IceDagger for pointing out this important optimization to multipass specular rendering - removes one pass (dropping from 6 to 5 passes on GF2, 5 to 4 passes on GF3/Radeon) by squaring specular even on the first pass

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2845 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoThis is a patch from Elric greatly cleaning up the filesystem portions of the engine...
havoc [Fri, 21 Mar 2003 21:47:57 +0000 (21:47 +0000)]
This is a patch from Elric greatly cleaning up the filesystem portions of the engine, and partially prepares the engine for .pk3 support (yay), this also removes support for gzipped files (but that had been disabled for months anyway)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2844 d7cf8633-e32d-0410-b094-e92efae38249

17 years agovarray_* rewritten to remove padding (varray_vertex3f, varray_texcoord2f, varray_texc...
havoc [Sat, 15 Mar 2003 04:54:47 +0000 (04:54 +0000)]
varray_* rewritten to remove padding (varray_vertex3f, varray_texcoord2f, varray_texcoord3f, varray_color4f now exist), this required changes to a huge amount of code (but netted a 30% speed gain typically)
fixed some various bugs
added voodoo1/2 support in realtime lighting engine (well, except for the fact it still requires stencil, which voodoo1/2 don't have, this will be addressed later when world lights and dlights are independently controlled)
changed lightning beams a bit (they're now white) and due to a request I added support for r_lightningbeam_qmbtexture (loads textures/particles/lightning.pcx and knows approximately how to use it, I recommend changing r_lightningbeam_repeatdistance to make it look right)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2842 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded loading of .ent files if found (overriding entities in bsp)
havoc [Sat, 15 Mar 2003 04:53:24 +0000 (04:53 +0000)]
added loading of .ent files if found (overriding entities in bsp)
added sv_entpatch cvar (to allow disabling the feature)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2841 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoMakefiles cleanups: r_explosion.o was declared twice in all Makefiles; removed some...
molivier [Thu, 13 Mar 2003 16:10:51 +0000 (16:10 +0000)]
Makefiles cleanups: r_explosion.o was declared twice in all Makefiles; removed some commented-out commands; diff reduction between makefile and makefile.mingwcross; forgot to call builddate previously; strip was even called on non-release binaries.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2840 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix for 16bit textures looking awful (bug in the alpha check for 8bit)
havoc [Wed, 12 Mar 2003 15:38:46 +0000 (15:38 +0000)]
fix for 16bit textures looking awful (bug in the alpha check for 8bit)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2839 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoFixed a MSVC6 warning in matrixlib. Added a "Public server" yes/no line in the server...
molivier [Mon, 10 Mar 2003 07:05:45 +0000 (07:05 +0000)]
Fixed a MSVC6 warning in matrixlib. Added a "Public server" yes/no line in the server creation menu. Removed a duplicated cvar declaration in "net.h".

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2821 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoVic informed me of the AGP settings (0-0.25, 0-0.25, 0.25-0.75) and video memory...
havoc [Sun, 9 Mar 2003 20:33:23 +0000 (20:33 +0000)]
Vic informed me of the AGP settings (0-0.25, 0-0.25, 0.25-0.75) and video memory settings (0-0.25, 0-0.25, 0.75-1) for use with GL_NV_vertex_array_range, they seem to have no effect but the defaults have been updated (to 0.2, 0.2, 0.7) to choose AGP

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2820 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoGL_NV_vertex_array_range support added, but disabled by default because for some...
havoc [Sun, 9 Mar 2003 16:42:54 +0000 (16:42 +0000)]
GL_NV_vertex_array_range support added, but disabled by default because for some reason it's halving my framerate rather than making it faster

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2819 d7cf8633-e32d-0410-b094-e92efae38249

17 years agochanged R_Mesh_ system (again), now uses R_Mesh_GetSpace to set up varray_* pointers...
havoc [Sun, 9 Mar 2003 11:39:08 +0000 (11:39 +0000)]
changed R_Mesh_ system (again), now uses R_Mesh_GetSpace to set up varray_* pointers, then fills in the data, then calls R_Mesh_Draw (this can be done repeatedly, but vertex data should *NOT* be modified after the first call)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2818 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoMod_FindNonSolidLocation now takes a radius and can output to a different vector...
havoc [Sun, 9 Mar 2003 11:19:57 +0000 (11:19 +0000)]
Mod_FindNonSolidLocation now takes a radius and can output to a different vector than the input (purpose: the sphere is nudged out of any surfaces in the area, this makes realtime lighting look a lot better as the lights aren't too close to the surface)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2817 d7cf8633-e32d-0410-b094-e92efae38249

17 years agomenu.c - changed M_DrawSlider to take a value and a min/max range, now prints the...
havoc [Fri, 7 Mar 2003 09:34:15 +0000 (09:34 +0000)]
menu.c - changed M_DrawSlider to take a value and a min/max range, now prints the current value of the cvar as well
menu.c, menu.h, gl_draw.c - added new color control options menu (the gl_draw.c change is merely adding a "ditherpattern" texture)
menu.c - added "Delay refresh (faster)" to options menu (gl_delayfinish cvar)
menu.c - added "Game Speed" to options menu (slowmo cvar)
vid_wgl.c, vid_glx.c, vid_null.c, vid_shared.c, vid.h, palette.c, palette.h, host.c - gamma system redesigned (VID_SetGamma now takes ramps, VID_GetGamma added, other cruft removed), moved VID_UpdateGamma to vid_shared.c, gamma is now turned off when darkplaces is minimized in X11 (unmapped), and when it's window is not active in Windows as well
vid_wgl.c - trailing whitespace fixed
vid_shared.c - added v_color_enable, v_color_black_[rgb], v_color_grey_[rgb], and v_color_white_[rgb] cvars as another way to adjust color settings
gl_draw.c - added support for v_color_* cvars, removed support for darkening screen (not possible to do in color)
vid_glx.c - got rid of unfinished X11 colormap based gamma code (using XF86 VidMode extension instead)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2813 d7cf8633-e32d-0410-b094-e92efae38249

17 years agounfinished beginnings of support for voodoo1/voodoo2 class paths for realtime lightin...
havoc [Fri, 7 Mar 2003 09:33:07 +0000 (09:33 +0000)]
unfinished beginnings of support for voodoo1/voodoo2 class paths for realtime lighting (no shadows however)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2812 d7cf8633-e32d-0410-b094-e92efae38249

17 years agonow uses TEXF_FORCELINEAR on lightmaps
havoc [Fri, 7 Mar 2003 09:31:46 +0000 (09:31 +0000)]
now uses TEXF_FORCELINEAR on lightmaps

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2811 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded TEXF_FORCENEAREST and TEXF_FORCELINEAR flags
havoc [Fri, 7 Mar 2003 09:31:10 +0000 (09:31 +0000)]

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2810 d7cf8633-e32d-0410-b094-e92efae38249

17 years agogot rid of AreaNode stuff, now only has AreaGrid (had to add sv_areagrid_outside...
havoc [Fri, 7 Mar 2003 09:30:21 +0000 (09:30 +0000)]
got rid of AreaNode stuff, now only has AreaGrid (had to add sv_areagrid_outside node)
renamed sv_useareanodes to sv_debugmove (inverted behavior)
SV_CreateAreaGrid now has a minimum grid size (sv_areagrid_mingridsize cvar), this greatly improved performance in helm18
SV_ClipToAreaGrid and SV_TouchAreaGrid no longer process any edicts twice (edict_t now has areagridmarknumber for this purpose)
increased AREA_GRID from 16 to 512
added SV_ClipToNode function to get rid of duplicate code in SV_ClipToAreaGrid

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2809 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded gl_delayfinish cvar (default off, used to always be on)
havoc [Fri, 7 Mar 2003 09:28:12 +0000 (09:28 +0000)]
added gl_delayfinish cvar (default off, used to always be on)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2808 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded invpow (arbitrary logarithm, finds a power that the base number would need...
havoc [Fri, 7 Mar 2003 09:27:33 +0000 (09:27 +0000)]
added invpow (arbitrary logarithm, finds a power that the base number would need to be raised to, to get the requested number)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2807 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded DrawQ_SuperPic, fixed severe bug in DrawQ_Mesh (was not allocating enough room...
havoc [Fri, 7 Mar 2003 09:26:11 +0000 (09:26 +0000)]
added DrawQ_SuperPic, fixed severe bug in DrawQ_Mesh (was not allocating enough room in drawqueue for the texcoords), DrawQ_Pic and DrawQ_Fill now use DrawQ_SuperPic

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2806 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoview.c, cl_parse.c, cl_main.c, gl_rmain.c - trying to remove all uses of origin,...
havoc [Fri, 7 Mar 2003 09:24:59 +0000 (09:24 +0000)]
view.c, cl_parse.c, cl_main.c, gl_rmain.c - trying to remove all uses of origin, angles, or scale fields of entity_render_t
view.c, gl_rmain.c - viewmodel entities are now processed in view.c instead of gl_rmain.c
view.c now uses matrix and inversematrix for view damage kicks

what this means:
the QC feature viewmodelforclient now works

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2805 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded Matrix4x4_OriginFromMatrix, and Matrix4x4_ScaleFromMatrix
havoc [Fri, 7 Mar 2003 09:23:33 +0000 (09:23 +0000)]
added Matrix4x4_OriginFromMatrix, and Matrix4x4_ScaleFromMatrix

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2804 d7cf8633-e32d-0410-b094-e92efae38249

17 years agogot an email about this being out of date, fixed
havoc [Wed, 5 Mar 2003 07:20:40 +0000 (07:20 +0000)]
got an email about this being out of date, fixed

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2802 d7cf8633-e32d-0410-b094-e92efae38249

17 years agochanged gloss behavior, now darkens light intensity (to 25% of normal) instead of...
havoc [Sun, 2 Mar 2003 07:20:28 +0000 (07:20 +0000)]
changed gloss behavior, now darkens light intensity (to 25% of normal) instead of assuming gloss texture is dim, this is consistent with tenebrae behavior, inconsistent with doom3 behavior (sigh...), this makes OgrO's model skins look a lot better
no longer spews 'refusing to create light' warnings when loading map light entities that actually aren't lights at all

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2797 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix external model skins (they weren't rendering)
havoc [Sun, 2 Mar 2003 07:18:14 +0000 (07:18 +0000)]
fix external model skins (they weren't rendering)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2796 d7cf8633-e32d-0410-b094-e92efae38249

17 years agochanged lots of printf to Con_Printf
havoc [Sun, 2 Mar 2003 01:30:44 +0000 (01:30 +0000)]
changed lots of printf to Con_Printf
removed some trailing whitespace

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2795 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix improper handling of overbright pixels when saving screenshots
havoc [Fri, 28 Feb 2003 11:31:14 +0000 (11:31 +0000)]
fix improper handling of overbright pixels when saving screenshots

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2794 d7cf8633-e32d-0410-b094-e92efae38249

17 years agolights now have an orientation (this isn't editable yet, and is infact not really...
havoc [Fri, 28 Feb 2003 11:28:10 +0000 (11:28 +0000)]
lights now have an orientation (this isn't editable yet, and is infact not really supported for rotated lights at the moment, their bbox would need to be rotated)
lights now use bbox culling instead of radius (because they aren't round in 2D texture mode)
fixed LOTS of light culling bugs (particularly with surface selection)
fixed scissor to be more efficient (smaller) when easily done (entirely infront of view) and fixed some bugs
got rid of ShadowSphere code in gl_rmain.c (it was not used)
added back RadiusFromBounds (and optimized it) and added RadiusFromBoundsAndOrigin
removed trailing whitespace in mathlib.c
added BoxesOverlap macro to mathlib.h
fixed a portal-flow bug when a light lies directly inside a portal polygon (now checks both leafs involved, very mild search tolerance for leafs around the light)
added back 3d attenuation texture (true spherical lights make a return, r_shadow_texture3d cvar controls this)
fixed light-bleeding in attenuation textures at the edges (fixed a bug in the biasing during texture generation, now the edge is always black as it should be)
realtime lighting texture generation (attenuation/normalizationcubemap) now has some macros for more easily adjusting texture resolutions
reduced resolution of attenuation and normalization textures
added a bunch more rendering paths for diffuse and specular lighting, to reduce number of passes in a few cases (and allow use of 3D attenuation texture)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2793 d7cf8633-e32d-0410-b094-e92efae38249

17 years agosome added structures in in preparation for another protocol version bump (to add...
havoc [Fri, 28 Feb 2003 11:27:10 +0000 (11:27 +0000)]
some added structures in in preparation for another protocol version bump (to add partial entity updates to avoid kicking people off server when packet buffer fills up in a single frame - yes this means rate capping and such will be possible)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2792 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix chthon lightning (ugh, how did I manage to use polygon lightning for this, I...
havoc [Fri, 28 Feb 2003 11:09:24 +0000 (11:09 +0000)]
fix chthon lightning (ugh, how did I manage to use polygon lightning for this, I made polygon lightning optional per beam for this very reason!)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2791 d7cf8633-e32d-0410-b094-e92efae38249

17 years agochanged TEXF_CLAMP to use GL_CLAMP_TO_EDGE (GL_EXT_texture_edge_clamp or GL_SGIS_text...
havoc [Thu, 27 Feb 2003 00:00:31 +0000 (00:00 +0000)]
changed TEXF_CLAMP to use GL_CLAMP_TO_EDGE (GL_EXT_texture_edge_clamp or GL_SGIS_texture_edge_clamp) instead of GL_CLAMP because it's a more useful behavior all-round, also fixed normalization cubemap on non-NVIDIA cards by doing this (I was properly using GL_CLAMP for attenuation texture, but not for normalization cubemap... *slaps self*)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2787 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadjustable r_shadow_projectdistance for testing (trying to identify Radeon bug)
havoc [Wed, 26 Feb 2003 12:47:49 +0000 (12:47 +0000)]
adjustable r_shadow_projectdistance for testing (trying to identify Radeon bug)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2786 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoToo fine an AREA_GRID seems to be dropping performance in normal quake maps (I hope...
havoc [Wed, 26 Feb 2003 01:41:00 +0000 (01:41 +0000)]
Too fine an AREA_GRID seems to be dropping performance in normal quake maps (I hope this fixes the performance).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2782 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded new method of culling irrelevant entity collisions - a grid of areas
havoc [Fri, 21 Feb 2003 09:24:53 +0000 (09:24 +0000)]
added new method of culling irrelevant entity collisions - a grid of areas
the areanode system still lingers because it can cope with things the grid can not (entities outside the grid, or too large for the alloted 16 grid links per entity)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2775 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded VectorMultiply (not used by anything, but for completeness...)
havoc [Fri, 21 Feb 2003 09:22:58 +0000 (09:22 +0000)]
added VectorMultiply (not used by anything, but for completeness...)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2774 d7cf8633-e32d-0410-b094-e92efae38249

17 years agodisable step interpolation unless entity is MOVETYPE_STEP
havoc [Fri, 21 Feb 2003 09:22:27 +0000 (09:22 +0000)]
disable step interpolation unless entity is MOVETYPE_STEP

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2773 d7cf8633-e32d-0410-b094-e92efae38249

17 years agooptional polygon collisions, not ready for practical use yet, also support for brush...
havoc [Thu, 20 Feb 2003 09:22:08 +0000 (09:22 +0000)]
optional polygon collisions, not ready for practical use yet, also support for brush collisions
not terribly optimized (fast enough though)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2771 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded #include "portals.h"
havoc [Thu, 20 Feb 2003 09:20:36 +0000 (09:20 +0000)]
added #include "portals.h"

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2770 d7cf8633-e32d-0410-b094-e92efae38249

17 years agosome minor cleanup of PartialIPAddress (and some comments about how stupid it is...
havoc [Thu, 20 Feb 2003 09:17:42 +0000 (09:17 +0000)]
some minor cleanup of PartialIPAddress (and some comments about how stupid it is) and a comment about hostname coming from network address being stupid, and some whitespace

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2769 d7cf8633-e32d-0410-b094-e92efae38249

17 years agonow counts (very approximate) cost of builtin functions called by progs, profile...
havoc [Thu, 20 Feb 2003 09:15:46 +0000 (09:15 +0000)]
now counts (very approximate) cost of builtin functions called by progs, profile command reports this in addition to the instructions count, also profile now reports a whole list, not just the top 10

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2768 d7cf8633-e32d-0410-b094-e92efae38249

17 years agosimplified "connect local" a bit
havoc [Thu, 20 Feb 2003 09:13:31 +0000 (09:13 +0000)]
simplified "connect local" a bit

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2767 d7cf8633-e32d-0410-b094-e92efae38249

17 years agooptional portal based determination of lit surfaces (good speed gain, enough to make...
havoc [Thu, 20 Feb 2003 09:12:25 +0000 (09:12 +0000)]
optional portal based determination of lit surfaces (good speed gain, enough to make dpdm2 somewhat playable, on by default)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2766 d7cf8633-e32d-0410-b094-e92efae38249

17 years agono longer adopt colors from server updates (this means demos no longer change your...
havoc [Mon, 17 Feb 2003 02:59:50 +0000 (02:59 +0000)]
no longer adopt colors from server updates (this means demos no longer change your colors, and other such annoyances)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2751 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoimproved Com_HexDumpToConsole, it now prints properly (not with a data byte on the...
havoc [Mon, 17 Feb 2003 00:58:53 +0000 (00:58 +0000)]
improved Com_HexDumpToConsole, it now prints properly (not with a data byte on the left side followed by offset number, and other sillyness), and also prints a text listing beside the hex, it remains the same width as the old hex-only listing.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2750 d7cf8633-e32d-0410-b094-e92efae38249

17 years agooptimized some functions like SV_WallFriction and SV_FlyMove, no known behavioral...
havoc [Fri, 14 Feb 2003 01:27:10 +0000 (01:27 +0000)]
optimized some functions like SV_WallFriction and SV_FlyMove, no known behavioral changes (the code is a lot simpler however)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2741 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix some bugs with r_fullbright, no lights, and other such cases
havoc [Fri, 14 Feb 2003 01:22:29 +0000 (01:22 +0000)]
fix some bugs with r_fullbright, no lights, and other such cases

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2740 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded con_notify cvar, which controls how many console notify lines are displayed...
havoc [Fri, 14 Feb 2003 01:17:51 +0000 (01:17 +0000)]
added con_notify cvar, which controls how many console notify lines are displayed (default 4 like quake, max 32)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2739 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded VectorBlend and Matrix4x4_Blend
havoc [Fri, 14 Feb 2003 01:16:41 +0000 (01:16 +0000)]
added VectorBlend and Matrix4x4_Blend

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2738 d7cf8633-e32d-0410-b094-e92efae38249

17 years agodon't crash on NULL model in entity culling
havoc [Fri, 14 Feb 2003 01:15:06 +0000 (01:15 +0000)]
don't crash on NULL model in entity culling

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2737 d7cf8633-e32d-0410-b094-e92efae38249

17 years agorestructured LDFLAGS a bit to make sure libraries come last (especially -lm as the...
havoc [Wed, 12 Feb 2003 18:09:58 +0000 (18:09 +0000)]
restructured LDFLAGS a bit to make sure libraries come last (especially -lm as the very last), also moved debugging/profiling flags to be first

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2736 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoget rid of yet another entity_frame_t on the stack, this is the last one, hopefully...
havoc [Wed, 12 Feb 2003 00:11:07 +0000 (00:11 +0000)]
get rid of yet another entity_frame_t on the stack, this is the last one, hopefully the last stack overflow

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2735 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix two more stack overflows on win32 (in one case two 3.25mb entity_frame_t structs...
havoc [Tue, 11 Feb 2003 23:55:46 +0000 (23:55 +0000)]
fix two more stack overflows on win32 (in one case two 3.25mb entity_frame_t structs resided on the stack at once!)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2734 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoanother stack overflow fixed, this one more on the order of 300k+?
havoc [Tue, 11 Feb 2003 14:03:15 +0000 (14:03 +0000)]
another stack overflow fixed, this one more on the order of 300k+?

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2733 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofixed another stack overflow on win32, apparently a 64k packet buffer on the stack...
havoc [Tue, 11 Feb 2003 13:48:34 +0000 (13:48 +0000)]
fixed another stack overflow on win32, apparently a 64k packet buffer on the stack causes a stack overflow - yeesh win32 stack is pathetic

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2732 d7cf8633-e32d-0410-b094-e92efae38249

17 years agofix win32 stack overflows in CL_ParseServerInfo, it was choking on the sheer quantity...
havoc [Mon, 10 Feb 2003 23:55:33 +0000 (23:55 +0000)]
fix win32 stack overflows in CL_ParseServerInfo, it was choking on the sheer quantity of memory used by model and sound precache names

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2731 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoadded cl_noplayershadow cvar to allow disabling player shadow
havoc [Mon, 10 Feb 2003 21:04:09 +0000 (21:04 +0000)]
added cl_noplayershadow cvar to allow disabling player shadow

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2730 d7cf8633-e32d-0410-b094-e92efae38249

17 years agoalmost lost this very important part of the MAX_EDICTS commit
havoc [Mon, 10 Feb 2003 21:02:29 +0000 (21:02 +0000)]
almost lost this very important part of the MAX_EDICTS commit

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2729 d7cf8633-e32d-0410-b094-e92efae38249