like the dhewm3 version and the OS and architecture of the dhewm3
version that created the savegame.
Also added an internalSavegameVersion so be independent of BUILD_NUMBER
fixes#344
I created this repo from the original dhewm3 repo, but I used
git filter-branch to kill all the files that are not needed to just
build base.dll and d3xp.dll (or .so or .dylib or whatever).
So this is basically just the files the original Doom3 SDK had, but
taken from dhewm3 instead (and thus GPL licensed and patched for
64bit-support etc) + some dhewm3 specific stuff + CMakeLists.txt
to build them.
The git filter-branch details:
filter-branch -f --prune-empty --tree-filter /tmp/killkill.sh @
## /tmp/killkill.sh:
#!/bin/sh
find . -exec /tmp/removeothers.sh {} \;
exit 0
## /tmp/removeothers.sh:
#!/bin/bash
FNAME="$1"
if [[ $FNAME == \./\.git* ]] || [[ $FNAME == \./d3xp/* ]] || [[ $FNAME == \./game/* ]]
then
#echo "ignoring $FNAME"
exit 0
fi
if ! grep -Fxq "$FNAME" /tmp/d3sdklist.txt
then
#echo "REMOVING $FNAME"
rm -rf "$FNAME"
fi
exit 0
## /tmp/d3sdklist.txt was is just a textfile with one path per line with
all the files (and directories!) I wanted to keep, like:
.
..
./sys/platform.h
./framework/Game.h
./config.h.in
./CMakeLists.txt
## ... and all the relevant files from the SDK
Added r_aspectratio -1 which means "auto" (as new default).
This mode sets fov_x and fov_y according to screen-width/height.
=> No need to set r_aspectratio manually anymore (assuming your display's
pixels are about square).
The standard aspect ratios can still be enforced as before, though.
(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.
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.
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'.
Required for events with string arguments. On debug builds
an assert() is triggered when trying to save such an event,
while events could not be properly restored in any build.
This happens when going from map delta4 to hell1 and the
autosave feature kicks in. The trigger event 'selectWeapon'
with the string argument 'weapon_fists' is in the event queue.
With the binary from id a warning is issued:
WARNING: player1 is not carrying weapon ''
so the bug exists in there too, just that its a release build
and doesn't abort().
I also managed to trigger this while saving shortly after
activating an elevator switch.
Don't include the lazy precompiled.h everywhere, only what's
required for the compilation unit.
platform.h needs to be included instead to provide all essential
defines and types.
All includes use the relative path to the neo or the game
specific root.
Move all idlib related includes from idlib/Lib.h to precompiled.h.
precompiled.h still exists for the MFC stuff in tools/.
Add some missing header guards.
Alot of stack and event variables are pointers. Align the size of
all script and event variable types to sizeof(intptr_t) so that
the CPU needs only one fetch insn on 64bit archs.
Tested on x86 and x86_64 and found no different script behaviours
compared to the binary from id.
Savegames on x86_64 do work, but are not compatible to x86 and vice
versa (among other issues, the stack is written to file as-is).
x86 builds can still load savegames from the official binary and
vice versa.