Commit graph

13519 commits

Author SHA1 Message Date
Christoph Oelckers
d17650f885 - removed the ValidateTarget call from HackSeqCallback.
The original function does not validate its target, it just uses undefined memory instead when this case happens.
2023-03-16 17:49:50 +01:00
Mitchell Richters
c4041affb1 - Duke: Reduce boilerplate from previous commit. 2023-03-16 22:24:34 +11:00
Mitchell Richters
9a17d33579 - Duke: Ensure spawned player actor has view height baked in up until the first getzrange() call.
* The original game spawning the player's sprite/actor would set the sprite's pos with the Z matching the player's, which had a height offset already applied.
* This baked in height offset was carried through up until the `SetActor()` call in `processinput()`, where the original game would then strip off `gs.playerheight`.
* This baked in height offset within the actor is critical on the first tic for pre-activated elevators on level spawn to function right, such as E1L2 and E2L3.
* Properly setting the player actor's Z immediately after the initial `getzrange()` call, but before other functions like `movement()`, etc further down in `processinput()` is the best spot.
* Fixes #870.
2023-03-16 22:15:11 +11:00
Mitchell Richters
8bcbc1b892 - Null the roll angle used for weapon drawing when looking left/right and with Blood's delirium for now.
* Intended to make the look left/right keys better, but doesn't work properly for weapons made up of layered parts of varying sizes.
* Fixes #879.
2023-03-16 16:34:31 +11:00
Mitchell Richters
528eb0ea9a - Blood: Fix state checks when using TNT while diving underwater.
* A mess of bloody proportions...
* Originates from d30c94c709.
* Fixes #878.
2023-03-16 15:50:52 +11:00
Mitchell Richters
cb1e4e7a34 - Exhumed: Ensure Player::items[] is signed.
* Change originates from b71c725e3e.
* Matches PCExhumed and GDX.
* Logic in game requires this variable to be signed.
* Fixes #415.
* Fixes #888.
2023-03-16 13:05:22 +11:00
Mitchell Richters
3d6f1e1a04 - Exhumed: Store dedicated player velocity in Player struct.
* Changes implementation in 67c7dd65f9.
* Cannot rely on the actor's velocity alone as parts of the game modify this, such as getting hit by lava dudes, but game nullifies this at the start of the player's tic.
2023-03-16 12:17:42 +11:00
Mitchell Richters
b42b9de2a2 Revert "- SW: Tune shadow drawing code so that it by default uses the sector's interpolated floorz when possible."
This reverts commit 3271c2011e.

* Fixes #884
* Fixes #892
2023-03-16 11:23:05 +11:00
Mitchell Richters
0d62e6befe - Exhumed: Optimise UnlinkIgnitedAnim() from fb97e3c6ca a bit.
* Bad cherry pick caused a stat iteration over the wrong stat number.
* Cleaned up commentary to reflect that we have actors and not so much sprites or an anim array anymore.
2023-03-15 22:52:14 +11:00
Mitchell Richters
07a82508fa - Blood: Fix palette of actor sprite on 2D automap.
* Fixes #846.
2023-03-15 22:22:52 +11:00
Mitchell Richters
e8f2f98473 - Repair voxel 2D vector adjustment.
* Originates from a6fb831894.
* Division taken off, probably mixing up x/yrepeat and x/yoffset.
* Fixes #869.
2023-03-15 20:42:24 +11:00
Mitchell Richters
a4bca328bc - SW: Remove Player::siang since we have the same data in 2023-03-15 19:57:45 +11:00
Mitchell Richters
7da3c62ea8 - Blood: Repair velocity scaling in ConcussSprite().
* Issue originates back from 645c606e39.
* During initial floatification, the velocity addition was changed a mulscale of 16 to 12, quadrupling the amplification.
* A lot's changed since then, but we can restore the size of the velocity by simply dividing the size value by 4x.
* Turned into a reciprocal as well to avoid division.
* Fixes #860.
2023-03-15 19:42:33 +11:00
Mitchell Richters
39624da390 - SW: Remove getViewHeightDiff() call in player sprite draw code.
* I added this when removing the player's pos vector in lieu of the sprite vector to further smooth out the sprite's Z in chase cam mode, but it just doesn't look good.
2023-03-15 19:42:33 +11:00
sirlemonhead
fb97e3c6ca PCExhumed: Fixed Ignited sprite anim issue that could cause invalid array access.
* Fixes #638.
2023-03-15 17:20:29 +11:00
Mitchell Richters
0dba1af7c0 - Move canslopetilt test for PlayerAngles::doViewPitch(). 2023-03-15 16:36:56 +11:00
Mitchell Richters
2162e51424 - Blood: Amend how QAVs process when game is paused.
* Repair of initial implementation in ebdc9c31f2.
* Fixes #883.
2023-03-14 21:45:47 +11:00
Mitchell Richters
016016b7ab - Blood: Fix max weapons slot test preventing slot 12 from being called.
* Fixes #891.
2023-03-14 21:45:46 +11:00
Mitchell Richters
a90665732c - Clean up other PlayerAngles interfaces for consistency. 2023-03-14 21:45:38 +11:00
Mitchell Richters
62561d863e - Tidy up PlayerAngles::doPitchKeys() interface by passing the whole sync packet through. 2023-03-14 21:45:37 +11:00
Mitchell Richters
9ffc65fa48 - Exhumed: Eliminate PlayerInput struct in favour of InputPacket object PlayerList::input. 2023-03-14 21:45:37 +11:00
Mitchell Richters
67c7dd65f9 - Exhumed: Remove PlayerInput::vel in favour of just using actor's velocity. 2023-03-14 21:45:37 +11:00
Mitchell Richters
73acffac2c - Exhumed: Move PlayerInput::nItem to Player struct as Player::nCurrentItem. 2023-03-14 21:45:37 +11:00
Mitchell Richters
f77b1007be - Exhumed: Remove unused PlayerInput::buttons 2023-03-14 21:45:37 +11:00
Mitchell Richters
c73ee5f848 - Exhumed: Move PlayerInput::pTarget to Player struct. 2023-03-14 21:45:37 +11:00
Mitchell Richters
c1f52b1137 - Adjust PlayerAngles::doViewPitch() so that view pitch always resets to 0 upon enabling mouse aiming. 2023-03-14 21:45:36 +11:00
Mitchell Richters
18ef460a99 - Tidy up interface for PlayerAngles::doViewPitch() since we have internal access to the player's actor. 2023-03-14 21:45:36 +11:00
alexey.lysiuk
41d7118099 - fixed compilation error
source\core\razefont.cpp(60,3): error C2181: illegal else without matching if
2023-02-21 10:30:44 +02:00
Christoph Oelckers
07d87940f2 - completed all of Blood's and Duke's fonts. 2023-02-20 16:52:51 +01:00
Christoph Oelckers
b645929035 - fixed some message mappings. 2023-02-19 13:01:20 +01:00
Christoph Oelckers
6729c342af - undid bad code from a broken GZDoom PR. 2023-02-11 19:49:49 +01:00
Christoph Oelckers
09c8430e4e - removed bad include. 2023-02-11 12:36:31 +01:00
Christoph Oelckers
8c99d7b034 - Backend update from GZDoom
* scriptable CVARs.
* GLES update
* various ZScript improvements.
2023-02-11 12:06:58 +01:00
Christoph Oelckers
fd04cda324 - added a font option to have lower case for Latin only.
This is meant for SW's SmallFont to avoid creating lowercase Greek or Cyrillic letters. The font is too small to render them adequately.
2023-02-11 10:43:59 +01:00
Christoph Oelckers
29de90beb6 - Duke: disable the 1.5 BigFont for languages using the Cyrillic or Greek alphabet
This font is incomplete, unlike the 1.3 variant, so for these languages use the font that can render them.
2023-02-11 10:43:09 +01:00
Rachael Alexanderson
3c4ab95664 - reflect https://github.com/ZDoom/gzdoom/pull/1983 2023-02-09 18:30:55 -05:00
Christoph Oelckers
6c77d1c39e - Duke: fixed setup of purely scripted enemies,
Some band-aid is still needed for the time being.
2023-02-09 17:34:59 +01:00
Mitchell Richters
17392fe400 - Change viewport aspect calculation from 6aa94a9b8e to be a reciprocal multiplication. 2023-02-06 19:58:08 +11:00
Mitchell Richters
f8035bb4ba - Re-calculate the sector for each eye if it has a shift factor applied. 2023-02-06 19:55:46 +11:00
Mitchell Richters
2020860ffe - For I_GetInputFrac(), just have the caller check if input is synchronised. 2023-02-05 08:40:25 +11:00
Mitchell Richters
9961a66a1f - Remove inputScale global and make static in mainloop.cpp. 2023-02-05 08:37:37 +11:00
Mitchell Richters
1938efabe6 - Fix bad return in scaletozero() from 924b601199. 2023-02-05 08:27:44 +11:00
Mitchell Richters
924b601199 - Change scaletozero() to return true when back at 0 to save callers having to test angle's signum again. 2023-02-04 19:01:01 +11:00
Mitchell Richters
cbcc4f7729 - SW: Repair pitch setup for all weapons not accounting for the player's view pitch offset.
* Long-standing omission from back in 0e3604ac9e.
2023-02-04 17:18:47 +11:00
Simon
e28088380f Fix crash in Shadow Warrior when player dies 2023-02-04 17:05:20 +11:00
Mitchell Richters
5fd4fbfde5 - Remove some leftover debug code. 2023-02-04 17:05:20 +11:00
Mitchell Richters
ca4b9c5044 - Slight tidy-up in vectors.h. 2023-02-04 17:05:20 +11:00
Mitchell Richters
30de9c1922 - Factor in view pitch when clamping player's actor pitch. 2023-02-04 17:05:19 +11:00
Mitchell Richters
991ef5c27f - Minor input tidy-up. 2023-02-04 17:05:18 +11:00
Christoph Oelckers
8052bc7e46 - fixed bad vector addition to incorrect variable. 2023-01-29 09:05:35 +01:00