Commit graph

698 commits

Author SHA1 Message Date
Christoph Oelckers
83796e9eed - changed map startup order to first play a cutscene before loading the level.
Something with the timers is screwing up here if a cutscene gets played - Blood's timer code is even worse than Duke's.
Fixes #151.
2020-08-11 23:21:08 +02:00
Christoph Oelckers
0686928ee8 - fixed transition to credits in blood.
Fixes #150.
2020-08-11 20:26:50 +02:00
Christoph Oelckers
fcc271ed7b - treat 100 as maximum volume for 2D sounds when coming from the SFX data.
Without this, many sounds are way too quiet, e.g. at tne beginning of E2M1 or the end of E3M7.

Fixes #146.
2020-08-11 20:17:56 +02:00
Christoph Oelckers
6a10a7f266 - changed the rules for dimming the menu to be more clear
It will no longer depend on the game state when the menu was opened but the current game state - only on the dedicated menu screen there's no dimming - everywhere else a dim gets applied.

Also renamed GS_DEMOSCREEN to GS_MENUSCREEN for clarity
2020-08-11 00:46:27 +02:00
Mitchell Richters
7243c08379 - stop weapon from moving up and down while cl_weaponsway 0 is set.
* Default zDelta is -2048, so only add (zDelta / 128.) if `cl_weaponsway 1` and add (-2048. / 128.) otherwise.
* Fixes #134 a bit better.
2020-08-11 08:40:42 +10:00
Christoph Oelckers
1d03d3d6a2 - fixed HUD meter and crosshair default size.
Fixes #137
2020-08-10 23:06:24 +02:00
Christoph Oelckers
7a2b1ee0aa - moved Blood's updatePauseStatus call to the main loop.
Fixes #149
2020-08-10 22:44:24 +02:00
Christoph Oelckers
030ca6f75d - reset the timer after the initial cutscene in Blood 2020-08-10 22:22:27 +02:00
Christoph Oelckers
97b202955c - strip the drive letter off WAV names for cutscenes. 2020-08-10 22:11:00 +02:00
Christoph Oelckers
5165834441 - handle GS_FULLCONSOLE in Blood 2020-08-10 22:02:58 +02:00
Christoph Oelckers
e93ec79608 - Blood: restart music after level warp. 2020-08-10 21:41:16 +02:00
Christoph Oelckers
3ba5ca46c9 - fixed font alignment in Blood 2020-08-10 21:14:42 +02:00
Christoph Oelckers
28b9aafe69 - disable translucency for menu text shadows.
It didn't look that great.
2020-08-10 20:27:00 +02:00
Christoph Oelckers
7317caf567 - do not loop the scream sound on the summary screen.
Fixes 143.
2020-08-10 20:24:49 +02:00
Christoph Oelckers
8a2d34cceb - fixed typo in BUNZ cheat. 2020-08-10 20:22:12 +02:00
Christoph Oelckers
ddf238ff19 - fixed cheat args parser.
Fixes 139
2020-08-10 20:18:21 +02:00
Mitchell Richters
09f347353a - fix cl_weaponsway() for Blood.
Fixes #134.
2020-08-10 22:08:44 +10:00
Mitchell Richters
db6d2e4d89 - fix cl_viewbob() for Blood.
Fixes #134.
2020-08-10 22:08:44 +10:00
Christoph Oelckers
d3df4e580c - do not restart one-page image scrollers with Enter
Instead go back one menu level.

Fixed #129
2020-08-10 01:12:53 +02:00
Christoph Oelckers
c7e664d3a6 - animate status bar elements
Fixes #127
2020-08-10 00:36:50 +02:00
Mitchell Richters
a3dfa58662 - correct typo in Blood text string because I'm OCD like that. 2020-08-05 23:17:57 +10:00
Mitchell Richters
157933e902 - fixed regression from b9eef9c6a3 where the angle wouldn't apply if horizon was specified. 2020-08-04 23:13:22 +10:00
Mitchell Richters
b9eef9c6a3 - make ang and horiz optional on each game's warptocoords CCMD as suggested in commentary for 1dc6edfa56. 2020-08-04 22:33:17 +10:00
Mitchell Richters
b08d571be9 - create Blood dynamic CCMD warptocoords.
* The setting of the player's horizon/viewangle probably still requires work, but warping to pos x/y/z works fine.
2020-08-04 19:10:43 +10:00
Christoph Oelckers
41cc5cac34 - fixed responsiveness issues with Blood's weapon selection.
This shouldn't really do anything and might point to some deeper implementation flaw.
2020-08-04 00:06:36 +02:00
Christoph Oelckers
b0c1140649 - fixed bad default for viewDrawText's alpha.
Like so many other things in Build the concept of alpha is hopelessly stupid and really makes no sense, and this was carried over here.
2020-08-03 21:26:19 +02:00
Christoph Oelckers
d526c6401f - use the generic cheat system for Blood. 2020-08-03 20:51:31 +02:00
Christoph Oelckers
724c811de3 - Moved message storage to the map records. 2020-08-03 20:16:32 +02:00
Christoph Oelckers
35a5c4e23c - undid hardcoded coupling of Mapinfo slots with episode/level pairs in Blood.
This both lifts the imposed limit of 16 levels and will allow dynamic management of global mapinfo data.
2020-08-03 20:11:30 +02:00
Christoph Oelckers
0036402be8 - removed most of the network code in Blood.
Mainly to expose the parts that still get used in single player because there's some problems here that need addressing.
ENet is also gone now.
2020-08-03 20:06:27 +02:00
Christoph Oelckers
825b286424 - removed some redundant parts in level.cpp
Let's use the underlying data directly.
2020-08-03 19:11:48 +02:00
Christoph Oelckers
5704c57fe0 - changed the byte order swappers to use ZDoom's versions
This is to reduce redundancy, plus, these are native on Windows and macOS.
2020-08-03 19:09:57 +02:00
Christoph Oelckers
3c8da8c421 - moved LocalKeys to controls.cpp
to consolidate input code in one file.
2020-08-03 19:08:49 +02:00
Mitchell Richters
48e4bccc6d - oops. Missed change of hudDraw() zDelta from int to double while implementing ae2d2c7948. 2020-08-03 10:23:15 +10:00
Mitchell Richters
ae2d2c7948 - interpolate zDelta with higher precision from updated CalcSmoothRatio() function that returns a double instead of an int. 2020-08-03 09:07:19 +10:00
Mitchell Richters
61820ddef5 - interpolate bobx and boby with higher precision from updated CalcSmoothRatio() function that returns a double instead of an int. 2020-08-03 08:50:48 +10:00
Christoph Oelckers
8a31e96602 - use all available precision to render Blood's weapon animations mpre smoothly, instead of throwing it away by needlessly storing it in some integer fields. 2020-08-03 00:25:40 +02:00
Christoph Oelckers
be9402c4e0 - fixed Blood not accepting any input after loading a saved game. 2020-08-03 00:10:18 +02:00
Christoph Oelckers
38616d90a3 - renamed some members of Blood's EPISODEINFO struct. 2020-08-02 23:47:21 +02:00
Christoph Oelckers
00ecea47aa - use CCMDs for input in Blood where appropriate. 2020-08-02 20:44:37 +02:00
Christoph Oelckers
4a049c1a4d - split sprite animation off view.cpp 2020-08-02 19:59:14 +02:00
Christoph Oelckers
e2498a53a9 - split Blood prediction code into its own file. 2020-08-02 19:43:45 +02:00
Christoph Oelckers
a9820abcae - migrated the remaining 2D content in Blood away from rotatesprite. 2020-08-02 19:00:32 +02:00
Christoph Oelckers
4e9ea9ef60 - fixed bad merge from some time agp. 2020-08-02 18:12:43 +02:00
Christoph Oelckers
1392f4db01 - handle the view frame with backend features. 2020-08-02 18:02:13 +02:00
Christoph Oelckers
fc390e244f - background for text screens. 2020-08-02 17:45:03 +02:00
Christoph Oelckers
1150e3ee0d - removed unused stuff from screen.cpp and deleted screen.h. 2020-08-02 13:54:36 +02:00
Christoph Oelckers
7846178130 - missed this... :( 2020-08-02 13:53:14 +02:00
Christoph Oelckers
3a32e8840f - ported Blood's status bar to the Status bar class.
Now it allows downscaling just like Duke's.
2020-08-02 13:35:34 +02:00
Christoph Oelckers
b259b94300 - implemented status bar scale control for Blood. 2020-08-02 08:48:23 +02:00
Christoph Oelckers
cc8798f6e2 - preparations for rendering Blood's status bar through the Statusbar class. 2020-08-02 08:39:51 +02:00
Christoph Oelckers
49a25c417b - split Blood's status bar code off into its own file. 2020-08-01 21:23:33 +02:00
Christoph Oelckers
ec846a3e63 - fixed shadows on Blood's text. 2020-08-01 20:07:32 +02:00
Christoph Oelckers
2f94ae8160 - removed Blood's message display.
We'll use the common one in c_console from now on.
2020-07-31 21:06:56 +02:00
Christoph Oelckers
a12cdf849e - fixed text in the menu 2020-07-31 21:05:57 +02:00
Christoph Oelckers
7bf3d5186f - Blood font refactoring. 2020-07-31 21:05:09 +02:00
Christoph Oelckers
5bae2fcef5 - moved global include out of namespace. 2020-07-31 21:04:28 +02:00
Christoph Oelckers
713c41c0a9 - fixed bad ordering of directives. 2020-07-31 21:03:23 +02:00
Christoph Oelckers
b6cb0ce1a1 - consolidated shade to light conversion 2020-07-31 20:58:55 +02:00
Christoph Oelckers
b308e730ea - started replacing rotatesprite with DrawTexture.
As an added bonus, thia now allows stretching the menu caption box for longer texts, rotatesprite could not do that.
2020-07-31 20:39:02 +02:00
Christoph Oelckers
5ed624a48d - Blood: stop music before showing the summary screen. 2020-07-29 23:39:37 +02:00
Christoph Oelckers
347ed51036 - refactored Blood's main loop.
* moved Smacker video playing code into the backend, so now all games can play all supported video formats
* logos and level intro/exit videos use ScreenJob
2020-07-29 23:18:08 +02:00
Christoph Oelckers
e345bf389f - removed some inactive pieces of code. 2020-07-28 00:05:56 +02:00
Christoph Oelckers
92d94543e5 - removed the Blood demo code as it won't be usable in this form anyway. 2020-07-28 00:01:16 +02:00
Christoph Oelckers
74c4bbc0e0 - preparations for refactoring Blood's HUD drawer, mainly to pass the palette explicitly to the drawers. 2020-07-27 23:29:10 +02:00
Christoph Oelckers
8a92ecb70c - some minor reordering of code to only have one call to credLogosDos. 2020-07-27 19:45:34 +02:00
Christoph Oelckers
709dac7c37 - more Polymer leftover. 2020-07-27 19:39:27 +02:00
Christoph Oelckers
c7fca86cf5 - removed incomplete Polymer code from Blood.
Looks like this was abandoned - this was still mostly Duke3D code
2020-07-27 19:38:58 +02:00
Christoph Oelckers
218a9c84fd - removed the last remaining Blood helpers from the file system, also deleted a few short files whose contents could be moved. 2020-07-27 19:38:41 +02:00
Christoph Oelckers
5f14153f3b - deleted declaration of deleted function. 2020-07-27 19:37:59 +02:00
Christoph Oelckers
dcd773ed9d - removed some unused pieces of code. 2020-07-27 19:37:58 +02:00
Christoph Oelckers
4e3ad09d70 - merged 5 more headers into misc.h.
These small header files are really counterproductive, file count has already gone down from 143 to 106.
2020-07-27 19:37:17 +02:00
Christoph Oelckers
b2f794bde5 - cache QAVs outside the file system as well.
- delete some voxel code that's software rendering only.
- apply Big Endian byte swapping for SFXs, as well, now that this no longer involves hacking the file system cache.
2020-07-27 19:37:02 +02:00
Christoph Oelckers
b804589f81 - implemented a proper cache for Blood's SEQs.
Messing around in the file system cache should be a no-go, so now it's no longer done.
This also allows reenabling the byte swapping needed for Big Endian.
2020-07-27 19:28:54 +02:00
Christoph Oelckers
bbbd7fadbb - merged several of Blood's smaller headers. 2020-07-27 19:17:13 +02:00
Christoph Oelckers
ab9854a215 - merged the 3 sound related headers in Blood. 2020-07-27 19:17:13 +02:00
Christoph Oelckers
dfda0c9cb2 - rewrote Blood's map loader to use FileReader directly instead of implementing its own wrapper around the lump cache.
Also deleting a few other unused files.
2020-07-27 19:17:00 +02:00
Christoph Oelckers
aea6467d00 - call D_ProcessEvents in Blood's main loop. 2020-07-27 19:12:49 +02:00
Christoph Oelckers
374a850565 - merged all of Blood's ai state headers together to reduce number of files and include clutter. 2020-07-25 17:56:39 +02:00
Christoph Oelckers
f9d48e1f68 - removed all the intermediate variables for the status bar size.
hud_size now gets used directly by the status bar code.
2020-07-25 13:26:56 +02:00
Christoph Oelckers
be9094cb97 Silenced lots of warnings pointed out by XCode. 2020-07-23 17:02:59 +02:00
Christoph Oelckers
6227f9f7fd - optimizations for better savegame performance. 2020-07-21 21:32:38 +02:00
Christoph Oelckers
a9f152c1fe - added JFDuke's label type checker and did some cleanup on the CON init code.
Most importantly: Use dynamic buffers for managing the labels instead of hijacking some other storage space.
2020-07-15 12:34:42 +02:00
Christoph Oelckers
99161e2e4a - made ps an array of player_struct like it originally was. 2020-07-15 00:26:58 +02:00
Christoph Oelckers
2fd2ad2212 - sky code cleanup and transitioning of Duke's. 2020-07-15 00:06:19 +02:00
Christoph Oelckers
1e9679aceb - removed faketimerhandler and the last static remains of EDuke's netcode. 2020-07-14 21:15:37 +02:00
Christoph Oelckers
05abc262ba - removed libdivide for good and the unused C++ wrapper for fix16 along with it. 2020-07-14 20:57:42 +02:00
Christoph Oelckers
424716bb88 - say goodbye to libdivide! 2020-07-14 20:21:16 +02:00
Christoph Oelckers
f9c03760a3 - removed setuptile DEF command due to the hacky implementation and general uselessness of what can be done with it. 2020-07-14 17:47:11 +02:00
Christoph Oelckers
fedeec73c7 - cleaned out some unused parts of engine.cpp 2020-07-14 17:35:19 +02:00
Christoph Oelckers
5655015691 - YAX is also gone now. 2020-07-14 16:06:14 +02:00
Christoph Oelckers
19ef0cd295 - removed screentext and reverted Blood to its original text output. 2020-07-14 15:25:35 +02:00
Christoph Oelckers
1a0b388570 - removed a few tabledivide uses in the game modules 2020-07-14 14:08:59 +02:00
Christoph Oelckers
aa01adb2f1 - removed osd.h as it was merely a minimal wrapper around c_dispatch, giving some alias names.
Nothing that's needed when cutting ties to upstream.
2020-07-14 14:00:27 +02:00
Christoph Oelckers
2e05ff532b - got rid of the struct trackers.
They were only used for handling an undefined case in the renderer but the overhead and side effects were too severe.
2020-07-14 13:51:03 +02:00
Christoph Oelckers
7e261425bb - time to get rid of clockticks.hpp.
Aside from its non-existent license it was also not the correct way to handle more precise view interpolation.
2020-07-14 13:00:52 +02:00
Christoph Oelckers
a93ed1e502 Merge branch 'master' into back_to_basics2
# Conflicts:
#	source/blood/src/view.cpp
#	source/core/gamecontrol.cpp
2020-07-14 12:57:38 +02:00
Christoph Oelckers
9caf1ead91 - use the common interpolation function for Blood.
This keeps the main calculation for time difference in one place.
2020-07-14 12:48:56 +02:00
Christoph Oelckers
481ac965cf - reverted ClockTicks to an integer so that interpolation can be reimplemented without it affecting the global game timer.
The entire method at use here is essentially not correct. Interpolation should be handled independently of the game timer directly based on the underlying clock, like in ZDoom.
There's interpolation bugs in the Build games that cannot be fixed if totalclock is used for it, but if we use something else we do not need a fractional totalclock.
2020-07-14 11:52:38 +02:00
Christoph Oelckers
6b86d7606f - safety commit - does not compile! 2020-07-07 13:19:09 +02:00