Commit graph

512 commits

Author SHA1 Message Date
Christoph Oelckers
266364fc2e - properly implement texture offsets 2020-05-24 13:26:45 +02:00
Christoph Oelckers
00e7b2fa25 - simple stuff from the texture manager inclusion commit.
To get this out of the way first...
2020-05-24 00:27:24 +02:00
Christoph Oelckers
ae6403a205 - added a level of abstraction to the lookup table code to ease later refactoring. 2020-05-23 22:43:05 +02:00
Christoph Oelckers
f929419a0a - refactoring of the lookup tables. 2020-05-23 22:43:04 +02:00
Christoph Oelckers
b971bc2717 - avoid using global palette settings when drawing 2D content with a custom palette.
Instead pass the palette info with the render call to avoid stale global state.
2020-05-23 22:43:01 +02:00
Christoph Oelckers
8d3199514d - removed some 'pragma' cruft. 2020-05-23 13:08:10 +02:00
Christoph Oelckers
8bd5f12b42 - matching sound backend code with GZDoom.
# Conflicts:
#	source/core/sound/s_soundinternal.h
2020-05-23 12:59:11 +02:00
Christoph Oelckers
6a8efb7520 - update of music code, in particular separating the engine-specific lookup from the backend.
# Conflicts:
#	source/core/music/music.cpp

# Conflicts:
#	source/build/src/palette.cpp
2020-05-23 12:37:47 +02:00
Christoph Oelckers
d0406e27b6 - all base palette data has been transitioned to GPalette. 2020-05-23 12:31:05 +02:00
Christoph Oelckers
6f9ee4b60f - store palettes in the palette container. 2020-05-23 12:31:05 +02:00
Christoph Oelckers
6a0785bbd4 - manual update of some missed content. 2020-05-22 18:28:03 +02:00
sirlemonhead
17be2617cf Clean up the FileStream code: Remove non-working Is_Eos() and make Seek() and Skip() return int. 2020-05-22 17:38:21 +02:00
Evan Ramos
4d7b37ca1a Rednukem: Remove redundant comment and fix formatting
# Conflicts:
#	source/rr/src/gameexec.cpp
2020-05-22 17:26:36 +02:00
sirlemonhead
8f8f033956 Rednukem: Limit sprite shade change to Redneck Rampage games, and add guard for invalid array access. Fixes ASAN error. 2020-05-22 17:22:18 +02:00
sirlemonhead
02d4712e57 Rednukem: Fix MVE crash on Release gcc builds. 2020-05-22 17:21:03 +02:00
sirlemonhead
808d0591eb Rednukem: Add newline to end of playmve.h 2020-05-22 17:21:03 +02:00
sirlemonhead
b89c6da6b8 Rednukem: Playback support added for Rides Again intro movie. Closes #266
# Conflicts:
#	GNUmakefile
#	platform/Windows/rednukem.vcxproj
#	platform/Windows/rednukem.vcxproj.filters
#	source/rr/src/game.cpp
2020-05-22 17:21:03 +02:00
alexey.lysiuk
2974af3178 - fixed a bunch of compilation errors with MSVC 16.6.0 2020-05-21 10:29:59 +03:00
Mitchell Richters
10142eee6b RR: Move lastInputTicks from DukePlayer_t struct to PlayerData_t struct.
Better location for it since it never needs to be sent across the wire in a multiplayer situation. It's now also located where the other properties to do with input being tied to frame-rate are located.
2020-05-14 10:00:16 +02:00
Mitchell Richters
22ae4182b5 RR: Properly reset pPlayer->lastInputTicks in G_EnterLevel() since all calls to P_ResetPlayer() are commented out.
Repairs issue with player spinning out of control when entering a new level.
2020-05-13 15:12:44 +02:00
Mitchell Richters
d411defd04 RR: Reset one_eighty_count if player angle input is detected. 2020-05-13 15:12:44 +02:00
Mitchell Richters
5f59c1364c RR: Process one_eighty_count (Turn-around key) at frame-rate. 2020-05-13 15:12:44 +02:00
Mitchell Richters
5299a0625d RR: Process q16rotscrnang and q16look_ang at frame-rate.
Had to move lastInputTicks to the DukePlayer_t struct. When first running P_GetInput(), the initial value of elapsedInputTicks is the actual value of timerGetHiTicks(), which is into the thousands. This high initial value was affecting how scaleAdjustmentToInterval() scales as it was taking an initial q16look_ang value of 512 and overflowing the fix16_t type, making it -32,768.
2020-05-13 15:12:44 +02:00
Mitchell Richters
22e9396feb RR: Promote look_ang to Q16.16. 2020-05-13 15:12:44 +02:00
Mitchell Richters
21e58160bf RR: Promote rotscrnang to Q16.16. 2020-05-13 15:12:44 +02:00
Richard C. Gobeille
c5e4c9631d RR: fix stupid input scaling bug 2020-05-11 21:27:29 +02:00
Mitchell Richters
e7621b4e05 RR: Properly scale tilt_status on vehicles with input being tied to frame-rate. 2020-05-11 21:27:29 +02:00
Mitchell Richters
da04a1d0aa RR: Return to centre improvements.
- Lock player horizon while returning to centre.
- Precisely scale player's horizon in time with rate at which 'pPlayer->return_to_center' decrements.
- Check player's horizon is between 99 and 101 degrees, not 99.9 and 100.1. The extra 0.9 degrees of precision is not noticeable and is dramatically slower.
- Reset 'pPlayer->return_to_center' to '0' when player's horizon is at 100.
- Match q16horizoff precision to precision of q16horiz.
2020-05-11 21:27:29 +02:00
Mitchell Richters
549ff75b99 RR: Change horizSkew from fix16_t to int8_t.
- No point converting an int to fix16, only to convert it back. It's only ever an unrounded integer.
2020-05-11 21:27:29 +02:00
Mitchell Richters
c7d3753c2b Revert "RR: Fix hard landing from preventing vertical mouse movement with player input tied to frame-rate."
This reverts commit 4bc105ec07.
2020-05-11 21:27:29 +02:00
Mitchell Richters
9cc86bd003 RR: Restore old interpolations when camera is chasing actor who whacked you (idea from NY00123). 2020-05-11 21:26:34 +02:00
Richard C. Gobeille
3b6b1a3063 Fix stupid typo that broke the camera aiming at the enemy that killed you in Duke3D 2020-05-11 21:26:34 +02:00
Mitchell Richters
8730bd9dda - allow game's clock to keep running while paused (restores interpolations/animations in menus). 2020-05-08 21:23:02 +02:00
Mitchell Richters
401e87f3d9 RR: Remove left-over else statement that should have been removed in 0ec2b87. 2020-05-08 10:51:59 +02:00
Mitchell Richters
d58f90de19 RR: Properly lock player movement when necessary while in a vehicle.
- This makes map follow mode work as expected again.
2020-05-08 10:51:59 +02:00
Mitchell Richters
9c27f49d42 RR: restore proper vehicle accuracy to RedNukem code-base.
- I tried to do something smarter originally but want the values to be 100% accurate to upstream.
2020-05-08 10:51:59 +02:00
Mitchell Richters
4bc105ec07 RR: Fix hard landing from preventing vertical mouse movement with player input tied to frame-rate. 2020-05-08 10:51:59 +02:00
Mitchell Richters
2e3bcdadd6 Duke 3D & RR: Repair issue where player would not return to centre following hard landing.
- Accidentally left in while merging changes from upstream.
- Change restores accuracy to game play in that a hard landing now returns the player's view to center.
2020-05-08 10:51:59 +02:00
Richard C. Gobeille
08bc2fbbcd RR: set .horizRecenter when handling SK_CENTER_VIEW
This seems so obvious that I almost think I intentionally left it out before, but I can't remember why I would have.
2020-05-08 10:51:59 +02:00
Richard C. Gobeille
8225d20e23 RR: zero .horizAngleAdjust and .horizSkew after checking playerquitflag instead of before
I don't think this actually makes a difference, but it's more consistent.
2020-05-08 10:51:59 +02:00
Richard C. Gobeille
bcf4903505 RR: zero .horizSkew in P_DoJetpack() 2020-05-08 10:51:59 +02:00
Richard C. Gobeille
818e14448d RR: zero player .horizRecenter, .horizSkew, and .horizAngleAdjust in P_ResetPlayer() 2020-05-08 10:51:59 +02:00
Mitchell Richters
4e1905e630 - reset buttonMap button states after returning from pause for RR (stops keys acting stuck down if down prior to pausing). 2020-05-06 10:51:08 +02:00
Mitchell Richters
e0e06284a5 - fix interpolation stutters when opening console for RR. 2020-05-06 10:51:08 +02:00
Mitchell Richters
db428a4f03 All Games: Make more precise use of 'scaleAdjustmentToInterval()'.
- Inline function returns a double, therefore we should use it and not potentially truncate the mantissa.
- Use divisors to get true numbers of some floats (3.333 -> 10/3, etc).
- Remove a few brackets/parentheses where possible from what are already exceedingly bracketed lines.
2020-04-14 00:00:21 +02:00
Mitchell Richters
02d436f802 Change Next/Previous Weapon button handling for Duke and RR games.
- Resolves inability to change weapons under SDL-based environments as reported at https://forum.zdoom.org/viewtopic.php?f=340&t=67232#p1142970
2020-04-13 23:59:47 +02:00
Christoph Oelckers
156a225ff4 - renamed global palookup variable.
Since the same word gets used in text messages and local variables in the game code it is easier this way to search for it and facilitate its transition to the translation table management in PaletteContainer.
2020-04-13 23:58:46 +02:00
Christoph Oelckers
fda4293013 - draw the movie franes outside of the tile system to reduce the palette maintenance.
The movie code has always been the part causing the most issues because it alters the palettes - the rest treats them as static data.
2020-04-13 23:58:45 +02:00
Christoph Oelckers
fac004b4d2 - palette code cleanup 2020-04-13 23:58:44 +02:00
Christoph Oelckers
d46ea7481f - handle RRRA E1L2's fog in the shader instead of hacking the shade tables. 2020-04-12 08:30:43 +02:00