Mitchell Richters
b5a9085aed
- Exhumed: Restore more accurate pitch adjustment for Ramses.
...
* Use `maphoriz(-11)` instead of some voodoo degree amount so it's clear when comparing sources.
* Don't stop interpolating while doing Ramses.
* Apply Ramses pitch amount to `nVertDestPan`, just like the original.
* Don't reset all angles when initialising Ramses, just set the yaw angle.
* Don't return player's view to center when doing Ramses, use the delta between `nDestVertPan` and the player's pitch, using same formula as original.
* Comment in how normal/non-ramses `nDestVertPan` setting should be 8x the sprite Z move delta, not 2x. I know it's not correct, but its been this way for a long time and we probably should CVAR it.
* When doing the player's death pitch, it's 40.156 degrees (horizon of 108), not 38 degrees (horizon of 100). This was a misread of mine way back when.
2023-03-26 22:13:57 +11:00
Christoph Oelckers
b6da4ecddf
- backend update from GZDoom.
2023-03-26 11:45:25 +02:00
Mitchell Richters
0840e547b7
- Exhumed: Reset the player actor's pitch with the rest of the actor resets.
2023-03-26 20:12:59 +11:00
Mitchell Richters
1888b7ee9f
- Exhumed: Ensure we back up the player actor's location after doing everything and not mid-way through a reset.
2023-03-26 20:09:43 +11:00
Mitchell Richters
950f4c2c38
- Exhumed: Restore nStandHeight
global and move to Player
struct.
...
* Was dropped in 572869f502
.
* Game's crouch testing necessitates that this value be pre-cached.
* Interestingly, this value is 62.5 whereas the game's view height is 55. Change in late development to make the world feel larger?
2023-03-26 20:06:25 +11:00
Mitchell Richters
fd62f1fb68
Revert "- Exhumed: Increase quake precision in SetQuake()
."
...
This reverts commit fb9ff7d105
.
* The game relies on this being low precision. It was causing a weird tremor in the training map.
2023-03-26 19:52:55 +11:00
Mitchell Richters
71aad07913
- Exhumed: Fix backwards logic from new pitch panning refactor.
...
* From 79f7ca976b
.
* Fixes #901 .
2023-03-26 18:56:01 +11:00
Mitchell Richters
e9a5f745fc
- Duke: Ensure pitch keys are done after adding player's input.
...
* As this function includes the actor's pitch clamp, it's important its done afterwards.
* Setup is already right for all the other games.
2023-03-26 16:40:25 +11:00
Mitchell Richters
0387282e37
- Fix two particularly loud warnings from GCC builds.
...
* `warning: type qualifiers ignored on function return type`.
2023-03-26 15:35:33 +11:00
Mitchell Richters
7d5ca901eb
- Exhumed: Clear all input out upon restarting the player.
...
* Stale accumulation from the last round can apply on the next tic.
2023-03-26 15:17:28 +11:00
Mitchell Richters
776c58c58a
- Duke: If we enter playerCenterView()
and put SB_CENTERVIEW()
back on, we need to null and lock input.
2023-03-26 14:36:23 +11:00
Mitchell Richters
0da2afe3d7
- Duke: Tidy up some of the pitch stuff.
...
* Remove some extern'd CVARs that didn't need externing.
* Change `player_struct::centeringView()` bool into proper method to handle the operation.
* Operation now properly unsets `SB_CENTERVIEW` if conditions aren't met instead of relying on implied behaviour from the rest of the playsim.
2023-03-26 13:35:12 +11:00
Mitchell Richters
a5a9882d9a
- Duke: Add a myriad of pitch recentering CVARs.
...
* Needs to be reworked into some kind of MP-safe flagging once we have demos/MP going. This will do for now.
* Fixes #853 .
2023-03-26 12:46:14 +11:00
Mitchell Richters
11049123b0
- Exhumed: Bring pickup code back into player.cpp
...
* We're going to tabbify everything soon anyway, might as well bring it in now.
2023-03-26 10:30:27 +11:00
Mitchell Richters
8f8809f66c
- Exhumed: Minor formatting changes to a number of player functions.
2023-03-26 10:00:06 +11:00
Mitchell Richters
76777a6567
- Exhumed: Change doPlayerActionSequence()
to do an early return instead of nested branches.
2023-03-26 10:00:06 +11:00
Mitchell Richters
dcfab3e57c
- Exhumed: Change doPlayerDeathRestart()
to do an early return instead of nested branches.
2023-03-26 10:00:06 +11:00
Mitchell Richters
b6c3753d3a
- Exhumed: Change doPlayerMovingBlocks()
to do an early return instead of nested branches.
2023-03-26 10:00:04 +11:00
Mitchell Richters
838aebdfb7
- Exhumed: Change doPlayerFloorDamage()
to do an early return instead of nested branches.
2023-03-26 09:51:26 +11:00
Mitchell Richters
8d1531ba78
- Exhumed: Change updatePlayerTarget()
to do an early return instead of nested branches.
2023-03-26 09:50:57 +11:00
Mitchell Richters
e7a0354109
- Exhumed: Fix possible workflow issue with zvel in doPlayerMovement()
.
...
* Originates from d976a6da01
.
* During change I missed the clamping of the zvel value between capturing `zz` and `zVel`.
* No observed issues, only noticed it when comparing something else but lets 100% maintain a accurate workflow.
2023-03-25 23:27:15 +11:00
Christoph Oelckers
8503f34eb5
- fix error message crash in SNDINFO parser.
2023-03-25 12:24:11 +01:00
Mitchell Richters
2bc6df7678
- Exhumed: Repair signedness issue with weapon change code.
...
* Never revealed itself when I was cheating to get weapons.
* Fixes #898
2023-03-25 22:05:06 +11:00
Christoph Oelckers
c6054595d0
- fixed lookup table generation for foggy fades.
...
ColorMatcher.Pick is not correct here, fortunately we do not need this for fog setup as it never uses the lookup so just do a normal copy of the first (fullbright) table.
2023-03-25 11:42:50 +01:00
Mitchell Richters
8f748fdb2a
- Exhumed: Fix noclipping so the player can clip through anything.
...
* The `inside()` test is now only performed when noclipping is off.
2023-03-25 21:36:17 +11:00
Mitchell Richters
7410c78ce4
- Exhumed: Merge pitch/yaw functions into one to minimise spread.
2023-03-25 21:26:56 +11:00
Mitchell Richters
7d6425fa06
- Exhumed: Amend 79f7ca976b
to use algorithm to cancel view pitch when disabling cl_slopetilting
.
2023-03-25 21:26:55 +11:00
Mitchell Richters
0189936070
- Exhumed: Use player pointer in MoveWeapons()
.
2023-03-25 21:26:55 +11:00
Mitchell Richters
4e1b269c59
- Exhumed: Use player pointer in AIPlayer::Draw()
.
2023-03-25 21:26:55 +11:00
Mitchell Richters
d270099aa7
- Exhumed: Use player pointer in AIPlayer::Damage()
.
2023-03-25 21:26:55 +11:00
Mitchell Richters
f0b9937ec7
- Exhumed: General tidy-up of AIPlayer::Damage()
.
2023-03-25 21:26:55 +11:00
Mitchell Richters
c3f0edf802
- Exhumed: Use player pointer in AIPlayer::Damage()
.
2023-03-25 21:26:54 +11:00
Mitchell Richters
45be386f7f
- Exhumed: Move nTemperature[]
into Player
struct.
2023-03-25 21:26:54 +11:00
Mitchell Richters
572869f502
- Exhumed: Reorganise RestartPlayer()
so player/actor variables are grouped.
2023-03-25 21:26:54 +11:00
Mitchell Richters
b4028cb250
- Exhumed: Clean up stack pointer names in RestartPlayer()
.
2023-03-25 21:26:54 +11:00
Mitchell Richters
c79a979395
- Exhumed: Store a player pointer on the stack and use in updatePlayerVelocity()
.
2023-03-25 21:26:52 +11:00
Mitchell Richters
7cfb5d9286
- Exhumed: Removed unneeded resetting of nDestVertPan
in doPlayerFloorDamage()
.
...
* Original game code below it was just resetting it anyway.
2023-03-25 19:56:20 +11:00
Mitchell Richters
12b4f68f24
- Exhumed: Directly inline interpfrac test into gi->Render()
.
2023-03-25 19:56:19 +11:00
Christoph Oelckers
32237421c9
- Exhumed: fixed Ramses's programmatic texture
2023-03-25 09:52:31 +01:00
Mitchell Richters
f96bc3ee31
- Exhumed: Reposition bIsFiring
setting.
...
* Mistake from e5e1428062
.
2023-03-25 18:13:11 +11:00
Mitchell Richters
e34c4353f6
- Exhumed: Properly clamp off pitch in death function.
2023-03-25 17:27:33 +11:00
Mitchell Richters
025f2ec5fb
- Exhumed: Do player pitch/yaw before movement code.
2023-03-25 16:58:15 +11:00
Mitchell Richters
79f7ca976b
- Exhumed: Refactor the pitch tilting/panning code.
...
* Made it work on the player's view pitch and not their actual pitch.
* Drastically simplifies implementation and allows its use even with mouse aiming.
2023-03-25 16:52:13 +11:00
Mitchell Richters
7ecf6b26c3
- Exhumed: Might as well split out the death restart as well.
2023-03-25 16:06:19 +11:00
Mitchell Richters
7da9b2c17d
- Exhumed: Slightly re-arrange where movement actions are called.
...
* Removes jank setups like testing whether the player is dead and nulling their input. Now, the movement code just doesn't call if they're dead.
2023-03-25 15:57:23 +11:00
Mitchell Richters
e5e1428062
- Exhumed: Split off runlist signal code from player ticker.
2023-03-25 15:57:22 +11:00
Mitchell Richters
a86751a355
- Exhumed: Move all underwater code into doPlayerBreath()
.
...
* Renamed to `doPlayerUnderwater()`.
* Keeps all underwater logic together.
* More importantly, fixes an issue 🙃 .
2023-03-25 15:12:13 +11:00
Mitchell Richters
52618ede14
- Exhumed: Amend 187710e9e2
.
2023-03-25 15:10:54 +11:00
Mitchell Richters
1ed91ade54
- Exhumed: Fix dopple actor picnum updating.
2023-03-25 14:19:07 +11:00
Mitchell Richters
481c52f175
- Exhumed: Move some player code out of exhumed.cpp and into player.cpp where it should be.
2023-03-25 14:08:02 +11:00