Commit graph

2773 commits

Author SHA1 Message Date
BjossiAlfreds
240232cdde Prevent dead bodies from obstructing elevators and from falling through BSP geometry 2022-09-30 14:16:09 +00:00
BjossiAlfreds
37db07410f Fix coop power cube related bugs 2022-09-24 14:31:21 +00:00
BjossiAlfreds
9891f3f5af Fix items already in water at level start playing splash sound 2022-09-24 12:11:16 +00:00
BjossiAlfreds
153587f0cb Prevent crash or memory corruption when flood_msgs is too low or too high 2022-09-24 01:23:39 +00:00
Jaime Moreira
654c145e29 Quicksaves can be deleted from menu
Also, avoids asking for deletion in "<empty>" savegames
2022-09-23 17:57:01 -03:00
David Carlier
9d38e5c347 Sys_CpuPause uses the new SDL_CPUPauseInstruction macro if available. 2022-09-20 19:06:03 +01:00
Jaime Moreira
9de55c603d Classic cvar 'in_initjoy' resurrected
Added myself to credits
2022-09-19 11:36:23 -03:00
Jaime Moreira
da31490684 "Invert gyro" spincontrols 2022-09-19 11:27:47 -03:00
Jaime Moreira
54eb9e441d Sliders can ignore cvar value's sign, if needed
Gyro sensitivity sliders need this, since their values can be negative
to invert pitch and yaw.
2022-09-19 11:24:06 -03:00
Yamagi
e29d37956a
Merge pull request #868 from devnexen/cmake_build_fix2
Cmake build fix2
2022-09-19 11:11:53 +02:00
Denis Pauk
61f4540617 Fix documentation for model preview.
All default players models have 84-94 frames for salute.
So value will be same for `cyborg`/`female`/`male`.
2022-09-18 12:39:50 +03:00
Denis Pauk
3b583a7143 Bumb game version value
New code has exported monster footsteps sounds function.

Fixes typos.
2022-09-18 12:39:50 +03:00
Denis Pauk
4946400260 sound: reverb logic cleanup 2022-09-18 12:39:50 +03:00
Denis Pauk
93c6c76b0e sound: cleanup reverb code 2022-09-18 12:39:50 +03:00
Denis Pauk
983f1db185 audio: Update autopick reverb magic 2022-09-18 12:39:50 +03:00
Denis Pauk
eb640a0033 sound: Little bit simplify reverb 2022-09-18 12:39:50 +03:00
SkacikPL
f0d6db5d4a Improved reverb behavior and presets
Adjusted presets and their ranges. Occluded sounds no longer have reverb.

Cherrypick of 66927bff72
2022-09-18 12:39:50 +03:00
SkacikPL
93812df488 Added reverb sound effect
Enabled by default, can be disabled via s_reverb 0. Also by default
picks preset automatically out of 7 presets based on surrounding
size, this function can be disabled via s_reverb_preset_autopick 0.
Presets can be set manually via s_reverb_preset (0-113).

Cherrypick of ac7be51e94
2022-09-18 12:39:50 +03:00
SkacikPL
66f1bc9a33 Add simple sound occusion based on YQ2 AL EFX code
Can be disabled via s_occlusion 0, strength is modified
via s_occlusion_strength (higher values are actually less occlusion).

Cherrypick of b557494e14
2022-09-18 12:39:50 +03:00
Denis Pauk
9820aa4cb1 game: sync functions definitions
Make local variables static
2022-09-18 12:39:50 +03:00
Denis Pauk
a1d053bca1 game: replace rand with randk in footsteps 2022-09-18 12:39:50 +03:00
Denis Pauk
e1164fc839 game: Fix makron walk
Walk/Run is fully same for makron, looks like copy/paste issue.
2022-09-18 12:39:50 +03:00
Denis Pauk
90b14fca24 game: make mframe static and export footstep functions 2022-09-18 12:39:50 +03:00
SkacikPL
cfb86acc81 game: Implement monster footsteps.
Better tracking of enemies complementing the audio changes.

Cherrypick of 74edb966a2
2022-09-18 12:39:50 +03:00
Yamagi
5a3163a7e4 Merge remote-tracking branch 'ui/ui' 2022-09-18 09:43:49 +02:00
Ted Thompson
7e7cda4487 Added brackets around mod names in menu 2022-09-17 17:30:17 +02:00
Yamagi
1053b5dfb1
Merge pull request #871 from 0lvin/new_commands
Add new cheats spawn commands
2022-09-17 17:17:02 +02:00
Yamagi
e705b48a8e
Merge pull request #883 from protocultor/thumbsticks_fs
Improved controller thumbsticks precision + Flick Stick
2022-09-17 16:13:57 +02:00
David Carlier
2301ce0f78 Fix cmake's C11 build and removing C99 flag then. 2022-09-16 21:27:32 +01:00
apartfromtime
f63b5914f6 Include guard pointers
Spincontrol checks for null itemnames, which could cause undefined behaviour (menu disappears or crashes) in some instances.
2022-09-10 09:05:36 +10:00
Denis Pauk
1dfeddc40f game: fix memory leak with spawn entities cheat 2022-09-04 23:40:55 +03:00
Denis Pauk
5cddd2110c client: add multiplayer model preview animation 2022-09-04 23:40:55 +03:00
Denis Pauk
cf110b5ea0 game: Add spawn on start point
It could be used for spawn weapon or opponnent for coop at spawn point.
2022-09-04 23:40:55 +03:00
Denis Pauk
2a8a2f390a game: add spawn entity by coordinates 2022-09-04 23:40:55 +03:00
Yamagi
021d6480d6
Merge pull request #873 from skullernet/pusher-delta-yaw
Remove broken pusher delta yaw manipulation
2022-09-04 18:55:46 +02:00
Yamagi
ac9c09694a Don't try to draw particles if there aren't any.
This fixes a VLA getting allocated with length 0 which is undefined
behavior. Additionally it may yield a small performance gain in some
situations.
2022-09-04 18:45:07 +02:00
Yamagi
a4edbb979f
Merge pull request #866 from apartfromtime/ui
Make skin icon bitmap part of the player setup menu
2022-09-04 18:37:46 +02:00
Yamagi
a44de1596d Fix spin controls getting applied multiple times.
When a spin control is at min or max value, pressing the arrow key to
switch to the next nonexiting value executes the callback function. That
is confusing.

Example: 'freelook' is set to 'no'. The user presses left arrow,
switching to the nonexiting value before no. The code handles the
case and resets the current value drom -1 to 0. Nevertheless the
callback is executed and switches 'freelook' from no to yes...

Fix that by not executing the callback when we're at min or max value.

Closes #884.
2022-09-04 18:18:58 +02:00
Jaime Moreira
2ee5d7b479 IN_MapRange slight optimization 2022-08-25 21:07:53 -04:00
Jaime Moreira
c6dd713c89 Smooth rotation for Flick Stick
Added cvar to change maximum rotation angle that will be smoothed
2022-08-24 19:37:25 -04:00
Jaime Moreira
748909fd96 "Flick Stick" controller layout implementation
With southpaw version added to "sticks layout" menu
Cvar for length of stick to be considered a flick or rotation
Lacks rotation smoothing
2022-08-24 19:02:21 -04:00
Jaime Moreira
0417bc1023 Sloped axial deadzone added
2 cvars to change it, 1 per stick
Provides the "snap-to-axis" feeling of the previous axial deadzone
2022-08-24 17:48:33 -04:00
Jaime Moreira
f3fcf3fc24 Joystick handling refactored for precision
Changed 6 cvars for stick layout to 1; includes menu option
Axial deadzone replaced with radial one, 6 cvars to 2
Expo different for each thumbstick (1 cvar to 2); sliders included
Expo applied to full joystick vector magnitude, instead of per axis
Deleted "joystick_up" ("updown" function) and its sensitivity
2022-08-24 12:30:39 -04:00
Jaime Moreira
301a2ce735 Disable gyro when game is paused
Changed text on controller menu for lower resolutions
Appropiate data type for updates_countdown
2022-08-23 18:36:33 -04:00
apartfromtime
45f4e1860c Check for null and free correct number of directories
Potential errors.
2022-08-21 11:31:09 +10:00
apartfromtime
4c7ab467f8 Dangling pointer on free
Won't need the guard pointer.
2022-08-19 16:05:21 +10:00
apartfromtime
64ac8c3183 Zero list elements
For in check for "NULL" cases, if free succeeds you probably want to
clear the pointer bits.
2022-08-19 15:26:53 +10:00
apartfromtime
73427b77a2 Convert model info from AOS to SOA
Converted model info from AOS to SOA
All strings allocated dynamically at run-time
New command "playermodels" prints valid models to console
Fixes any bugs that may have existed in the directory search

The issue still exists of undefined behavior if a directory name for a
model exceeds the predefined limits.
2022-08-19 15:22:22 +10:00
Andrey Nazarov
fe15bf2335 Remove broken pusher delta yaw manipulation.
This didn't work correctly for multiple reasons:

1. `deltayaw` was wrongly initialized for the pusher itself, rather than
for pushed client.

2. `delta_angles[YAW]` is a short, adding plain `amove[YAW]` to it is
wrong.

To support yaw angle rotation properly, delta_angles must be
interpolated on the client. But this is hardly practical as it would
introduce other bugs. Thus, simply remove delta yaw manipulation code
altogether.

Fixes infamous Q2 bug when player standing on a blocked lift gets turned
into wrong direction.
2022-08-16 01:43:47 +03:00
apartfromtime
acea0c54d9 Remove player skin box bounds check introduced in #866
Failure produces black screen.
2022-08-13 10:09:05 +10:00
apartfromtime
e87f025d13 Merge branch 'master' into ui 2022-08-13 10:08:02 +10:00
Yamagi
98a4522b1b
Merge pull request #865 from protocultor/cycleweap_quick
Faster weapon switching with 'cycleweap'
2022-08-07 18:21:30 +02:00
apartfromtime
de051f248c Make skin icon bitmap part of the player setup menu
Adding menu bitmaps makes this possible.
Bounds check on skin box current value.
2022-08-06 13:20:21 +10:00
Jaime Moreira
7f689f649c Faster weapon switching with 'cycleweap'
Allows to skip elements on the weapon list by tapping the same bound key
2022-08-01 14:31:26 -04:00
Jaime Moreira
5f59b752c0 Scope fixed for some cvars
Old sliders required some of their associated cvars to be "extern" so
their current value could be read. That's no longer needed, so they are
"static" now.
2022-07-30 14:29:38 -04:00
Jaime Moreira
6c4866995b Enhanced sliders for menus
"menuslider_s" types, used to create sliders in menus, now are directly
associated to a cvar. That makes possible for them to get their
currently selected value from the cvar, and express their min and max
values in terms of the real values of the cvar.
The rhythm at how they change can be overridden with s->slidestep.
The new sliders also present visually their current value to the user,
making them more useful than before.
2022-07-30 14:23:33 -04:00
David Carlier
cfd8cd94e5 Hunk_Begin/Alloc attr malloc addition. 2022-07-23 14:05:30 +01:00
Yamagi
90eb2f394d
Merge pull request #862 from devnexen/glrenderer_drawparticles_sig
R_DrawParticles2 signature slight change fixing build warning.
2022-07-22 10:14:37 +02:00
Yamagi
2cb98b7a1d
Merge pull request #857 from protocultor/gyro_bluetooth
Gyro aiming through Bluetooth for PS4 & PS5 controllers
2022-07-22 09:53:00 +02:00
David Carlier
136222d4d7 R_DrawParticles2 signature slight change fixing build warning. 2022-07-20 22:54:42 +01:00
Yamagi
aaffcf81b0
Merge pull request #861 from devnexen/client_pingserverfix
client ping server fix unitialized field.
2022-07-17 12:24:35 +02:00
Yamagi
91fd76ca5d
Merge pull request #860 from apartfromtime/ui
UI code maintenance
2022-07-17 12:24:20 +02:00
David Carlier
024d065f80 client ping server fix unitialized field. 2022-07-16 19:44:30 +01:00
apartfromtime
affea5aef3 Remove menu number of slots property
Remove unused and dead code.
2022-07-15 12:51:01 +10:00
apartfromtime
c0bad27f43 Pre-calculate x, y offsets
Make code easier to read.
2022-07-15 12:47:41 +10:00
Jaime Moreira
0bb2bf0cea Increased sensitivity range for controllers on menu 2022-07-07 23:43:02 -04:00
Jaime Moreira
1fa432f695 Gyro aiming through Bluetooth for PS4 & PS5 controllers 2022-07-05 19:15:10 -04:00
Yamagi
95eabefec9
Merge pull request #856 from apartfromtime/ui
Iterate once through menu item list
2022-06-25 17:28:40 +02:00
apartfromtime
c03f4fd094 Iterate once through menu item list
Avoids any infinite loop cases.
2022-06-25 14:17:58 +10:00
David Carlier
a635721c50 client download, sets a sane connection timeout, the default being way to high. 2022-06-24 20:49:23 +01:00
Yamagi
c6f6a17176
Merge pull request #849 from protocultor/gyro_aiming
Gyro aiming
2022-06-17 13:07:25 +02:00
Jaime Moreira
35495fb6f2 Readability improved for gyro calibration & controller hotplug code
"init_delay" was renamed to "updates_countdown", since it's now a "general
purpose" countdown, having also to count the inputs left for gyro calibration,
besides controller initialization.
Reason for the countdown is now explicit, not having to depend if
"gyro_calibration" was true or not to select what was the purpose of the
countdown.
Explanation comment added for gyro initialization on Linux & Mac.
REMINDER: see if SDL2 will keep the difference of gyro readings between Windows
and Linux/Mac for the Switch controllers.
2022-06-14 16:16:47 -04:00
Yamagi
ca70f8e679
Merge pull request #851 from devnexen/download_limits
client download, adding two new cvar to have the ability to set
2022-06-13 08:08:52 +02:00
Daniel Gibson
86811a4c24 Fix fallback when window couldn't be created because renderer is unsupported
For example, on Windows with AMDs drivers, GLES3 isn't supported,
so CreateSDLWindow() will fail. We should just try the regular GL3
renderer then instead of exiting with Com_Error()

Also make (Windows') Sys_Error() print to stdout (in addition to stderr),
so errors end up in stdout.txt as well (like all other messages).
2022-06-11 17:57:29 +02:00
Yamagi
a1dddaede3
Merge pull request #846 from devnexen/vla_0_fix
GL1 renderer fix VLA with no size cases,
2022-06-11 16:40:48 +02:00
Yamagi
a8ae79c6ab Remove twi unsused declarations. 2022-06-11 16:40:15 +02:00
David CARLIER
a01309235b client download, adding two new cvar to have the ability to set
a threshold to abort the download if a certain transfer rate is too low.
Disabled by default.
2022-06-11 13:41:24 +01:00
Jaime Moreira
df399576a2 Gyro normalization value in Windows improved
SDL2 provides different gyro readings between Windows and Linux/Mac for
the Switch Pro Controller. To keep the natural sensitivity scale intact
(in-game turn = controller turn), the normalization factor is handled
differently by platform, at least for now.
Also, now giving info when there's no gyro sensor available/detected.
And green light for the DualShock 4, because why not :)
2022-06-10 22:31:24 -04:00
apartfromtime
353295d0c7 Infinite loop in bind menu fix
Bug introduced in #841.
Added QMF_INACTIVE.
QMF_INACTIVE menu items are skipped.
2022-06-11 09:17:49 +10:00
Jaime Moreira
077d861a57 Gyro aiming menu options
"Gyro mode", "axis to turn" and "sensitivity" grouped with calibration.
2022-06-07 09:49:47 -04:00
Jaime Moreira
f12b759feb Gyro aiming configuration cvars
Cvar to choose between "yaw" (0) or "roll" (1) axis of the controller
to turn (change your yaw) in-game.
Cvars to change pitch and yaw gyro sensitivities.
Updated cvar documentation with new section "Game Controller".
2022-06-07 09:34:45 -04:00
Jaime Moreira
d3da95cfc8 Gyro aiming implementation
SDL 2.0.16 and a controller with a gyroscope required to make it work.
Manual calibration of the gyro sensor is needed to avoid "drifting"; a menu
option to do it is included.
New cvar 'gyro_mode' for mode of operation, and to assign action to the new
"+gyroaction" button: disable or enable the gyro.
2022-06-07 09:24:08 -04:00
Yamagi
a80f5b6cd7
Merge pull request #844 from protocultor/inventory
Inventory screen keys/buttons display fix
2022-06-07 14:22:23 +02:00
Yamagi
1cd347beb7
Merge pull request #843 from devnexen/fbsd_build_warnings
freebsd/clang and server only warnings build fix
2022-06-07 14:20:59 +02:00
Yamagi
82a280bc40
Merge pull request #841 from apartfromtime/ui
Add menu bitmap support
2022-06-07 14:19:26 +02:00
Yamagi
09d6dfcd92
Merge pull request #840 from Dremor8484/Dremor8484-aimfix-doublebarrel_shotgun
Update weapon.c
2022-06-07 14:18:51 +02:00
apartfromtime
42e85a207a Cache cursor frames
Bug fix. Missed bringing this over from my other failed pull request.
2022-06-05 13:28:58 +10:00
David Carlier
4a60ba634c GL1 renderer fix VLA with no size cases, 2022-05-29 14:43:28 +01:00
Yamagi
3872a60e6c Bump version number to 8.11pre. 2022-05-29 07:12:58 +02:00
Yamagi
31260fc0fd Bump version number to 8.10. 2022-05-29 07:10:24 +02:00
Yamagi
ba2fc77ee8 Enforce a minimal render (dsiplay) time for dlights of 32 milliseconds.
Several effects use dlights which are rendered for only one frame.
Muzzle flashes are an example. While this worked on 1997th computers,
todays hardware renders way too many frames for these dlights to be
visible at all. Work around that by enforcing a minimal display time
of 32 milliseconds for each dlight.

Fixes part of #815.
2022-05-28 16:44:29 +02:00
maraakate
deec7e422d src/common/shared/shared.c: Check >= maxsize in Info_SetValueForKey(). Found by ASAN. 2022-05-27 18:28:31 -04:00
Jaime Moreira
0419cd7931 Inventory screen keys/buttons display fix
When a key/button name is too long, and its bound to an inventory element, its
display in the inventory screen misaligns the item it is bound to, even pushing
it out of the inventory frame.

This commit limits its display to the maximum of 6 characters the inventory
screen allows.
2022-05-21 22:59:02 -04:00
apartfromtime
7e1bc6911b Code style changes
Tabs to white-space.
BSD style.
2022-05-22 05:52:25 +10:00
David CARLIER
aaf6489d21 freebsd/clang and server only warnings build fix 2022-05-21 20:19:04 +01:00
apartfromtime
809588798e De-align apply action
Draw the "apply" action string from right to left, with no alignment.
2022-05-21 22:22:10 +10:00
apartfromtime
07fc65f9c5 Add menu bitmap support
Adds menu bitmap struct, drawing of a menu bitmap and highlighting if bitmap menu item is in focus.
Allows items that are gray (inactive) to be skipped when adjusting the menu cursor.
Removed switch case from Menu_SelectItem, all items either do or do not call their callback functions.
2022-05-21 22:21:29 +10:00
Dremor8484
25aeb81fa7
Update weapon.c
aimfix cvar now applies to the doublebarrel shotgun too
2022-05-20 11:37:34 +02:00
Yamagi
12c7fddfaa
Merge pull request #827 from protocultor/sdlcontroller
Full transition to SDL_GameController for gamepad usage
2022-05-17 19:42:19 +02:00
Daniel Gibson
413b44b4cd Qcommon_Frame(): Try to get closer to desired packet framerate
.. by running a packet frame if the current renderframe is closer to
the time the packet frame *should* be run than the next renderframe
(presumably) will be.

This should also help when using cl_maxfps -1 on a slow system that
can't reach the desired rfps (vid_maxfps or display refresh rate).
Without this change, we might run int the problem described in the
following example:
Imagine having cl_async 1, cl_maxfps 100, no vsync and a system that
mostly only reaches about 60fps. So rfps is 100 and pfps is 50.
But then (without this change) running at 60fps means that only every
second renderframe is a packetframe, so the packetframerate
*effectively* is 30, which can cause movement/clipping/physics bugs
(for example when hugging some non-perpendicular walls, like the right
 wall with the window that leads to the last room in base1).
With this change the packet framerate would effectively be 60 (every
renderframe is also a packetframe), which is less buggy and also closer
to 50 than 30 is.
2022-05-09 20:27:41 +02:00
Daniel Gibson
f95b5e7725 Qcommon_Frame(): Make pfps and rfps floats
should be more precise when converting to microseconds
2022-05-09 02:05:19 +02:00
Daniel Gibson
502ff345c3 Introduce cl_maxfps -1 for "use optimal value based on render framerate"
(this is the default value of that cvar now)

In Qcommon_Frame(), if cl_async is 1, the packet framerate should
ideally be a fraction of the render framerate, and to avoid movement
glitches and such it should be between 45 and 90, ideally around 60.
With cl_maxfps set to -1, pfps now is set to such a value automatically.
2022-05-09 02:05:19 +02:00
Daniel Gibson
7cf1392765 Qcommon_Frame(): Improve max framerate handling when vsync is enabled
When setting rfps based on GLimp_GetRefreshRate() and vid_maxfps,
take into account that GLimp_GetRefreshRate() might return a value
that's slightly too low (like 58 or 59 when it's 59.95 and should be 60)

The 20% tolerance that, in case of vsync enabled, used to be handled
with `packetdelta < 0.8 * 1000000/pfps` (and the same for rfps) is now
instead added to rfps (and thus implicitly pfps, if it's >= refreshrate)
2022-05-09 01:43:08 +02:00
Daniel Gibson
5a8382064a Remove 0.95 factor for packet framerate
It could make things stutter, especially if cl_maxfps was deliberately
set to a fraction of the display refreshrate (as it'd target a few
frames less).
The 0.95 factor was supposed to ensure that we don't have more packet
frames than renderframes (or two packet frames in a row without
rendering in between), as that apparently breaks the movement prediction
code. We now ensure the same thing my not running a packet frame if no
render frame is run at the same time.
2022-05-08 18:10:25 +02:00
Jaime Moreira
422715cee2 Hot plugging / hot swapping of game controller(s)
May be unreliable on some devices, e.g. Nintendo Switch Pro Controller.
Works great on others, e.g. DualShock 4.

Delay added to gamepad initialization on hotplug, gives time to the OS to
recognize the device.
2022-05-08 01:05:07 -04:00
Jaime Moreira
20542420ef New controller alt buttons menu option
Allows to bind buttons that only will work with "+joyaltselector" active.
The definition of another "scope" of keys was needed, to identify ALT bindings.
2022-05-08 00:24:52 -04:00
Jaime Moreira
0aa44afa13 New customize controller buttons menu option
Handles game controller button bindings exclusively.
Classic "customize controls" option now handles only keyboard / mouse bindings.
This separation is achieved with the new order of QKEYS in keyboard.h, and
binding functions in menus (especially "MenuKey" functions) now take into
account the "scope" where they operate: keyboard/mouse only, controller only,
or both.
2022-05-07 23:55:00 -04:00
Jaime Moreira
d4100f7113 Menu inputs standardised
Streamlined menu inputs by making most "*_MenuKey(key)" functions to use
Key_GetMenuKey(). "Backspace" is not a special case anymore, so any menus
that have a "delete" option can already handle any input expected, like the
backspace or delete keys, or the "Y" button of the controller, to run it.

Also, fixed a bug where changing the key for "team chat" also changes the one
for "chat" in the "multiplayer" -> "customize controls" menu.
2022-05-07 22:45:44 -04:00
Jaime Moreira
2bb1b33d7e Full transition to use only SDL_GameController for gamepad
This removes the usage of SDL_Joystick for joystick buttons and hat, and
relies exclusively on SDL_GameController for input. This allows to identify
buttons in a consistent manner across multiple types of controllers, which
in turn allows to assign specific tasks to them without worrying of breaking
usability, like having "A" to accept and "B" to cancel in menus.

Init and Shutdown logic of game controller have been separated from main SDL
Init and Shutdown functions.

Old style button names "JOYx" have been removed.

If your gamepad has paddles or other extra buttons, you'll need at least
SDL version 2.0.14 to use them.
2022-05-07 21:26:50 -04:00
Yamagi
e294fc94e5
Merge pull request #822 from DanielGibson/gles3-rb
OpenGL ES 3.0 support
2022-05-07 09:45:30 +02:00
Yamagi
22ff171007
Merge pull request #825 from devnexen/curl_progress_fix
curl client show progress only when there actually some
2022-05-07 09:44:00 +02:00
Yamagi
434e85feaf
Merge pull request #823 from 0lvin/benchmark
Remove framelimits for timedemo
2022-05-07 09:42:16 +02:00
Yamagi
56d5342fa7
Merge pull request #816 from devnexen/refactor_cpu_pause
frame cpu pause refactoring.
2022-05-07 09:39:57 +02:00
David Carlier
c34071d05c curl client show progress only when there actually some 2022-05-07 07:03:40 +01:00
Denis Pauk
bbaf6d6b20 Remove framelimits for timedemo 2022-04-27 23:09:28 +03:00
Daniel Gibson
56e1b9bc1e Add gles3 renderer to videomenu 2022-04-27 00:33:46 +02:00
Daniel Gibson
0881a63b1e GLES3: Explicitly don't handle gl_drawbuffer
GLES can't render to the front-buffer
2022-04-27 00:33:46 +02:00
Daniel Gibson
a195305592 GL3: Fix particles on RPi4
tested V3D 4.2; OpenGL ES 3.1 Mesa 20.3.5
2022-04-26 04:10:57 +02:00
Daniel Gibson
89f63915a3 GLES3: Make newer shaders work with OpenGL ES 2022-04-26 04:09:38 +02:00
Daniel Gibson
c936e43420 GL3: Use one projection-view matrix in shaders
instead of separate projection and view matrices - this way there is
one less mat4 multiplication in the 3D vertex shaders.
2022-04-26 04:09:38 +02:00
Daniel Gibson
1eabde6b55 GL3: Make GLES3 work on Raspberry Pi 4B
(older Raspberry Pi versions don't support OpenGL ES 3.0, only 2.0)
2022-04-26 04:09:38 +02:00
Daniel Gibson
8737ce64fc GL3: Support OpenGL ES3.0 (compile time option GL3_GLES=yes)
the option defaults to no, of course.
2022-04-26 04:09:38 +02:00
Daniel Gibson
c6145b4e6a GL3: Only use FBO if under water
because on some systems (like RPi4 with my experimental GLES3 branch)
the overhead of a FBO is really noticeable, so no reason to pay for it
when it's not needed
2022-04-26 04:08:21 +02:00
David Carlier
df86c15395 frame cpu pause refactoring.
expanding to powerpc archs also for visual studio/MSVC while
keeping clang support for windows.
2022-04-25 18:17:46 +01:00
Daniel Gibson
3d619a1441 GL3: Implement underwater postprocess effect using framebuffer object
Can be disabled with gl3_usefbo 0.
Mostly this adds an underwater warping effect, like the soft-renderer,
and also like the vulkan renderer (the shader is based on the vk one).
When this is enabled, the v_blend effect (for fullscreen overlay with
one color, like when hit or to make the screen white-ish when under
water) is now applied in the shader used for rendering the FBO instead
of rendering a fullscreen quad in blendmode.
2022-04-25 17:44:51 +02:00
Yamagi
4db6534ab3 Implement damage tracking for the framecounter.
This fixes the framecounter in the soft renderer when `viewsize` is set
to something smaller than 100. This requires the renerer to rerender
bigger parts of the borders which has a measurable speed impact. About
5 frames less with the framecounter enabled on my system. No impact with
`viewsize 100`.
2022-04-24 00:17:48 +02:00
Yamagi
be3e0cc695 Fix viewsize not working correctly with the GL renderers.
The GL renderers require that the borders are redrawn after every
glClear() call, the damage tracking doesn't take that into account.
Since the speedup by the damage tracking is neglibiable in the GL
renderers, don't use it. Just redraw everything when we're running
with everthing which isn't the soft renderer.
2022-04-24 00:01:14 +02:00
Yamagi
a9a0c35a98 Rename the nightmare menu entry to hard+.
I think this looks ugly, I always called it nightmare and it was one of
the first changes I've made to Quake II. But for the sake of peace and
quiet change it to be standard conformant. Closes #809.
2022-04-23 16:35:27 +02:00
Yamagi
aa5d6636d6
Merge pull request #814 from protocultor/gamecontrollerdb
Load gamecontrollerdb.txt for SDL2 joy mappings
2022-04-23 16:21:09 +02:00
Denis Pauk
b2500d6aed soft: revert to use colormap
Apply light uses colormap for each color components with colorlights.
2022-04-17 23:25:22 +03:00
Denis Pauk
afc892001d soft: move light code to separate function 2022-04-17 23:07:38 +03:00
Denis Pauk
a58fb0ed01 soft: fix colors 2022-04-17 23:07:38 +03:00
Denis Pauk
96a78c41c8 soft: speedup apply grey light to wall 2022-04-17 23:07:38 +03:00
Denis Pauk
e1d5bad4db soft: fix grey light with fix c20c47b0 2022-04-17 23:07:38 +03:00
Jaime Moreira
45d8228dff Corrected silly string concatenation 2022-04-16 11:53:22 -04:00
Jaime Moreira
db0e643419 Load gamecontrollerdb.txt for SDL2 joy mappings 2022-04-16 01:37:15 -04:00
Yamagi
6e45f5a66b
Merge pull request #810 from protocultor/prefweap
Added prefweap command to select weapon by priority
2022-04-13 11:51:33 +02:00
Jaime Moreira
fadb281ec9 Added cvar to define SDL gamepad's 'Back' button 2022-04-06 22:15:14 -04:00
Jaime Moreira
f80e5224bb Added prefweap command to select weapon by priority 2022-04-06 15:28:34 -04:00
Yamagi
9d451faca5
Merge pull request #808 from devnexen/sw_useq
S/W last instance of strncpy usage.
2022-04-03 17:46:58 +02:00
Yamagi
8fa5ea3599
Merge pull request #807 from devnexen/config_settings_haiku
saving data into Haiku system user config.
2022-04-03 17:44:06 +02:00
David Carlier
2425082a04 S/W last instance of strncpy usage. 2022-04-03 14:58:04 +01:00
David Carlier
7ce0964b9b saving data into Haiku system user config. 2022-04-02 04:22:55 +00:00
Denis Pauk
ccb22843bf soft: use float for medium light 2022-03-29 22:29:28 +03:00
Denis Pauk
e650eff100 soft: preshift values in lightmap 2022-03-29 22:29:28 +03:00
Denis Pauk
020ce27109 soft: speedup colorlight=0
colorlight>0 is regressed little bit.
2022-03-29 22:29:28 +03:00
Denis Pauk
a0da1717cc soft: use max light in blocklights (colorlight=0) 2022-03-29 22:29:28 +03:00
Denis Pauk
3b825670ba soft: fix lightmap mask 2022-03-29 22:29:28 +03:00
Denis Pauk
c20c47b06f soft: skip light apply on wall's 2022-03-29 22:29:28 +03:00
Denis Pauk
ff1814922e soft: use vid_lightthreshold for skip apply light 2022-03-29 22:29:28 +03:00