]> git.rm.cloudns.org Git - xonotic/darkplaces.git/log
xonotic/darkplaces.git
3 years agoode: Add more #ifdefs to ensure ODE is fully disabled without -DUSEODE
Cloudwalk [Wed, 21 Jul 2021 22:14:01 +0000 (18:14 -0400)]
ode: Add more #ifdefs to ensure ODE is fully disabled without -DUSEODE

3 years agoedict: Move free and freetime into prvm_edict_t itself
Cloudwalk [Wed, 21 Jul 2021 19:57:40 +0000 (15:57 -0400)]
edict: Move free and freetime into prvm_edict_t itself

3 years agocommon: Use static_assert to prohibit unsafe functions more cleanly. Fixes compile...
Cloudwalk [Wed, 21 Jul 2021 15:49:53 +0000 (11:49 -0400)]
common: Use static_assert to prohibit unsafe functions more cleanly. Fixes compile warning with mingw builds

3 years agocommon: Define DP_STATIC_ASSERT which wraps static_assert
Cloudwalk [Tue, 20 Jul 2021 18:14:54 +0000 (14:14 -0400)]
common: Define DP_STATIC_ASSERT which wraps static_assert

3 years agozone: Pass __FILE__ and __LINE__ to Mem_strdup
Cloudwalk [Tue, 20 Jul 2021 18:10:02 +0000 (14:10 -0400)]
zone: Pass __FILE__ and __LINE__ to Mem_strdup

Made it a macro for _Mem_strdup which is what Mem_strdup was.
We have to call _Mem_Alloc directly to pass __FILE__ and __LINE__
to that function.

3 years agozone: Add Z_ counterparts for Realloc and strdup
Cloudwalk [Tue, 20 Jul 2021 18:05:36 +0000 (14:05 -0400)]
zone: Add Z_ counterparts for Realloc and strdup

3 years agozone: Do a straight malloc on non-Windows
Cloudwalk [Tue, 20 Jul 2021 18:03:39 +0000 (14:03 -0400)]
zone: Do a straight malloc on non-Windows

3 years agoqtypes: Define shorthand typenames for stdint types (i32, u32, etc). Remove the vec5...
Cloudwalk [Sun, 18 Jul 2021 03:36:55 +0000 (23:36 -0400)]
qtypes: Define shorthand typenames for stdint types (i32, u32, etc). Remove the vec5+ types as we have no use for those yet

3 years agocmd: Use a bitshift and subtract to calculate CF_MAXFLAGSVAL
Cloudwalk [Sun, 18 Jul 2021 03:34:20 +0000 (23:34 -0400)]
cmd: Use a bitshift and subtract to calculate CF_MAXFLAGSVAL

3 years agocom_list: Fix spacing. No code changes
Cloudwalk [Wed, 14 Jul 2021 15:08:26 +0000 (11:08 -0400)]
com_list: Fix spacing. No code changes

3 years agoFix file paths.
Rudolf Polzer [Thu, 8 Jul 2021 13:47:53 +0000 (06:47 -0700)]
Fix file paths.

3 years agoAlso actually include the .enc file for the key.
Rudolf Polzer [Thu, 8 Jul 2021 13:31:42 +0000 (06:31 -0700)]
Also actually include the .enc file for the key.

3 years agoNow with new Travis secret key.
Rudolf Polzer [Thu, 8 Jul 2021 12:48:56 +0000 (05:48 -0700)]
Now with new Travis secret key.

This breaks building on srv03 - was impossible to retain anyway due to travis-ci.com migration.

3 years agoRename host_t -> host_static_t.
Rudolf Polzer [Thu, 8 Jul 2021 12:09:01 +0000 (05:09 -0700)]
Rename host_t -> host_static_t.

Fixes build on OS X, as host_t is already a typedef for mach_port_t.

3 years agoTemporarily upload DarkPlaces autobuilds to both Xonotic build servers.
Rudolf Polzer [Thu, 8 Jul 2021 11:35:32 +0000 (04:35 -0700)]
Temporarily upload DarkPlaces autobuilds to both Xonotic build servers.

We are migrating from srv03 to srv04 and moving components one by one.

3 years agocvar: Rename Cvar_RegisterAlias to Cvar_RegisterVirtual
Cloudwalk [Mon, 5 Jul 2021 17:22:36 +0000 (13:22 -0400)]
cvar: Rename Cvar_RegisterAlias to Cvar_RegisterVirtual

They're now called "virtual cvars" to avoid confusion with actual
aliases. And it's just a better name for them.

3 years agoRemove redundant ampersand breaking ContainerOf and List_For_Each_Entry. Make all...
Cloudwalk [Sat, 3 Jul 2021 16:46:00 +0000 (12:46 -0400)]
Remove redundant ampersand breaking ContainerOf and List_For_Each_Entry. Make all current loops use List_For_Each_Entry instead

3 years agoAdd support for the .dpk package format used by Unvanquished Mario/dpk_support
Mario [Fri, 18 Jun 2021 15:20:49 +0000 (01:20 +1000)]
Add support for the .dpk package format used by Unvanquished

3 years agocom_list.h: Fix copy/paste oversight where List_For_Each_Entry went backwards like...
Cloudwalk [Tue, 8 Jun 2021 12:18:36 +0000 (08:18 -0400)]
com_list.h: Fix copy/paste oversight where List_For_Each_Entry went backwards like its Prev counterpart

3 years agoAdd .md extension to README so it actually parses the markdown
Cloudwalk [Sun, 30 May 2021 15:42:04 +0000 (11:42 -0400)]
Add .md extension to README so it actually parses the markdown

3 years agoAdd a proper README with build instructions and links to the available chats. To...
Cloudwalk [Sun, 30 May 2021 15:17:41 +0000 (11:17 -0400)]
Add a proper README with build instructions and links to the available chats. To be continued.

3 years agocvar: Don't memset cvar->aliases before it's even allocated
Cloudwalk [Sat, 29 May 2021 18:13:00 +0000 (14:13 -0400)]
cvar: Don't memset cvar->aliases before it's even allocated

3 years agocvar, prvm_cmds: Remove redundant Cmd_Exists checks
Cloudwalk [Tue, 25 May 2021 23:21:59 +0000 (19:21 -0400)]
cvar, prvm_cmds: Remove redundant Cmd_Exists checks

3 years agocvar: Rename aliasindex to aliases_size and only use it for size of the aliases array...
Cloudwalk [Tue, 25 May 2021 23:16:07 +0000 (19:16 -0400)]
cvar: Rename aliasindex to aliases_size and only use it for size of the aliases array. Simplify iterating over cvar aliases.

3 years agocvar: Remove unused ignore_callback variable
Cloudwalk [Tue, 25 May 2021 21:19:58 +0000 (17:19 -0400)]
cvar: Remove unused ignore_callback variable

3 years agoAdd/update license headers across various files
Cloudwalk [Tue, 25 May 2021 20:55:20 +0000 (16:55 -0400)]
Add/update license headers across various files

3 years agocurves.c and .h: Remove whitespace at the top of both files
Cloudwalk [Tue, 25 May 2021 20:15:41 +0000 (16:15 -0400)]
curves.c and .h: Remove whitespace at the top of both files

3 years agovpk: Include stdint.h only
Cloudwalk [Tue, 25 May 2021 20:15:04 +0000 (16:15 -0400)]
vpk: Include stdint.h only

3 years agoCREDITS: Add name
Cloudwalk [Tue, 25 May 2021 20:13:41 +0000 (16:13 -0400)]
CREDITS: Add name

3 years agoMerge intoverflow.h into qdefs.h
Cloudwalk [Tue, 25 May 2021 20:13:24 +0000 (16:13 -0400)]
Merge intoverflow.h into qdefs.h

3 years agocmd: Add comments to better explain the overly complicated cbuf system, to aid later...
Cloudwalk [Tue, 25 May 2021 03:21:50 +0000 (23:21 -0400)]
cmd: Add comments to better explain the overly complicated cbuf system, to aid later rewriting

3 years agoAdd the Visual Studio .vs folder to gitignore.
Ashley 'LadyHavoc' Hale [Mon, 24 May 2021 01:26:10 +0000 (18:26 -0700)]
Add the Visual Studio .vs folder to gitignore.

3 years agoAdd CREDITS.md. To be continued... (contact information, who did what, etc)
cloudwalk [Sun, 16 May 2021 18:23:53 +0000 (18:23 +0000)]
Add CREDITS.md. To be continued... (contact information, who did what, etc)

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

3 years agoclient: Add SV_Shutdown hook and remove all direct calls in non-server code. Lock...
cloudwalk [Fri, 14 May 2021 16:24:24 +0000 (16:24 +0000)]
client: Add SV_Shutdown hook and remove all direct calls in non-server code. Lock the server mutex within SV_Shutdown itself. Call the hook directly from CL_Disconnect.

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

3 years agosv_main: Remove redundant client variable set from server code
cloudwalk [Fri, 14 May 2021 16:23:59 +0000 (16:23 +0000)]
sv_main: Remove redundant client variable set from server code

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

3 years agocl_parse: Remove redundant disconnect print
cloudwalk [Fri, 14 May 2021 16:23:35 +0000 (16:23 +0000)]
cl_parse: Remove redundant disconnect print

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

3 years agocl_parse: break on qw_svc_disconnect instead of return, consistent with regular svc_d...
cloudwalk [Fri, 14 May 2021 16:23:09 +0000 (16:23 +0000)]
cl_parse: break on qw_svc_disconnect instead of return, consistent with regular svc_disconnect

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

3 years agocl_demo: Move demo playback functionality to a separate function
cloudwalk [Fri, 14 May 2021 16:22:44 +0000 (16:22 +0000)]
cl_demo: Move demo playback functionality to a separate function

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

3 years agosv_save: Remove SV_CanSave hook and just call it directly. Move it to sv_save.c
cloudwalk [Fri, 14 May 2021 16:22:19 +0000 (16:22 +0000)]
sv_save: Remove SV_CanSave hook and just call it directly. Move it to sv_save.c

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

3 years agohost: Clean it up. Give some functions new names and new homes.
cloudwalk [Fri, 14 May 2021 16:22:11 +0000 (16:22 +0000)]
host: Clean it up. Give some functions new names and new homes.

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

3 years agoUpdate a few cl_* cvar descriptions
cloudwalk [Mon, 10 May 2021 02:47:42 +0000 (02:47 +0000)]
Update a few cl_* cvar descriptions

(cherry picked from commit 90ac504e2287c6750d931ea1d741cca178759667)

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

3 years agoFix a possible divide by zero in Mod_PSKMODEL_Load.
havoc [Sun, 9 May 2021 20:21:47 +0000 (20:21 +0000)]
Fix a possible divide by zero in Mod_PSKMODEL_Load.

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

3 years agoFix some warnings in MSVC++2019. Add SDL2-nuget package as a dependency of the MSVC...
havoc [Sun, 9 May 2021 20:16:20 +0000 (20:16 +0000)]
Fix some warnings in MSVC++2019.  Add SDL2-nuget package as a dependency of the MSVC++2019 project.

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

3 years agoOptimize FS_FileExtension
cloudwalk [Sun, 9 May 2021 04:45:06 +0000 (04:45 +0000)]
Optimize FS_FileExtension

(cherry picked from commit f7c1ec5c94e7356ac7ab9061c3c1f6fac6010336)

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

3 years agoRevert "gl_draw, model_shared: Refactor vertex adding. Add faster codepath that skips...
cloudwalk [Sun, 9 May 2021 04:45:05 +0000 (04:45 +0000)]
Revert "gl_draw, model_shared: Refactor vertex adding. Add faster codepath that skips hash function for drawing lines. Modest improvement in netgraph performance."

This reverts commit 5ad6c0e8577478422c10d7ae79fb61b88ac5ae85.

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

3 years agocmd: Merge cmd_client and cmd_server into cmd_local. Third time's a charm. 97/merge
cloudwalk [Tue, 20 Apr 2021 18:39:54 +0000 (18:39 +0000)]
cmd: Merge cmd_client and cmd_server into cmd_local. Third time's a charm.

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

3 years agomenu: Partially implement MQC built-in #352 (registercommand). Not enabled yet due...
cloudwalk [Tue, 20 Apr 2021 13:24:11 +0000 (13:24 +0000)]
menu: Partially implement MQC built-in #352 (registercommand). Not enabled yet due to design considerations.

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

3 years agoprvm: Deduplicate console command handler
cloudwalk [Tue, 20 Apr 2021 13:24:10 +0000 (13:24 +0000)]
prvm: Deduplicate console command handler

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

3 years agocmd: Use per-interpreter hooks to handle commands, to replace an ugly hack
cloudwalk [Tue, 20 Apr 2021 13:24:09 +0000 (13:24 +0000)]
cmd: Use per-interpreter hooks to handle commands, to replace an ugly hack

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

3 years agosys: Don't bother doing Host_Shutdown on Sys_Error
cloudwalk [Sat, 17 Apr 2021 17:12:48 +0000 (17:12 +0000)]
sys: Don't bother doing Host_Shutdown on Sys_Error

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

3 years agocl_main: Slight refactor
cloudwalk [Tue, 13 Apr 2021 16:31:44 +0000 (16:31 +0000)]
cl_main: Slight refactor

Authored by bones_was_here and Cloudwalk
https://gitlab.com/xonotic/darkplaces/-/merge_requests/116

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

3 years agocom_list: Move all functions to the header and inline them. Include where needed
cloudwalk [Tue, 13 Apr 2021 16:31:41 +0000 (16:31 +0000)]
com_list: Move all functions to the header and inline them. Include where needed

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

3 years agohost: Move Host_GetConsoleCommands and rename it for consistency. Add comment
cloudwalk [Tue, 13 Apr 2021 16:31:41 +0000 (16:31 +0000)]
host: Move Host_GetConsoleCommands and rename it for consistency. Add comment

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

3 years agocurl: Rename Curl_Run to Curl_Frame. Fix typo in comment
cloudwalk [Tue, 13 Apr 2021 16:31:40 +0000 (16:31 +0000)]
curl: Rename Curl_Run to Curl_Frame. Fix typo in comment

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

3 years agohost, netconn: Use cvar callbacks on (cl_)port to reduce branching in main loop
cloudwalk [Tue, 13 Apr 2021 16:31:40 +0000 (16:31 +0000)]
host, netconn: Use cvar callbacks on (cl_)port to reduce branching in main loop

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

3 years agohost: Refactor Host_Frame; simplify control flow.
cloudwalk [Tue, 13 Apr 2021 16:31:39 +0000 (16:31 +0000)]
host: Refactor Host_Frame; simplify control flow.

Authored by bones_was_here and Cloudwalk
https://gitlab.com/xonotic/darkplaces/-/merge_requests/116

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

3 years agoFix a use of FALSE in some JPEG code.
divverent [Mon, 12 Apr 2021 13:00:54 +0000 (13:00 +0000)]
Fix a use of FALSE in some JPEG code.

Should fix build for OS X.

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

3 years agoimage: Sanitize paths on *all* images rather than images loaded from Q3 shaders
cloudwalk [Sun, 11 Apr 2021 19:23:23 +0000 (19:23 +0000)]
image: Sanitize paths on *all* images rather than images loaded from Q3 shaders

Implemented FS_SanitizePath. Perhaps expand on this? Not really a clean
way to do it that I can think of, but I can't see the harm in doing this
for all filepaths.

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

3 years agohost: Make delta non-static in Host_Sleep
cloudwalk [Sun, 11 Apr 2021 16:46:15 +0000 (16:46 +0000)]
host: Make delta non-static in Host_Sleep

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

3 years agocl_parse: Implement 7th mode for cl_nettimesyncboundmode; jitter compensated dynamic...
cloudwalk [Sun, 11 Apr 2021 16:46:15 +0000 (16:46 +0000)]
cl_parse: Implement 7th mode for cl_nettimesyncboundmode; jitter compensated dynamic adjustment rate

This mode aims to prevent network jitter or other disturbances from
significantly affecting the client's timekeeping,
by correcting gradually (max 10% of mean error per tic).

The rolling harmonic mean gives large time error outliers low significance.

Correction rate is dynamic, determined by mean error size.
Time is correct within a few tics of connect/map start despite no hard bounding.

The adjustment approach is from mode 5 and can achieve
microsecond accuracy if client frametime is a multiple of server frametime.

Prevents 0ms move frame times with uncapped fps.

Smoothest mode esp for vsynced clients on servers with aggressive inputtimeout.

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agocl_input: Don't floor cl.cmd.frametime to the nearest millisecond in CL_SendMove
cloudwalk [Sun, 11 Apr 2021 16:46:14 +0000 (16:46 +0000)]
cl_input: Don't floor cl.cmd.frametime to the nearest millisecond in CL_SendMove

Removes the requirement of integer millisecond client and server frame times (eg 125fps) to get the smoothest asynchronous movement.

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agoclient: Improve input packet timing (netfps)
cloudwalk [Sun, 11 Apr 2021 16:46:13 +0000 (16:46 +0000)]
client: Improve input packet timing (netfps)

Increase min netfps to 10 (matches min ticrate).

Skip packettime calculations for 0ms packets.

Cap netfps when ticrate stat is available:
soft limit 2x, hard limit < 4x server frame rate.

Set packettime to (largest multiple of realframetime) <= packettime.
Prevents packet rates lower than cl_netfps or server frame rate,
eg: cl_netfps 60 and cl_maxfps 250 would otherwise send only 50 netfps.

Allow for float error when deciding if it's time to send yet.

Accumulate realframetime instead of storing host.realtime.
Fixes low packet rates in some configurations,
eg: with cl_maxfps 125 and cl_netfps 125 it would not send every frame,
as host.realtime - lastpackettime was often well below (or above) 8ms.

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agocl_parse: Clarify a few cvar descriptions
cloudwalk [Sun, 11 Apr 2021 16:46:13 +0000 (16:46 +0000)]
cl_parse: Clarify a few cvar descriptions

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agocl_parse: Further optimize CL_NetworkTimeReceived
cloudwalk [Sun, 11 Apr 2021 16:46:12 +0000 (16:46 +0000)]
cl_parse: Further optimize CL_NetworkTimeReceived

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agocl_parse: Refactor cl_nettimesyncboundmode check into a switch block
cloudwalk [Sun, 11 Apr 2021 16:46:12 +0000 (16:46 +0000)]
cl_parse: Refactor cl_nettimesyncboundmode check into a switch block

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/112

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

3 years agosv_main: Let the other players know if a connected player has timed out
cloudwalk [Sun, 11 Apr 2021 16:46:11 +0000 (16:46 +0000)]
sv_main: Let the other players know if a connected player has timed out

Authored by bones_was_here
https://gitlab.com/xonotic/darkplaces/-/merge_requests/114

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

3 years agorender: Refactor R_CullBox to simplify it.
cloudwalk [Sun, 11 Apr 2021 15:18:38 +0000 (15:18 +0000)]
render: Refactor R_CullBox to simplify it.

Use bitwise comparisons instead of the previous switch. Skip the
nearclip plane on the view frustum.

From divVerent. Cleaned up further by Cloudwalk.

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

3 years agoMake trace entity culling optional for spectators with sv_cullentities_trace_spectators
bones_was_here [Wed, 7 Apr 2021 12:41:03 +0000 (22:41 +1000)]
Make trace entity culling optional for spectators with sv_cullentities_trace_spectators

Can save a lot of CPU time on Xonotic servers.

3 years agosv_user: Check if frametime is positive
cloudwalk [Tue, 30 Mar 2021 16:19:13 +0000 (16:19 +0000)]
sv_user: Check if frametime is positive

From bones_was_here

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

3 years agosv_user: Don't bound moveframetime to a multiple of frametime when frametime is...
cloudwalk [Tue, 30 Mar 2021 16:11:38 +0000 (16:11 +0000)]
sv_user:  Don't bound moveframetime to a multiple of frametime when frametime is zero

Fixes https://gitlab.com/xonotic/darkplaces/-/issues/347

From bones_was_here

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

3 years agocl_screen: Finish frames even if we're minimized, if recording video
cloudwalk [Mon, 29 Mar 2021 21:17:42 +0000 (21:17 +0000)]
cl_screen: Finish frames even if we're minimized, if recording video

From malice

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

3 years agoprotocol: Make receivetime a float since it's derived from sv.time casted to float...
cloudwalk [Mon, 29 Mar 2021 20:55:14 +0000 (20:55 +0000)]
protocol: Make receivetime a float since it's derived from sv.time casted to float anyway

From bones_was_here

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

3 years agosv_user: Use sv.time directly, to limit reported time to current time
cloudwalk [Mon, 29 Mar 2021 20:55:13 +0000 (20:55 +0000)]
sv_user: Use sv.time directly, to limit reported time to current time

From bones_was_here

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

3 years agoRevert "Tell clients to reconnect before loading the next map. Should fix lag/stutter"
cloudwalk [Mon, 29 Mar 2021 20:55:13 +0000 (20:55 +0000)]
Revert "Tell clients to reconnect before loading the next map. Should fix lag/stutter"

This reverts commit b30c46fb9423afb892b639de58ade85d5dbed03e.

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

3 years agoserver: Remove unused/broken ping smoothing feature
cloudwalk [Mon, 29 Mar 2021 20:55:12 +0000 (20:55 +0000)]
server: Remove unused/broken ping smoothing feature

Removes unused ping smoothing feature (didn't actually compile so safe
to say nobody is using it). It could cause problems for QC mods that use
ping for antilag purposes, and QC can easily average pings if desired.

From bones_was_here

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

3 years agosv_user: Don't detect heavy movement loss right after a map change
cloudwalk [Mon, 29 Mar 2021 20:55:12 +0000 (20:55 +0000)]
sv_user: Don't detect heavy movement loss right after a map change

From bones_was_here

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

3 years agoserver: Limit moveframetime to a multiple of sv.frametime
cloudwalk [Mon, 29 Mar 2021 20:55:11 +0000 (20:55 +0000)]
server: Limit moveframetime to a multiple of sv.frametime

Matches clmovement_inputtimeout decrementing behaviour and prevents player speed bugs with certain ticrate/inputtimeout/netfps combos.

Also use maximum of 0.1 for the timeout, not just the moveframetime limit.

From bones_was_here

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

3 years agosv_user: Remove redundant return/unreachable code
cloudwalk [Mon, 29 Mar 2021 20:55:11 +0000 (20:55 +0000)]
sv_user: Remove redundant return/unreachable code

moveframetime is already checked a few lines above and already returns
if it's less than 0.0005, making the redundant return unreachable.

From bones_was_here

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

3 years agocmd: Dynamically allocate the command interpreters
cloudwalk [Tue, 9 Mar 2021 00:12:25 +0000 (00:12 +0000)]
cmd: Dynamically allocate the command interpreters

Will help with threading and other stuff later.

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

3 years agosys: Simplify Sys_LoadLibrary. Implement Sys_LoadDependency and move bloat to it
cloudwalk [Sat, 6 Mar 2021 12:03:22 +0000 (12:03 +0000)]
sys: Simplify Sys_LoadLibrary. Implement Sys_LoadDependency and move bloat to it

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

3 years agosys: Rename Sys_UnloadLibrary to Sys_FreeLibrary for consistency
cloudwalk [Sat, 6 Mar 2021 12:03:21 +0000 (12:03 +0000)]
sys: Rename Sys_UnloadLibrary to Sys_FreeLibrary for consistency

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

3 years agocl_particles: Fix rain splash particles falling through map by adding very slight...
cloudwalk [Thu, 4 Feb 2021 14:16:52 +0000 (14:16 +0000)]
cl_particles: Fix rain splash particles falling through map by adding very slight bounce. A pbounce value of 0 disabled collisions. Minor framerate impact.

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

3 years agosys_win: Remove pointless cls.state sets since we're calling Sys_Error immediately...
cloudwalk [Thu, 4 Feb 2021 13:48:10 +0000 (13:48 +0000)]
sys_win: Remove pointless cls.state sets since we're calling Sys_Error immediately after

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

3 years agokeys: Fix intermittent buffer overflow when pasting text. From malice
cloudwalk [Sun, 24 Jan 2021 02:23:33 +0000 (02:23 +0000)]
keys: Fix intermittent buffer overflow when pasting text. From malice

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

3 years agomodel_shared: Avoid Mod_MakeSortedSurfaces if dedicated. Fixes crash.
cloudwalk [Wed, 6 Jan 2021 17:57:00 +0000 (17:57 +0000)]
model_shared: Avoid Mod_MakeSortedSurfaces if dedicated. Fixes crash.

R_FrameData_Alloc isn't available in dedicated builds and sorting
surfaces is not really necessary without a renderer.

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

3 years agomodel_shared: Clarify comments
cloudwalk [Wed, 6 Jan 2021 17:56:59 +0000 (17:56 +0000)]
model_shared: Clarify comments

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

3 years agomodel_brush: Rename some Q1BSP functions that are actually generic BSP functions
cloudwalk [Wed, 6 Jan 2021 17:56:59 +0000 (17:56 +0000)]
model_brush: Rename some Q1BSP functions that are actually generic BSP functions

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

3 years agomodel_brush: More work on VBSP. Still crashes.
cloudwalk [Fri, 1 Jan 2021 15:09:24 +0000 (15:09 +0000)]
model_brush: More work on VBSP. Still crashes.

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

3 years agomodel_brush: Very early implementation of VBSP loader. It crashes
cloudwalk [Fri, 1 Jan 2021 07:53:23 +0000 (07:53 +0000)]
model_brush: Very early implementation of VBSP loader. It crashes

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

3 years agoconsole: Readd code accidentally removed
cloudwalk [Thu, 31 Dec 2020 19:31:37 +0000 (19:31 +0000)]
console: Readd code accidentally removed

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

3 years agomodel_vbsp: Move magic header define to its appropriate place
cloudwalk [Thu, 31 Dec 2020 19:31:36 +0000 (19:31 +0000)]
model_vbsp: Move magic header define to its appropriate place

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

3 years agomodel_shared: Fix gcc warning
cloudwalk [Thu, 31 Dec 2020 19:31:35 +0000 (19:31 +0000)]
model_shared: Fix gcc warning

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

3 years agoAdd missing include guards. Formatting improvement
cloudwalk [Thu, 31 Dec 2020 19:31:35 +0000 (19:31 +0000)]
Add missing include guards. Formatting improvement

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

3 years agofs: Create header for Source engine VPK format
cloudwalk [Thu, 31 Dec 2020 19:06:38 +0000 (19:06 +0000)]
fs: Create header for Source engine VPK format

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

3 years agomodel: Create header for Half-Life MDL format
cloudwalk [Thu, 31 Dec 2020 19:06:37 +0000 (19:06 +0000)]
model: Create header for Half-Life MDL format

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

3 years agomodel: Recognize Valve BSP format. Add file format headers.
cloudwalk [Thu, 31 Dec 2020 19:06:37 +0000 (19:06 +0000)]
model: Recognize Valve BSP format. Add file format headers.

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

3 years agoFix crash in q3bsp loading on submodels where it was adding the submodelsurfaces_star...
havoc [Tue, 29 Dec 2020 05:04:43 +0000 (05:04 +0000)]
Fix crash in q3bsp loading on submodels where it was adding the submodelsurfaces_start and shouldn't (reported by Cloudwalk - thanks).

Fix missing submodels in q3bsp loading where it was allocating a separate modelsurfaces_sorted for each submodel which was probably coming out uninitialized.

Simplified Mod_MakeSortedSurfaces a little by sorting each submodel separately - no need to worry about sorting by submodel this way, they're going to stay in the same ranges.

Refactored away the many duplicates of the mod->DrawSky and mod->DrawAddWaterPlanes setting code into Mod_SetDrawSkyAndWater function which is called after loader (and in submodel creation), this also means it checks for NULL texture pointer consistently whereas that varied a bit in the past by loader.

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

4 years agocom_game: Add GAME_BATTLEMETAL
cloudwalk [Wed, 23 Dec 2020 18:27:48 +0000 (18:27 +0000)]
com_game: Add GAME_BATTLEMETAL

https://store.steampowered.com/app/1447830/battleMETAL/

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

4 years agoshader_glsl: Don't use the r_colorfringe codepath if not enabled (terencehill)
cloudwalk [Mon, 21 Dec 2020 16:36:54 +0000 (16:36 +0000)]
shader_glsl: Don't use the r_colorfringe codepath if not enabled (terencehill)

Fixes scr_screenshot_alpha

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

4 years agosv_ccmds: Comment fix
cloudwalk [Mon, 21 Dec 2020 16:36:53 +0000 (16:36 +0000)]
sv_ccmds: Comment fix

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