Commit graph

185 commits

Author SHA1 Message Date
dhewg
d250bf9262 Initial make install target for *nix
cmake fails it, so *nix only.
2018-08-20 01:46:34 +02:00
dhewg
f9ca9c0119 Bump ASYNC_PROTOCOL_MINOR
Due to changed protocol we're not compatible anymore.
2018-08-20 01:46:34 +02:00
dhewg
e85823f8ce Remove all OS specific gamepak code
Useless since there are no gamepaks.
2018-08-20 01:46:34 +02:00
dhewg
ed099aa128 Remove all gamepak FileSystem<->Async[Client|Server] code 2018-08-20 01:46:34 +02:00
dhewg
5aa122978d Don't try to extract libraries from gamepaks. 2018-08-20 01:46:34 +02:00
dhewg
5adb4810d4 Remove UpdateGamePakChecksums()
Not required anymore.
2018-08-20 01:46:34 +02:00
dhewg
b992d117f0 Remove all client/server gamepak checks
We don't use any gamepaks anymore, remove the related checks.
2018-08-20 01:46:34 +02:00
dhewg
22c8120b56 Overhaul the *nix based BASE path
Try BUILD_DATADIR first (build time setting), then the vanilla
doom3 path.
2018-08-20 01:46:34 +02:00
dhewg
a31bb00e21 Rename game libraries to the game name
Never use "game" as library name, use the game name instead. This
allows d3xp/mods to coexist in a single (installation-)directory.

This paves the way for future `make install` or binary installers.

Additionally, the "mods" menu entry works from within the game gui.
2018-08-20 01:46:34 +02:00
dhewg
47672c4592 Add TODO for OSX .dylib's for the bundle 2018-08-20 01:46:34 +02:00
dhewg
e67598eeb5 Introduce CMAKE_INSTALL_PREFIX relative paths
configure style install dirs.
2018-08-20 01:46:34 +02:00
dhewg
c4af9b0ce0 Get the shared library suffix from the build system 2018-08-20 01:46:34 +02:00
dhewg
98791a0ea5 Drop the CPU suffix from libraries on all platforms 2018-08-20 01:46:34 +02:00
dhewg
0025ad6cf7 Introduce fs_configpath
Split fs_savepath for config files. This is in preparation for
moving the writable paths on *nix to $XDG_DATA_HOME and
$XDG_CONFIG_HOME.
Affected files: config.spec, *.cfg, doomkey, xpkey.
2018-08-20 01:46:34 +02:00
dhewg
1f17040f0c Unify Sys_*Path() into Sys_GetPath() 2018-08-20 01:46:34 +02:00
dhewg
e632cd030b Get rid of ID_DEMO_BUILD
There are no demo pk4s compatible to this 1.3.1 codebase.
2018-08-20 01:46:34 +02:00
dhewg
2d43892ef3 Get rid of sys_stub.cpp
Unused.
2018-08-20 01:46:34 +02:00
dhewg
a97f685132 Use PATH_MAX for MAX_OSPATH on all platforms
The hardcoded 256 doesn't cut it.
2018-08-20 01:46:34 +02:00
dhewg
a385bbeb29 Fixes issues with MacOSX.
- Fixes compiler errors with mismatching types in DoomController.mm
- Adds PPC_INTRINSICS fix to Simd_Altivec.h
2018-08-20 01:46:33 +02:00
dhewg
16657c0ce3 Rename PVS vars to match their type 2018-08-20 01:46:33 +02:00
dhewg
8dfc6df02a s/ReadDeltaLong/ReadDeltaInt/
to match the argument type
2018-08-20 01:46:33 +02:00
dhewg
8cd1580d60 s/WriteDeltaLong/WriteDeltaInt/
to match the return type
2018-08-20 01:46:33 +02:00
dhewg
ae319dbe4a s/ReadDeltaLongCounter/ReadDeltaIntCounter/
to match the return type
2018-08-20 01:46:33 +02:00
dhewg
c971755d98 s/WriteDeltaLongCounter/WriteDeltaIntCounter/
to match the argument type.
2018-08-20 01:46:33 +02:00
dhewg
431415c51c s/ReadLong/ReadInt/ to match the return type 2018-08-20 01:46:33 +02:00
dhewg
814abb55b9 s/WriteLong/WriteInt/ to match the argument type 2018-08-20 01:46:33 +02:00
dhewg
a9ffb336f6 s/BigLong/BigInt/ to match the return type 2018-08-20 01:46:33 +02:00
dhewg
420783b151 s/LittleLong/LittleInt/ to match the return type 2018-08-20 01:46:33 +02:00
Daniel Gibson
a9a6042a04 Remove usage of long type from idlib/
Apart from some minor stuff, this changes the signature of some methods
of Parser and Token classes and of the (unused) Random2 class.
That no problem though, because the calling code uses normal ints
anyway.
2018-08-20 01:46:33 +02:00
Daniel Gibson
ce87a8904c Remove longs from game/ and d3xp/
(Except for handling of longs in TypeInfo and win32-only Maya import stuff).

sizeof(long) == sizeof(int) on x86 and win64,
but not on 64bit (x86_64) linux/unix/osx/.. so they should be avoided.
2018-08-20 01:46:33 +02:00
Daniel Gibson
5c08cb0140 Fix PVS calculations on 64bit systems
Monsters got stuck in same places of d3xp because PVS calculations
returned that they were not in the players PVS.
This only happened on LP64 systems like Unix/Linux amd64 where
sizeof(long) == 8 - it did not happen on Win64 because it's LLP64, i.e.
sizeof(long) == 4 (like on x86 32bit).

Bit fiddling code in Pvs.cpp seemed to assume that sizeof(long) == 4
like on win32.

Fixes #7.
2018-08-20 01:46:33 +02:00
Daniel Gibson
ca4b20eb08 Fix several bugs from iodoom3 bugtracker
rhyskidd@gmail.com found them (with PVS studio IIRC), reported them and posted
patches.
Some of the patches were incorrect so I rewrote them.
2018-08-20 01:46:33 +02:00
Daniel Gibson
d51c05c768 Fix idMatX::IsOrthonormal()
The original implementation was pretty broken (but not used anyway),
it is now fixed and improved a bit (got rid of one inner loop).
This (at least part of the problem) was detected by PVS-Studio,
see http://www.viva64.com/en/b/0120/ Fragment 3
2018-08-20 01:46:33 +02:00
dhewg
5199d8ea65 Add the build target "Profile" suitable for profiling 2018-08-20 01:46:32 +02:00
dhewg
c5c5762ae4 Fix "unreachable code" warnings 2018-08-20 01:46:32 +02:00
dhewg
9de64efa62 This is dhewm 3
Rename project, now at https://github.com/dhewm
2018-08-20 01:46:32 +02:00
dhewg
5b49b7242b Get rid of unused defines in Licensee.h 2018-08-20 01:46:32 +02:00
dhewg
6b30d96d44 Get rid of CPU_EASYARGS
Never use the event callbacks with mismatching prototypes.
2018-08-20 01:46:32 +02:00
dhewg
151288e170 CMake: Use config.h for BUILD_OS and BUILD_CPU
This fixes, among others, FreeBSD 64bit builds where the build
system used a "amd64" suffix and runtime "x86_64".
2018-08-20 01:46:32 +02:00
dhewg
a6796cb444 CMake: Detect libcurl and use it when found
Move ID_ENABLE_CURL to config.h
2018-08-20 01:46:32 +02:00
dhewg
6dfe95e732 CMake: Create config.h
Use config.h for configure time settings.
2018-08-20 01:46:32 +02:00
dhewg
9ee84519fa CMake: Use CMAKE_SOURCE_DIR
Instead of CMAKE_CURRENT_SOURCE_DIR.
2018-08-20 01:46:32 +02:00
dhewg
c7d406835e Get rid of ID_OPENAL
This is always required for clients.
2018-08-20 01:46:32 +02:00
dhewg
ac090883ac More fixes regarding event saving and restoring
Fix silly issue from 3d692b58 (sizeof(E_EVENT_SIZEOF_VEC)).
Align entity values of events to the native pointer size, which
is noticeably faster on x86_64 and fixes another assert() in
debug builds.

Past savegames with entities in events are not compatible.
2018-08-20 01:46:32 +02:00
dhewg
0fb3d2d37f Prevent assert() while saving and restoring events
The argument size of each event is checked in debug builds
and this change was missing from the x86_64 commits.

Surprisingly this didn't trigger yet with the original game,
only with the mod 'Classic Doom 3'.
2018-08-20 01:46:32 +02:00
dhewg
b8f1a3e38c Port EAX to EFX
First attempt at porting the EAX reverb code to EFX.
This only works when the ALC_EXT_EFX extension is supported by
the OpenAL vendor (which is not the case for the OSX supplied
framework, use OpenAL soft instead).

The current stable version of OpenAL Soft (v1.13 as of this
writing) can barely handle this additional workload, current
master is highly recommended when using this feature.
2018-08-20 01:46:32 +02:00
dhewg
b87bd8040f Get rid of memory status functions
Unused.
2018-08-20 01:46:32 +02:00
dhewg
cdefb2ba7a Always allow multiple instances 2018-08-20 01:46:32 +02:00
dhewg
a1fe69f429 Get rid of Sys_DefaultCDPath()
Stub on all platforms.
2018-08-20 01:46:32 +02:00
dhewg
a5d6a76961 Get rid of ID_MCHECK
mcheck() is not thread safe, use MALLOC_CHECK_ or TCMalloc
instead.
2018-08-20 01:46:31 +02:00