Commit Graph

242 Commits

Author SHA1 Message Date
terminx ca789dc4d0 Wait to run G_MoveLoop() until a frame has just been rendered
This should give G_MoveLoop() a better chance to not run past the time when another frame is to be drawn.

git-svn-id: https://svn.eduke32.com/eduke32@8195 1a8010ca-5511-0410-912e-c29ae57300e0
2019-10-20 10:45:49 +02:00
terminx d7f779eaec Use EXIT_FAILURE and EXIT_SUCCESS from stdlib.h when calling exit()
git-svn-id: https://svn.eduke32.com/eduke32@8190 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/build.cpp
#	source/build/src/polymost.cpp
#	source/build/src/tiles.cpp
#	source/duke3d/src/astub.cpp
2019-10-20 10:45:48 +02:00
terminx a649130327 Clamp nextPageDelay in G_FPSLimit() to 0.0 - g_frameDelay
git-svn-id: https://svn.eduke32.com/eduke32@8148 1a8010ca-5511-0410-912e-c29ae57300e0
2019-10-20 08:12:26 +02:00
terminx 85dd8e31a5 G_HandleAsync() -> gameHandleEvents()
git-svn-id: https://svn.eduke32.com/eduke32@8140 1a8010ca-5511-0410-912e-c29ae57300e0
2019-10-20 07:48:15 +02:00
terminx 802f69d324 Partial timer cleanup
After this revision, the only place timerUpdate() is called is from within handleevents(). S_Cleanup(), MUSIC_Update(), and G_HandleSpecialKeys() are now called from a timer callback set with timerSetCallback(). This more or less deprecates the usage of faketimerhandler() in EDuke32 and Mapster32, but other games still rely on the functionality.

git-svn-id: https://svn.eduke32.com/eduke32@8139 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/duke3d/src/astub.cpp
2019-10-20 07:48:13 +02:00
terminx 593b5740e3 Reword stupid error message that has probably never even been seen
git-svn-id: https://svn.eduke32.com/eduke32@8138 1a8010ca-5511-0410-912e-c29ae57300e0
2019-10-20 07:48:05 +02:00
terminx 4d3dedd4ab ifdef DEBUGGINGAIDS for this quick exit crap
this is more like regular AIDS than DEBUGGINGAIDS though

git-svn-id: https://svn.eduke32.com/eduke32@8137 1a8010ca-5511-0410-912e-c29ae57300e0
2019-10-20 07:48:04 +02:00
Christoph Oelckers 8b1f2f5fc9 - disabled console lockout option as a modding feature.
No, sorry, but this is something I consider unacceptable!
2019-10-19 00:27:34 +02:00
Christoph Oelckers 9a52e8039c - rerouted tileCreate and tileSetExternal calls. 2019-10-15 23:18:52 +02:00
Christoph Oelckers c3bc690e98 - more updating and bug in UpdatePicSize fixed. 2019-10-15 20:02:37 +02:00
Christoph Oelckers 0e165e40a3 - first batch of adjustments to the new tile management.
- consolidated Polymost precaching and removed precaching for static tiles because they now are always loaded.
- removed cache configurability. On modern systems this is relatively pointless - allocating 50 or 100 MB is a non-issue - and the cache is due for replacement anyway.
2019-10-15 00:54:14 +02:00
Christoph Oelckers bb67a1ba38 - some reworking of the texture code to make integration of Build tiles easier. 2019-10-12 08:54:06 +02:00
Christoph Oelckers fbc22e0125 - sanitized walock.
Sorry, but having a globally writable pointer to every texture is just insane and makes any functional management impossible.
This is merely a preparation for adding a real texture manager. That cannot be done if any code can write over the data at will. For that, it now has to make the texture writable first or create a writable empty texture.
2019-10-11 23:31:59 +02:00
Christoph Oelckers 3621aae3f0 - rerouted all write accesses to tilesiz and picsiz through a function interface.
These will have to do some texture management bookkeeping so directly changing the values is problematic.
This required changing the parameter interface in polymost.cpp because a few places hacked around with the global state to pass parameters to subfunctions.
2019-10-11 21:04:31 +02:00
Christoph Oelckers ae1e090716 - all non-shader related GL calls are gone from the main code base. 2019-10-04 21:13:04 +02:00
Christoph Oelckers cd920299d0 - moved winbits.cpp to the platform folder and cleaned out unused parts. 2019-09-25 22:38:47 +02:00
Christoph Oelckers 2cbe211e7c - transitioned project to CMake and deleted most of the old build system.
The EDuke32 and RedNukem frontends are working, Blood isn't yet.

Notes:

many of the CMake variables and its output still refer to zdoom. Before changing that I wanted to make sure to be able to commit something that works.
support code for Windows XP has been entirely removed. On Windows this will only target Vista and up.
the crc32.h header had to be renamed to deconflict from zlib.
several Windows API calls were changed to call the A-versions directly. Weirdly enough there were places that defined their parameters as T types but in a non-working way.
removed some remaining editor files and support for the native software rendering only Windows backend.
in a few simple cases, replaced 'char' with 'uint8_t'. The code as-is depends on chars being unsigned which is non-portable. This needs to be carefully reviewed.
2019-09-22 23:15:46 +02:00
Christoph Oelckers 55a879fcc0 - put EDuke frontend source into a namespace.
This commit does not work yet!
2019-09-21 22:53:00 +02:00
Christoph Oelckers 30c47a8511 - include namespace file in all sources as the very first include. 2019-09-21 20:59:54 +02:00
Christoph Oelckers 71b332459b - removed Android and Mapster headers plus raw EDuke assets in Blood folder. 2019-09-21 19:30:20 +02:00
Christoph Oelckers 998ac01157 - manual merge of all NBlood changes that couldn't get cherry picked. 2019-09-21 13:02:17 +02:00
nukeykt 107a630883 Add TROR rendering
# Conflicts:
#	source/blood/src/mapedit.cpp
#	source/build/include/editor.h
#	source/build/include/polymer.h
#	source/build/src/build.cpp
#	source/build/src/polymer.cpp
2019-09-21 10:11:02 +02:00
terminx aa8ce8d42a Fix USE_OPENGL=0 builds
git-svn-id: https://svn.eduke32.com/eduke32@8082 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 23:17:57 +02:00
terminx e262135463 Use multiples of 5 for the HUD scale option and cap the range at 50-100
git-svn-id: https://svn.eduke32.com/eduke32@8071 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 21:10:42 +02:00
terminx 1ba0406b4d uint64_t in G_FPSLimit()
git-svn-id: https://svn.eduke32.com/eduke32@8070 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 21:10:42 +02:00
terminx 4300eb1a66 Rename gamefunc_Crouch_Toggle to gamefunc_Toggle_Crouch to match the only existing similarly named gamefunc, gamefunc_Toggle_Crosshair
Now bound to C by default.

git-svn-id: https://svn.eduke32.com/eduke32@8059 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 21:09:18 +02:00
terminx dcf9768c20 Rework crouch toggle
This is almost entirely contained in P_GetInput() now. It still uses two separately mappable buttons but you can get away with only gamefunc_Crouch_Toggle.

git-svn-id: https://svn.eduke32.com/eduke32@8057 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 21:09:17 +02:00
terminx 9841b053ea Set actor .bpos after A_GetZLimits() in A_Spawn()
git-svn-id: https://svn.eduke32.com/eduke32@8055 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 21:09:16 +02:00
pogokeen 222e593437 Change some clocks to support sub-tick precision using a new class, ClockTicks.
Using that higher precision, interpolate at a higher granularity.
Further, truncate the target interpolation time to vertical blank boundaries to avoid producing temporal artifacts.
Fix issues caused by interpolation calculations being handled differently in multiple places (and fix cases where smoothratios were being thrown away only to be redone without checking all proper conditions).
Ensure ClockTicks changes do not break other targets (EKenBuild, VoidSW), but note any interpolation there is not similarly updated.

git-svn-id: https://svn.eduke32.com/eduke32@8050 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/build.cpp
#	source/build/src/sdlayer.cpp
2019-09-20 21:09:14 +02:00
terminx b9e61fcb7f Use a vec3_t instead of separate vars to hold temporary position data in G_HandleMirror()
git-svn-id: https://svn.eduke32.com/eduke32@8029 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 20:14:10 +02:00
hendricks266 4f5434dffe Don't clobber E1L8 for user maps
git-svn-id: https://svn.eduke32.com/eduke32@8016 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 20:12:21 +02:00
hendricks266 733cb636cd Return to the main menu after completing a user map
git-svn-id: https://svn.eduke32.com/eduke32@8015 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 20:12:20 +02:00
terminx 59b0c0e3f7 Revise r8001
git-svn-id: https://svn.eduke32.com/eduke32@8004 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:12:21 +02:00
terminx c72a69ff6f This timing stuff actually works
It doesn't help when it turns out the compiler is broken and implementing std::chrono::high_resolution_clock as something that only counts in ms instead of properly aliasing it to std::chrono::steady_clock!

git-svn-id: https://svn.eduke32.com/eduke32@8002 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/sdlayer.cpp
2019-09-20 16:12:16 +02:00
terminx 3b504975a2 Call A_GetZLimits() for sprites in the map at load time
git-svn-id: https://svn.eduke32.com/eduke32@8001 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:11:09 +02:00
hendricks266 345497b271 newgamechoices: usercontent flag
git-svn-id: https://svn.eduke32.com/eduke32@7998 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:11:03 +02:00
hendricks266 a29869f86e Fix gamepad analogs not working in menus when in game
git-svn-id: https://svn.eduke32.com/eduke32@7987 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:10:40 +02:00
hendricks266 ba730be6b6 Add Crouch Toggle gamefunc
git-svn-id: https://svn.eduke32.com/eduke32@7978 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:10:22 +02:00
terminx f76ca0a361 Fix remaining casts to vec2_t/vec3_t
git-svn-id: https://svn.eduke32.com/eduke32@7973 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/build.cpp
2019-09-20 16:07:36 +02:00
hendricks266 5c96fcb334 Add Third Person View gamefunc
git-svn-id: https://svn.eduke32.com/eduke32@7967 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:07:12 +02:00
terminx 620f0da65b Another attempt at improving/fixing the fps limiter
git-svn-id: https://svn.eduke32.com/eduke32@7954 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:03:41 +02:00
hendricks266 e7723efcf4 Fix skipping to the end of def blocks
git-svn-id: https://svn.eduke32.com/eduke32@7938 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:03:06 +02:00
terminx 564a68f1a7 Improve frame limiter logic
git-svn-id: https://svn.eduke32.com/eduke32@7935 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 16:03:00 +02:00
hendricks266 67b7d2408b newgamechoices
git-svn-id: https://svn.eduke32.com/eduke32@7930 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/defs.cpp
2019-09-20 16:02:49 +02:00
terminx 32cd1ae4dd Tweak the fatal engine initialization error and game already running dialog boxes a bit
git-svn-id: https://svn.eduke32.com/eduke32@7921 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/build.cpp
2019-09-20 16:01:11 +02:00
terminx 48f9edf743 New feature: combine SF_GLOBAL and SF_DTAG definesound flags to get Duke3D explosion sound behavior
git-svn-id: https://svn.eduke32.com/eduke32@7914 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 15:46:47 +02:00
terminx 40e54fdbbb Tweak how the semaphore used to detect multiple running copies of the game is utilized
git-svn-id: https://svn.eduke32.com/eduke32@7912 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 15:46:43 +02:00
terminx 9021b885d6 Eliminate pos_as_vec2 from anything that had it
git-svn-id: https://svn.eduke32.com/eduke32@7905 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/build/src/build.cpp
#	source/build/src/polymost.cpp
2019-09-20 15:46:28 +02:00
pogokeen 091a2961ab game.cpp: move check for quitevent during start-up so that if start-up is cancelled during definitions parsing, the game won't continue to play in a half-loaded state.
git-svn-id: https://svn.eduke32.com/eduke32@7900 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 15:44:15 +02:00
hendricks266 640b1c4461 Remove RTS names from standalone builds
git-svn-id: https://svn.eduke32.com/eduke32@7897 1a8010ca-5511-0410-912e-c29ae57300e0
2019-09-20 15:44:10 +02:00