Commit graph

2722 commits

Author SHA1 Message Date
Yamagi
1a913eb7d1 Resolve pathes before adding them to the search path.
Working with canonical fullpathes everywhere makes debugging easier.
And it will be used in a later commit to make sure, that each path is
added only once.
2020-10-20 08:20:20 +02:00
Yamagi
7553dc4856 Sanitize pathes before adding them to the search path.
* Convert back slashes into forward slashes.
* Make sure that there's no slash at the end.

In theory this is a noop, just making the output somewhat more readable.
2020-10-19 17:51:11 +02:00
Yamagi
fa345ed38e Move FS_ListMods() upward, to a more appropriate place in the file. 2020-10-19 17:22:23 +02:00
Yamagi
36d64aaefb Check if FS_LIstFiles() returned NULL.
This would have prevented the 7.44 release f*ckup. In practise this
shoudl never happen, because there's always baseq2/ but you never know
and it's better to be sure.
2020-10-19 17:19:44 +02:00
Yamagi
5ed882763a Implement one qsort() comparator function for strings and use it. 2020-10-19 17:17:09 +02:00
Yamagi
cfd5bce43d Bump version number to 8.00pre (again). 2020-10-17 15:37:27 +02:00
Yamagi
6102a36dab Bump version number to 7.45. 2020-10-17 15:37:27 +02:00
Yamagi
4e6b85a2bb Update CHANGELOG for 7.45. 2020-10-17 15:37:12 +02:00
Yamagi
f49a7f482f Pass correct path specifier to FS_ListFiles().
This prevents Sys_FindFirst() further down below getting called with
wrong arguments, returning a null pointer. The null pointer crashes
the filesystem. :/
2020-10-17 15:18:47 +02:00
Yamagi
6498876c1a Revert "Bump version number to 8.00pre."
This reverts commit 0d20fffd8e.
2020-10-17 15:18:21 +02:00
Yamagi
0d20fffd8e Bump version number to 8.00pre. 2020-10-16 10:17:37 +02:00
Yamagi
bbc382dc66 Bump version number to 7.44. 2020-10-16 10:13:44 +02:00
Yamagi
262e84f26a
Merge pull request #615 from devnexen/dfbsd_port
DragonFlyBSD build fix.
2020-10-11 09:20:51 +02:00
David Carlier
915c680f52 DragonFlyBSD build fix. 2020-10-10 14:29:28 +01:00
Yamagi
f536c9a82a Update the CHANGELOG for 7.44. 2020-10-08 13:01:03 +02:00
Yamagi
d5dcf3a772 Fix several inconsistencies and typos in console output. 2020-10-08 12:38:29 +02:00
Yamagi
e3aefbff2c Add some more build time options to the startup output.
* cURL
* Systemwide installation
2020-10-08 12:08:20 +02:00
Yamagi
e9a0162eea -fvisibility=hidden is a compiler option, don't pass it to the linker. 2020-10-08 12:02:35 +02:00
Yamagi
bf83db4d6d Add an ASAN option to the Makefile.
ASAN includes DEBUG. ASAN can be overriden by the environment.
2020-10-08 11:56:41 +02:00
Yamagi
0cdfd8f292 Bring the CMakeLists.txt more inline with the Makefile:
* Always set -fvisibility=hidden
* Set -Wl,--no-undefined where it is supported
* Add missing libraries for Windows
2020-10-08 11:44:38 +02:00
Yamagi
257075c928
Merge pull request #610 from 0lvin/for_review
Add ioquake3 vstr/nextdemo support
2020-10-08 10:24:30 +02:00
Denis Pauk
db20a6ce18 Add ioquake3 vstr/nextdemo support 2020-10-06 23:38:12 +03:00
Yamagi
0a159eefb2 Limit the work around against wrong resolutions to fullscreen.
When Q2 runs in windowed mode, SDL can never switch to the wrong the
resolution. The resolution isn't switched, of course. The work around
prevented Q2 from creating Windows larger than the resolution of the
primary display. For example a primary display of 1280x1024 prevented
a window size of 1680x1050 on the much bigger secondary display.
2020-10-06 17:52:14 +02:00
Yamagi
dfaf33e478 Force stdout and standerr on Windows to unbuffered mode.
Normally stdout and stderr are buffered. In case of a crash the last
lines aren't written to the stdout.txt, making post mortem debugging
difficult. Forcing both FDs to unbuffered mode ensures that everything
gets written. The performance impact is negliable.
2020-10-06 17:22:50 +02:00
Yamagi
741ffcdb1c
Merge pull request #604 from devnexen/last_bit_for_haiku
Last bit for proper Haiku support.
2020-10-06 16:55:41 +02:00
Yamagi
2231268bc7
Merge pull request #603 from devnexen/code_simplification
Little simplification for NetBSD, /proc/<pid>/exe works just fine too.
2020-10-06 16:55:01 +02:00
David Carlier
800cdf9617 Last bit for proper Haiku support.
Even tough it is a multi user os, due to BeOs heritage and being backwards
compatible with, the desktop runs as root, thus its dog get eaten after all...
2020-10-02 14:36:57 +00:00
David Carlier
6bb23c908f Little simplification for NetBSD, sysctl works just fine too. 2020-09-30 22:56:19 +01:00
Yamagi
41931d7a06
Merge pull request #599 from earth-metal/master
Create "mods" submenu to allow changing "game" cvar via UI
2020-09-12 16:11:26 +02:00
Yamagi
213a338d03
Merge pull request #598 from JoBergeron/map-autocomplete
map name autocompletion
2020-09-12 16:02:44 +02:00
earth-metal
a4de026eb3 Create "mods" submenu to allow changing "game" cvar via UI
Combs all Raw search paths to find game dirs containing PAK/PK2/PK3
files.  If multiple uniquely-named directories exist, then show a "mods"
option on the "Game" menu and allow selection of desired mod on new
eponymous submenu.  Includes fix for memory leak of mapnames (read from
"maps.lst") when changing games.
2020-09-06 16:43:36 -04:00
JBerg
a843ef416f map name autocompletion 2020-09-05 22:32:13 -04:00
Yamagi
408d019792
Merge pull request #595 from devnexen/haiku_simplification
Haiku support, code simplification.
2020-09-05 16:50:50 +02:00
David Carlier
e4fac541a9 Haiku support, code simplification.
using more straightforward approach to get the current binary path.
Actual approach more fit to get other infos (e.g. address mappings and so on).
2020-09-01 11:27:26 +00:00
Yamagi
56ddda7021
Merge pull request #593 from devnexen/fbsd_mprotect
Hunk: FreeBSD set the map permission to max read and write
2020-08-31 13:31:03 +02:00
David Carlier
5e89f96067 Hunk: FreeBSD set the map permission to max read and write
which cannot be made executable afterwards.
2020-08-24 23:45:54 +01:00
Yamagi
2bb6fdf4a8
Merge pull request #592 from earth-metal/master
Start Server Menu: reload "maps.lst" after "game" dir is changed
2020-08-23 20:33:19 +02:00
earth-metal
c31926ec90 Reset map list in "start network server" menu when "game" cvar changes
When the "game" directory is changed, clear the current list of maps in
the "start network server" menu so that it will be re-initialized the
next time the menu is accessed.
2020-08-23 14:06:01 -04:00
Daniel Gibson
37a5ca8a8d Make "wait" in scripts wait for >= 17ms, fix #591
so it waits for about the time of one frame at 60fps, but independently
of the actual framerate.
Without this fix, wait is broken unless vsync is on, because
CBuf_Execute() is called about 1000 times per second by Qcommon_Frame(),
even if no render- or packet-frame is executed.
(vsync "fixes" this because then we have a real wait at the end of each
 renderframe)
2020-08-23 17:21:20 +02:00
Yamagi
634748a5b5 Add missing return type for SV_ListMaps_f() 2020-08-23 10:34:52 +02:00
Daniel Gibson
93d1dfe60d Fix typo in Qcommon_Mainloop() that reduced performance, refs #591
We busy-looped for 5000 microseconds, i.e. 5 milliseconds, which reduces
the framerate to < 200fps
I guess the value was copypasted from Sys_Nanosleep() below, but
that was nanoseconds of course..
Anyway, busy-looping for 5 *micro*seconds instead fixes it.
2020-08-20 17:27:09 +02:00
Daniel Gibson
1d42dbc541 doc/090_filelists.md: Fix GOG music filelist
for GOG it's TrackXY.ogg, not just XY.ogg
2020-08-20 16:01:54 +02:00
Yamagi
0fdc3750e0
Merge pull request #589 from JoBergeron/listmap-cmd
added listmaps command
2020-08-20 07:19:27 +02:00
JBerg
ffe9997735 Documented the new listmaps console command 2020-08-19 21:14:53 -04:00
JBerg
b746f4520d added listmaps command 2020-08-18 23:18:22 -04:00
Yamagi
1f3f796322 Add cl_anglekick, when set to 0 angle kicks are ignored.
Angle kicks are used for weapon recoil, damage kicks and the like.
Setting the `cl_anglekicks` to `0` ignored them, they're read from
the network but not displayed. The cvar is cheat protected, it's
reset to `1` on server connect.

Rquested by Martin via mail.
2020-08-17 14:18:51 +02:00
Daniel Gibson
fd0c058b2e Implemented coop_elevator_delay cvar (for func_plat)
In coop it's often hard to get on the same elevator together, because
they're immediately triggered once the first player steps on it.
This cvar sets a delay (1 second by default) for the elevator to wait
before moving, so other players have some time to get on it.
If you like elevators/platforms that suck, just set it to `0` :-P

Currently only used in func_plat, if it turns out that other entities
are used for automatically triggered platforms, we'll have to adapt
those as well (I guess wait_and_change() is generally useful for that).

We're not bumping the savegame version because they should only break in
an uncommon corner case: *Coop* savegames created with clients including
this change will not work on older clients - SP savegames are not
affected and old savegames on new clients also still work.
2020-08-10 14:27:35 +02:00
Yamagi
1a6dea5a0b Add coop_pickup_weapons, allow a weapon to be taken several times.
In coop a weapon can be picked up only once. That's annoying, because in
coop ammunition is sparse and not getting the ammunition that comes with
a weapons make things worse. When `coop_pickup_weapons` is set to `1` a
weapon may be picked up if:

1) The player doesn't have the weapon in their inventory.
2) No other player has already picked it up.
2020-08-10 13:52:33 +02:00
Yamagi
7ca55afffe
Merge pull request #585 from devnexen/backtrace_detection
backtrace support rework proposal.
2020-08-09 17:27:50 +02:00
David Carlier
1412d0201c Backport changes to old Makefile 2020-08-09 15:52:11 +00:00