Commit graph

14729 commits

Author SHA1 Message Date
MajorCooke
62f3a1cf08 Added an optional extra float parameter to $pitchshift. (#1150)
- This allows for setting a randomized range for the pitch each time the sound is initialized.
# Conflicts:
#	src/sound/s_sound.cpp
2020-08-28 13:47:09 +02:00
MajorCooke
83f82afbc8 Optimized P_CheckPosition. (#1161)
- If the actor passed into the function has THRUACTORS, PIT_CheckThing won't be called anymore.
- Moved THRUACTORS check to just under the self clipping check in PIT_CheckThing.
2020-08-28 13:46:55 +02:00
Chronos Ouroboros
3ea75a7863 Fixed an incorrect abort message on out of bounds array access. 2020-08-28 13:46:48 +02:00
alexey.lysiuk
643cba776b - added initialization for line and sector portals
Resizing of portal arrays during serialization could lead to processing of junk data

https://forum.zdoom.org/viewtopic.php?t=67494

# Conflicts:
#	src/maploader/specials.cpp
#	src/portal.cpp

# Conflicts:
#	src/portal.h
2020-08-28 13:46:10 +02:00
alexey.lysiuk
36210acc28 - update floor/ceiling for inventory items after traveling
Inventory items had dangling floor and ceiling sector pointers after transition to a new level
This could cause random issues with serialization

https://forum.zdoom.org/viewtopic.php?t=67494
2020-08-28 13:44:41 +02:00
Ed the Bat
83eeaac940 Optional override for SetSlot and ClearPlayerClasses
With this, a decade-long struggle can now be ended.

# Conflicts:
#	src/keysections.cpp
#	wadsrc/static/menudef.txt
2020-08-28 13:42:40 +02:00
drfrag
7416a1d49b - Disable compat_oldrandom for a few more PRNGs just in case. 2020-08-28 13:25:27 +02:00
drfrag
a020070bf0 - Add game load message. 2020-08-24 18:31:31 +02:00
drfrag
0a210ed7f0 - Disable chat for single player, controlled by the chat_self CVAR. 2020-08-24 17:59:51 +02:00
drfrag
a228edf64f - Disable the original Doom PRNG flag for a bunch of named generators. 2020-08-24 17:22:53 +02:00
drfrag
eeef1c2dad - Now base the old PRNG flag on Edward850's implementation but done in reverse.
Also disable it for some generators.
https://forum.zdoom.org/viewtopic.php?f=4&t=47546
2020-08-24 17:06:09 +02:00
drfrag
e002d61823 Revert "Ported the COMPATF2_OLD_RANDOM_GENERATOR compatibility flag from Zandronum".
It made demos and MP games desync.
2020-08-24 16:19:16 +02:00
drfrag
f9bd158211 - Ported the COMPATF2_OLD_RANDOM_GENERATOR compatibility flag from Zandronum and added it to the Doom (Strict) compatibility mode.
Added new compatflag "old random generator", controlled by the new CVAR compat_oldrandom. If this is enabled, the original Doom random table is used to generate random integers in [0,255], which should make for instance the SSG cause a little more damage.
2020-08-24 16:11:07 +02:00
Chronos Ouroboros
0ea4e182c7 Fixed nested structs breaking the ZScript compiler under certain circumstances. 2020-08-15 19:02:58 +02:00
RockstarRaccoonAlt
2c3303e723 Fix obscure error in Animated Doors where the Actor can be NULL
This is a quick fix for an error in which Animated Doors crash the game by trying to check "actor->player" when "actor" itself is NULL.  Deleting the check entirely also worked, but I worried it might be there for some higher-level scripting reason.  This just puts in a check to make sure actor isn't NULL before checking actor->player, and keeps the behavior in that case the same.

I think this was happening because I had doors being opened by projectiles (like in Metroid) which were being despawned into NULL pointers when they hit the doors, as this was an issue when initially programming said doors..
2020-08-15 11:27:45 +02:00
MajorCooke
3d22c635f4 P_BounceActor now calls SpecialMissileHit before any other bouncing effects are processed. Return values are as such: (#1156)
- 1: The missile will continue moving through the actor, and it's down to the modder to handle bouncing.
- 0: The missile will explode.
- Any other value will process a bouncing actor as normally done in the engine.
2020-08-14 12:46:31 +02:00
alexey.lysiuk
a4fe7b6de2 - fixed: UMAPINFO partime was multiplied by ticrate
https://www.doomworld.com/forum/post/2167749
2020-08-03 17:57:30 +02:00
Rachael Alexanderson
3197679114 - demote pwad defcvars error to a warning 2020-08-01 17:31:43 +02:00
Major Cooke
09f5d1b666 Added $PitchSet <logical name> <float> for SNDINFO.
- Sets the direct pitch of the sound to the specific float. Default is 0.0, meaning do not set a specific pitch. Regular pitch is 1.0.
- Only works for direct sound definitions.
- Overrides $PitchShift unless value is <= 0.0
- Overridden by A_StartSound's pitch parameter if the value > 0.0.
2020-07-24 12:42:17 +02:00
Rachael Alexanderson
b9e98889ef - add 'sv_alwaystally' defaults to 0 with the following states:
* 0: previous behavior (completely MAPINFO controlled)
* 1: always show level tally at the end of an episode
* 2: always show level tally even when changing levels within a hub

# Conflicts:
#	src/g_level.cpp
#	src/g_levellocals.h

# Conflicts:
#	src/g_level.cpp
2020-07-21 21:38:00 +02:00
Major Cooke
b9e2063a65 Begin TICRATE conversion.
- Moved TICRATE from Thinker to Object in ZScript so status bars have access to it.

# Conflicts:
#	src/p_effect.h
#	wadsrc/static/zscript/base.zs
2020-07-15 19:03:44 +02:00
drfrag
54482bf165 - Fix compilation with VS 2019? 2020-07-12 12:14:33 +02:00
Marisa Kirisame
b6ee4151ee Optimize UE1 vertex normal computation. 2020-07-12 12:14:30 +02:00
Rachael Alexanderson
de2d564c98 - change recent /0 fix to conform to UDMF specs
# Conflicts:
#	src/playsim/p_spec.cpp
2020-06-25 16:07:20 +02:00
drfrag
cf083f5b56 - Fixed division by zero when damageinterval was not specified from ZScript. 2020-06-25 14:02:29 +02:00
alexey.lysiuk
d3b5e952ba - fixed freeze with StartSlideshow called for undefined intermission
https://forum.zdoom.org/viewtopic.php?t=69079
2020-06-23 20:15:45 +02:00
drfrag
aad005c688 - Don't show the iwad selection box with -iwad. 2020-06-21 15:54:13 +02:00
drfrag
299cd93a3f - LZDoom 3.86. 2020-06-20 18:28:37 +02:00
alexey.lysiuk
da8c452795 - added mixin support to AST output 2020-06-20 16:25:35 +02:00
alexey.lysiuk
f2b1d45985 - fixed leaking full VM frames
https://forum.zdoom.org/viewtopic.php?t=69055
2020-06-20 10:48:32 +02:00
Cacodemon345
a0fee03209 Account for the NOTONAUTOMAP flag when using am_thingrenderstyles 2020-06-20 10:48:21 +02:00
Christoph Oelckers
8eb09a0099 - added missing target check to A_RadiusDamageSelf. 2020-06-19 11:54:03 +02:00
Christoph Oelckers
7706dd65f9 - fixed: AActor::GetModifiedDamage must account for the inventory items to get destroyed in its scripted subfunctions. 2020-06-13 01:49:23 +02:00
drfrag
19183ba157 - Fixed: check for bad sidedefs was not taking into account unused ones.
# Conflicts:
#	src/p_setup.cpp
2020-06-12 19:28:21 +02:00
Christoph Oelckers
68d95befd4 - mapped "Smooth mouse" back to m_filter CVAR and removed smooth_mouse.
The option effectively disables per frame mouse checks.
The motivation to add it was that many wireless mice 10-15 years ago had update rates of less than 35Hz, and on these it was necessary to sync mouse input with the playsim to properly interpolate between updates.
Today this is totally useless and even counterproductive because modern mice have significantly higher update rates, so this option no longer smoothes things but instead makes the mouse feel more choppy.
2020-06-10 13:54:09 +02:00
Christoph Oelckers
555dea3c8a - do not allow playing sounds during PlayerFinishLevel.
This gets called right before the level ends, any sound in here would play during the intermission or at the start of the next level.

# Conflicts:
#	src/sound/s_soundinternal.h
2020-06-09 23:29:26 +02:00
drfrag
d4dba5ed3f - Add fake missing DTA_Desaturate DrawTexture tag. 2020-06-09 19:41:28 +02:00
drfrag
796c25b056 - Add missing DrawTextureTags.
DTA_FlipY, DTA_SrcX, DTA_SrcY, DTA_SrcWidth and DTA_SrcHeight.
2020-06-09 18:42:52 +02:00
nashmuhandes
7d20e74603 Fixed wrong MINDEMOVERSION which was committed in 95f447927a 2020-06-08 15:50:37 +02:00
drfrag
5cd3f66dd2 - Bumped ZScript version. 2020-06-08 14:44:15 +02:00
Marisa Kirisame
4ca8d538b3 Hotfix: LineTrace now reports the correct number of portal crossings. 2020-06-07 15:52:15 +02:00
alexey.lysiuk
c00dddea68 - tighten rules for action functions called from Decorate
FxVMFunctionCall (previously used to call action functions from Decorate) skipped self pointer compatibility checks

https://forum.zdoom.org/viewtopic.php?t=68678
2020-06-07 14:51:48 +02:00
Christoph Oelckers
100897b406 - fixed: The full dotted lump filter string was never used.
The code added all partial matches to the file system but not the full match.

# Conflicts:
#	src/resourcefiles/resourcefile.cpp
2020-06-07 14:35:29 +02:00
alexey.lysiuk
8c877cb36a - fixed (un)morphing of more than one actor from ACS
https://forum.zdoom.org/viewtopic.php?t=68847

# Conflicts:
#	src/p_acs.cpp
2020-06-07 14:35:19 +02:00
alexey.lysiuk
55bbc4a86b - fixed setup of JIT functions that require extra frame space
https://forum.zdoom.org/viewtopic.php?t=68816
2020-06-07 14:35:05 +02:00
Alexander Kromm
d28ba37af2 make various getter and pure-math methods clearscope, and where applicable, const
Original PR: https://github.com/coelckers/gzdoom/pull/532

Status of the original PR

1. Actor
- [already in] deltaangle
- [already in] absangle
- [already in] AngleToVector
- [already in] RotateVector
- [already in] Normalize180
- [already in] BobSin
- [already in] GetDefaultSpeed
- [this PR] GetBobOffset
- [this PR] InStateSequence
- [already in] FindState
- [already in] GetDropItems
- [this PR] DistanceBySpeed
- [this PR] AccuracyFactor
- [not in original PR, for PlayerInfo.isTotallyFrozen] isFrozen

2. PlayerInfo
- [this PR] GetUserName
- [this PR] GetColor
- [this PR] GetDisplayColor
- [this PR] GetColorSet
- [this PR] GetPlayerClassNum
- [this PR] GetSkin
- [this PR] GetNeverSwitch
- [this PR] GetGender
- [this PR] GetTeam
- [this PR] GetAutoaim
- [this PR] GetNoAutostartMap
- [this PR] GetClassicFlight
- [this PR] IsTotallyFrozen

3. C++ methods, to match ZScript:

- [scriptified] AActor::AccuracyFactor() to Actor.AccuracyFactor
- [this PR] AActor::DistanceBySpeed(AActor *, double) — it is a combination of getter and pure math
- [this PR] AActor::Distance2D(AActor *, bool) — called by DistanceBySpeed
- [this PR] AActor::Distance2D(AActor *, double, double, bool) — called by DistanceBySpeed
- [not in original PR, for PlayerInfo.isTotallyFrozen] AActor::isFrozen

# Conflicts:
#	src/actor.h
#	src/actorinlines.h
2020-06-07 14:34:48 +02:00
Christoph Oelckers
3106b46481 - advanced coordinate control for overlays over DTA_Fullscreen images.
Manually merged, there were severe conflicts.

# Conflicts:
#	src/textures/textures.h
#	src/v_draw.cpp
#	src/v_video.h
2020-06-07 14:15:59 +02:00
Christoph Oelckers
bbceaa1fcb - added limited support for replacing the intermission backgrounds in Doom 1 with widescreen images.
Due to how the placement works here, it is only usable with fullscreenautoaspect mode 3.

# Conflicts:
#	src/wi_stuff.cpp
2020-06-07 13:28:12 +02:00
Christoph Oelckers
17add7f47f - don't let CHANF_AUTO hijack other channels.
With CHANF_OVERLAP this isn't needed anymore - any sound started on CHAN_AUTO can actually play on this channel with overlap implicitly allowed.
This has the added advantage that these sounds can be reliably accessed with other function by using CHAN_AUTO.

# Conflicts:
#	src/v_2ddrawer.cpp
2020-06-07 13:27:02 +02:00
Christoph Oelckers
af10281799 - fixed some double to float conversion warnings. 2020-06-04 10:50:36 +02:00
Christoph Oelckers
8ec5a4616b - fixed: vertically mirrored textures should not be subjected to empty space optimizations because the algorithm cannot deal with the inverted case.
# Conflicts:
#	src/gl/scene/gl_wall.h
2020-06-04 01:52:21 +02:00
Christoph Oelckers
30327ffa4f - fixed: the 3D floor processing code in the renderer did not restore the render style after finishing.
Normally this won't be noticable, the only exception is if the last processed 3D floor had additive translucency and colored fog - this case is special because for additive rendering the fog color needs to be disabled.

# Conflicts:
#	src/gl/scene/gl_walls.cpp
2020-06-04 01:46:14 +02:00
Edoardo Prezioso
09fbbfb1c6 - Fixed OpenAL regression with looping sounds with playing length 0.
If such case occurs, the starttime parameter passed to the sound functions is ignored and truncated to 0.
2020-06-03 17:08:47 +02:00
Christoph Oelckers
55390b2403 - fixed floorclipping checks for 3D floors.
Neither the setup nor the in-game checks were correct, because this code comes from a time where ceilings could not have a terrain, meaning that 3D floors couldn't have one.
2020-06-03 11:23:30 +02:00
Christoph Oelckers
b43d87c4cd - reject all 0-special lines for activation.
This is to ensure consistency between all callers of this function.
2020-06-03 00:07:25 +02:00
Christoph Oelckers
d8db13a539 - use modulo, not bitwise and-ing to check the damage delay for terrain based damage.
This was apparently overlooked when refactoring the damage system 4 years ago.
2020-06-03 00:07:23 +02:00
drfrag
524d8ee524 - Present the iwad selection box also with only one iwad. 2020-06-02 16:38:33 +02:00
Hugo Locurcio
03c9906b55 Add a cvar to control weapon bobbing while firing
This simulates a feature found in Crispy Doom, which keeps the
weapon bobbing while firing. This leads to a "smoother" appearance
which may look a bit prettier to some people.

The default value of 0 preserves the old behavior.
2020-06-01 10:39:09 +02:00
drfrag
0ec9af91a9 - Fixed crash printing weapon name tags. 2020-05-31 16:41:01 +02:00
drfrag
a05df40a6e - Fixed crash on maps with out of range sidedef and sector numbers, adapted from PRBoom.
# Conflicts:
#	src/p_setup.cpp
2020-05-29 23:50:49 +02:00
drfrag
98de1423ea - Reload fake fonts, people keep doing it and that made some mods incompatible. 2020-05-27 23:41:38 +02:00
Christoph Oelckers
42b037d708 - fixed: TRF_ALLACTORS did not consider actors without any flag being set. 2020-05-26 00:30:11 +02:00
Christoph Oelckers
8c9cf5234a - fixed missing sound for Polyobj_MoveTo. 2020-05-26 00:30:05 +02:00
Marisa Kirisame
be13bbb9a2 Add mapinfo option to disable merging of identical pickup messages on same tic
# Conflicts:
#	src/g_inventory/a_pickups.cpp
2020-05-24 11:04:20 +02:00
alexey.lysiuk
c386a71c3c - added #include to fix compilation with MSVC 16.6.0
https://forum.zdoom.org/viewtopic.php?t=68641

# Conflicts:
#	src/files_decompress.cpp
#	src/sound/s_music.cpp
2020-05-22 21:35:55 +02:00
Alexander Kromm
a8282c3ec6 fix "'ictionary' is freed outside the GC process" warning 2020-05-22 21:35:51 +02:00
alexey.lysiuk
898860eebf - fixed erroneous removal of property flag members
https://forum.zdoom.org/viewtopic.php?t=63520
2020-05-17 02:10:10 +02:00
Rachael Alexanderson
f477a1aa47 - force player respawn to call up the player's default class settings before determining where to respawn the player
# Conflicts:
#	src/g_levellocals.h
#	src/p_mobj.cpp
2020-05-08 14:52:58 +02:00
Mekboss
b658d4c225 Fix MSVS compile bug and add offset parameter for SprayDecal
# Conflicts:
#	src/g_shared/a_sharedglobal.h
2020-05-08 14:52:56 +02:00
Mekboss
6e30ac5f3c Replace function variables to DVector3
# Conflicts:
#	src/g_shared/a_sharedglobal.h
2020-05-08 14:52:53 +02:00
Mekboss
bfe367fb20 Add optional direction parameters for SprayDecal and its A_SprayDecal zscript counterpart
# Conflicts:
#	src/g_shared/a_sharedglobal.h
2020-05-08 14:52:51 +02:00
Cacodemon345
19b125ca3a Fix bouncing missiles not dealing damage when hitting top/bottom (#1068)
* Fix bouncing missiles not dealing damage when hitting top/bottom
2020-04-30 11:45:45 +02:00
arookas
dec6a03caf Add option to invert mouse x 2020-04-30 11:45:43 +02:00
Christoph Oelckers
ae882d983a - fixed ZScript compiler crash with dereferencing null pointers 2020-04-30 11:45:37 +02:00
PaulyB
df1e469163 Properly namespaced UDMF flag 2020-04-28 02:23:07 +02:00
PaulyB
acdf18bc75 Exposed MTF_NOCOUNT to UDMF 2020-04-28 02:23:05 +02:00
PaulyB
e59fe8e01f Added MTF_NOCOUNT to spawn flags 2020-04-28 02:22:44 +02:00
drfrag
0d8d51f0b4 - Bump LASTRUNVERSION for defcvars. Missed this. 2020-04-23 14:03:13 +02:00
alexey.lysiuk
1e9f0700f0 - added validation of game skill when changing a level 2020-04-20 12:47:24 +02:00
alexey.lysiuk
c6514e4438 - fixed potential crash on intermission cast screen 2020-04-20 12:47:23 +02:00
Christoph Oelckers
411b287cd9 - block off the Substitute function by making it private to the 3 classes that really need it. 2020-04-19 21:39:25 +02:00
Christoph Oelckers
11106a08b5 - relax pointer substitution restriction for morphed monsters.
# Conflicts:
#	src/p_mobj.cpp
2020-04-19 21:39:23 +02:00
Christoph Oelckers
896e4f6d6a - let TeleportSpecial universally map to Teleport when checking action special names. 2020-04-19 19:50:30 +02:00
Christoph Oelckers
27aa39fb59 - apply aspect ratio compensation for all fullscreen images with a height of 200 and 400, and not just to 320x200 and 640x400. 2020-04-19 16:13:53 +02:00
Christoph Oelckers
c7a41eb73d - fixed incorrect value range for particle's depth value, used for sorting.
# Conflicts:
#	src/hwrenderer/scene/hw_sprites.cpp
2020-04-19 16:12:33 +02:00
Christoph Oelckers
a953578484 - made 3D floor damage transfers optional by adding a new flag bit (2048) and made that mode automatic for the old ZDoom-based light only transfer special.
# Conflicts:
#	src/maploader/specials.cpp
2020-04-19 15:18:54 +02:00
Christoph Oelckers
9ca1e43292 - fixed text size calculations in the status bar.
To avoid errors, all spacing calculations have been added to FFont::StringWidth which already performs proper escape filtering.

# Conflicts:
#	src/common/fonts/font.cpp
2020-04-17 01:17:42 +02:00
Christoph Oelckers
086327666f - fixed: Setting 'noallies' on the level cleared the player's friendly flag.
The check was for mobj->player, which at this point wasn't set yet so the check failed.

# Conflicts:
#	src/p_mobj.cpp
2020-04-17 01:17:40 +02:00
Blue
86927074c9 Added $OPTVAL_MBFSTRICT to menudef.txt, and added corresponding case 7 to the compatmode cvar in d_main.cpp 2020-04-08 23:32:40 +02:00
Magnus Norddahl
7d4603f4c1 Revert "- Fix legacy input state getting out of sync when raw mouse input grabs or releases the events"
This reverts commit b4424b2d4d.
2020-04-08 23:32:38 +02:00
drfrag
6d3fc6b38a - Clarify error message. 2020-04-06 11:21:54 +02:00
drfrag
7b66bdf35c - Add hint on error for some Intel cards. 2020-04-04 20:09:33 +02:00
drfrag
0669a3f589 Revert "- Change OS type for stats, but that code is disabled and outdated anyway."
This reverts commit 7bc2983ecc.

Revert "- Removed Win 10 compatibility from the manifest to address a bug in old intel drivers."

This reverts commit 007576416c.
2020-04-04 19:20:38 +02:00
drfrag
6dffeea88c - Add fake vid_rendermode CVAR. 2020-04-04 18:34:57 +02:00
drfrag
7bc2983ecc - Change OS type for stats, but that code is disabled and outdated anyway. 2020-03-30 21:26:36 +02:00
drfrag
007576416c - Removed Win 10 compatibility from the manifest to address a bug in old intel drivers. 2020-03-30 18:56:12 +02:00
Major Cooke
7b2b7325ab - Fixed: SPECTRAL flag didn't check for DMG_FORCED before aborting DamageMobj. 2020-03-30 13:00:13 +02:00
Magnus Norddahl
69f50e2056 - Fix legacy input state getting out of sync when raw mouse input grabs or releases the events
- Remove the need to center the mouse by specifying RIDEV_INPUTSINK (RIDEV_CAPTUREMOUSE does not take effect unless it is also an input sink)
2020-03-29 13:04:03 +02:00
Christoph Oelckers
9b5b6342ce - There's really no need anymore to dynamically load RawInput, considering it has been in Windows since XP.
# Conflicts:
#	src/win32/i_keyboard.cpp
#	src/win32/i_mouse.cpp
2020-03-29 13:03:49 +02:00
drfrag
efe87adcf2 - Fix compilation on Linux. 2020-03-25 15:54:48 +01:00