Commit Graph

548 Commits

Author SHA1 Message Date
Major Cooke ec14dd94a7 A_Explode now returns the number of actors damaged and can be used in expressions.
- Enemies that do not take damage in any way are not counted.
2016-08-12 09:17:20 +02:00
Christoph Oelckers b4e712ab01 - made disabling the push window check a real compatibility option.
No idea why this was a hidden one, this one definitely needs to be in the menu.

- set some required compatibility options for Super Sonic Doom.
2016-08-09 20:15:13 +02:00
yqco b2a6512981 Fix partial initialization in ACS PickActor function 2016-08-09 02:11:13 -06:00
Christoph Oelckers ab837b608d - compatibility optioned triggering sector actions by indirectly initiated teleports
There's several old maps depending on this not happening.

- Set the option for Hell's Twisted Influence Part 1.
2016-08-07 22:04:16 +02:00
alexey.lysiuk cbe0a34f0b Fixed usages of abs() function with double arguments
Clang no longer issues "warning: using integer absolute value function 'abs' when argument is of floating point type"
2016-07-30 14:03:57 +02:00
yqco 4d6532d303 Added RGF_NORANDOMPUFFZ flag for A_CustomRailgun and A_RailAttack 2016-07-22 02:46:41 -06:00
MajorCooke 02064437c5 Fixed wrong angle/slopes being used and one too many &s for NOINTERACT. 2016-07-16 17:34:17 +02:00
MajorCooke 10fabc3ab7 Cleaned up code. Puffs no longer need ALWAYSPUFF.
- A_CustomBulletAttack and A_FireBullets will perform a second P_LineAttack to get a puff which only returns to the previous function after a tracer.
2016-07-16 17:34:17 +02:00
Christoph Oelckers b81876698f - changed P_ChangeSector so that for bridges it only keeps the floorz and ceilingz of the spawn position.
This is necessary to prevent moving sectors from altering the bridge's z-position. The bridge should remain at its current z, even if the sector change would cause floorz or ceilingz to be changed in a way that would make P_ZMovement adjust the bridge.
2016-07-04 22:36:27 +02:00
MajorCooke 2d4eb8dde4 - Added limit parameter to A_RailAttack and A_CustomRailgun. 2016-06-14 18:20:43 -05:00
MajorCooke 33ddbe8ab3 Added SKYEXPLODE support for P_LineAttack on horizons. 2016-05-29 12:38:37 +02:00
Christoph Oelckers 49234b1fc3 - fixed: UpdateRenderSectorList did some bad calculations for checking portal plane order. 2016-05-24 13:53:29 +02:00
Christoph Oelckers 428bd52295 - fixed: It was not possible to step through a ceiling portal into the upper sector. 2016-05-20 13:10:42 +02:00
Christoph Oelckers 6949afc334 - fixed: For allowing an unblocking move, PIT_CheckThing used the wrong actor's position. This was causing monster pile-ups with moving ceilings.
- don't let P_PushUp move any actors with the same z as the pushing actor. This should solve most monster pile-ups, but the entire logic here needs some serious rethinking. The only reason this doesn't cause more problems is some fudging in several other places.
2016-05-14 15:05:06 +02:00
MajorCooke 952219a018 Added RTF_THRUSTZ for A_RadiusThrust.
- Allows thrusting with Z velocity.
2016-05-11 19:41:33 +02:00
Christoph Oelckers 852ed6cd04 - un-revert P_CheckMove fix. 2016-05-11 19:39:08 +02:00
Christoph Oelckers d4b258f15b - don't place the chasecam right at the hit position of the trace. This will be the intersection with a wall or sector plane and may cause clipping issues. Instead place it very slightly in front of the actual hit position. 2016-05-11 13:57:49 +02:00
Christoph Oelckers 220255e6a4 - fixed P_CheckMove's dropoff check and removed some unneeded code. 2016-05-11 11:56:03 +02:00
Christoph Oelckers cc88130362 - fixed: P_CheckMove's dropoff check had the heights swapped. This also shouldn't in any way depend on COMPATF_DROPOFF and must be skipped entirely for actors with either MF_FLOAT or MF_DROPOFF set. 2016-05-11 10:09:13 +02:00
Christoph Oelckers 8309d8f634 - fixed coordinate typo. 2016-04-29 23:14:04 +02:00
MajorCooke 660aff562d - Added support for THRU flags on bullets and rails.
- ALLOWTHRUFLAGS must be used on the puffs, added for the sake of compatibility with older mods. This applies to the following:
-- Bullets: THRUACTORS, THRUSPECIES
-- Rails: Same as bullets, but includes THRUGHOST.
2016-04-27 13:38:27 +02:00
Christoph Oelckers 934b1923d0 - fixed: CheckForPushSpecial did not check blocking 3D midtextures. 2016-04-27 12:37:38 +02:00
Christoph Oelckers 044bf4ada6 - fixed: P_CheckPosition must initialized tm.floorterrain. 2016-04-27 12:08:22 +02:00
Christoph Oelckers fab38d092b - fixed: P_LineOpening could miss a 3D floor if an actor was centered right against its side.
- restored the original 3D floor code to retrieve the current floor in P_CheckPosition. The portal aware version was a bit too strict and could place the actor on the wrong side when moving at high speeds.
2016-04-27 02:13:35 +02:00
MajorCooke 6bba84458c - Rail spawned actor trails now set their targets to the shooter and transfer pitch. 2016-04-23 08:19:59 -05:00
Christoph Oelckers 382a6e8b9f - link actors to touching line portals, for use by the renderer. 2016-04-21 22:59:07 +02:00
Christoph Oelckers ba7260c176 - fixed overflow issue with large damage values in P_RadiusAttack. 2016-04-21 10:51:41 +02:00
Christoph Oelckers 322b9fc0ae - wrap access to portal properties into sector_t:: member functions. 2016-04-19 11:35:28 +02:00
Christoph Oelckers 2661a94fe9 - call UpdateSectorRenderList from LinkToWorld as well, because this can be called from outside the actor's Tick function. 2016-04-18 01:35:37 +02:00
Christoph Oelckers 89b2cc45a2 - reverted P_CreateSecNodes to the regular FBlockLinesIterator.
This got accidentally committed. Even if this gets extended to reach through portals it needs to be done differently. FMultiBlockLinesIterator can't guarantee to get every sector that's being touched.
2016-04-18 00:02:07 +02:00
Christoph Oelckers 54d78df267 - added a new sector list to AActor that collects all portal-linked sectors the actor's center is in. (Inspired by Eternity's solution to the same problem.)
This is for rendering the sprite properly in all areas the actor touches. The original thinglist is not sufficient for this and Boom's touching thinglist has other purposes and collects too much data.
This new list will only get filled in when the actor is actually crossing a portal plane, for the normal sector thinglist will still be used.
This piggybacks on the msecnode_t code which has been extended to be able to handle more than one list by passing the sector's membert pointers as parameters.
2016-04-17 23:48:04 +02:00
Christoph Oelckers 7ac0cfbbb9 - added support for angle changing portals to P_AimCamera. 2016-04-16 22:54:47 +02:00
Christoph Oelckers 0f6a567055 - added portal-awareness to the railgun trail.
This required some changes to the Trace function because it turned out that the original was incapable of collecting the required information:

* actors are now also linked into blockmap blocks on both sides if they occupy the boundary of a sector portal.
* Trace will no longer set up parallel traces in all parts connected with sector portal, but only use one trace and relocate that on the actual boundary.
2016-04-16 19:41:33 +02:00
Christoph Oelckers ae6df617ba - fixed: The FPathTraverse call in P_UsePuzzleItem was missing the PT_DELTA flag. 2016-04-11 22:10:46 +02:00
Christoph Oelckers db86385cf6 - removed STACK_ARGS.
The only reason this even existed was that ZDoom's original VC projects used __fastcall. The CMake generated project do not, they stick to __cdecl.
Since no performance gain can be seen by using __fastcall the best course of action is to just remove all traces of it from the source and forget that it ever existed.
2016-04-11 10:46:30 +02:00
MajorCooke 76f00131ff - Fixed: A_CheckBlock's dropoff check ignored the specifications of NOACTORS and NOLINES due to P_CheckMove blindly failing if P_CheckPosition failed. This lead to false positives such as blocking actors being detected when they shouldn't be. 2016-04-10 20:11:04 +02:00
MajorCooke c79a1b6a45 thing->floorz --> thing->dropoffz 2016-04-09 22:33:55 +02:00
MajorCooke 8b8c879994 - CBF_DROPOFF Fixes
- Fixed: CBF_DROPOFF didn't actually check the coordinates passed to it for dropoff height values. It only checked to see if it was stuck in lines.
2016-04-09 22:33:54 +02:00
Christoph Oelckers ca317a87ea - started working on tracking portal transitions for railgun shots. 2016-04-09 12:09:06 +02:00
Christoph Oelckers 47e20aead4 - disallow crossable portals on one-sided linedefs which do not belong to a polyobject.
Sadly the mappers cannot be trusted to use a feature correctly. Despite repeatedly telling that portals on one-sided lines are problematic, everybody seems to do it this way - and then report bugs if it doesn't work. Under such circumstances the only safe option is to block such portals entirely.

See http://forum.zdoom.org/viewtopic.php?f=2&t=51511&p=898522#p898522 for a typical example of the problems this might cause.
2016-04-07 17:13:56 +02:00
Christoph Oelckers a1c03c9a62 - fixed: P_AimCamera inverted the pitch. 2016-04-07 12:44:46 +02:00
Christoph Oelckers 2dff6a08d1 - fixed: P_RadiusAttack passed the wrong radius value to the BlockThingsIterator. 2016-04-04 16:51:25 +02:00
Christoph Oelckers 7586320038 Merge branch 'master' into floatcvt
# Conflicts:
#	src/p_map.cpp
2016-04-04 14:19:34 +02:00
Christoph Oelckers c346ac6143 - fixed: P_TeleportMove must clear the spechits array.
This was accidentally deleted during one round of portal refactoring but is essential to prevent multiple teleport activations in one move.
Fixing this also allowed removing the fudging that was added to work around the issue in P_TryMove.
2016-04-04 14:17:34 +02:00
Christoph Oelckers fd27c8db9e Merge branch 'master' into floatcvt
# Conflicts:
#	src/dobjtype.cpp
#	src/dobjtype.h
#	src/version.h
2016-04-04 01:21:24 +02:00
Christoph Oelckers 1011e26eb9 - fixed: P_RadiusAttack should not call P_DamageMobj for a damage value of 0.
This could happen if the damage calculations resulted in a value between 0 and 1, which for the actual check was multiplied with the damage parameter of P_RadiusAttack which inflated the fractional value to something that looked like actual damage but was later truncated.
2016-04-03 22:45:54 +02:00
Christoph Oelckers 4e5ba49aca - got rid of secplane_t::fA and fB. All uses could be replaced by other functions. 2016-04-03 19:46:00 +02:00
Edoardo Prezioso 28ac65b25b - Fixed GCC and Clang compilation errors. 2016-04-02 23:01:32 +02:00
Christoph Oelckers b3659305ce - fixed typo in line portal interpolation path calculation. 2016-04-02 20:10:32 +02:00
Christoph Oelckers 6445615b5d - fixed the sound location calculations which got somewhat broken by the constant changes during the conversion. 2016-03-31 21:13:32 +02:00