Commit graph

947 commits

Author SHA1 Message Date
Lach
2d7ae88586 Hardcode MT_BOOSTPAD as MT_SNEAKERPANEL 2023-07-21 19:19:28 +10:00
toaster
f9e11be98a UDMF upscaled springs: Treat as an increased hitbox only, not as a strength multiplier 2023-07-19 21:27:58 +01:00
SteelT
41ca397881 Don't thrust player if the UFO is dead 2023-06-29 22:21:59 -07:00
SteelT
c836d27448 Thrust player if they are under the UFO 2023-06-29 22:21:24 -07:00
Sal
7b98752b67 Merge branch 'refactor-mapthing' into 'master'
Read-only mapthing_t

See merge request KartKrew/Kart!1252
2023-06-14 00:07:42 +00:00
Sally Coolatta
9d80323a3a Read-only mapthing_t
Map things are writeable in Lua, which I am pretty certain is a mistake because mapthings are not sent over the network at all. I considered making them net-synced (it would be relatively easy), but it also aligns with another, more "philosophical" issue: Doom generally copies over properties from mapthing_t into mobj_t, and then only refers to it again when needing to respawn an object -- mapthing_t is not really intended to be referred to very often at runtime. At best it's slightly annoying since some objects rely on a spawnpoint for behavior changes, at worst it may make ACS more confusing in the future since Thing and Mobj tags are mixed together or less useful since they wouldn't be able to modify behaviors of objects that are based on args.

So I decided to solve these two issues at the same time; just treat mapthing_t as something to copy values from, like OG Doom does it. This basically just means that special and args are also part of the mobj now instead of the mapthing, which should fill any desire to edit this stuff from Lua, and reduces the number of instances where objects need to check for their spawnpoint to function properly.
2023-05-25 14:40:55 -04:00
AJ Martinez
df6c9cee73 Instashield: actually do height checks 2023-05-19 15:34:54 -07:00
AJ Martinez
18c45d8a8a WIP: Insta-"whip" 2023-05-16 23:36:38 -07:00
Sally Coolatta
6fa821b2d3 Local P_LineOpening result + traversal leniency
P_LineOpening results are stored in a locally made struct instead of being a bunch of disorganized globals.

Waypoint traversals can go thru 1 line, if it was blocked by step-up rules, for free, similar concept to sound-blocking lines in Doom.
2023-05-13 00:39:36 -04:00
Sally Coolatta
0ec5c4346b Fix Block Players for waypoint detection 2023-05-07 14:34:03 -04:00
toaster
2f63669385 P_CheckPosition: If thing was removed in its remit and iteration has MF_NOCLIP, do not return true
This fixes increment_move in the case of Lightning shield pop
2023-04-14 14:38:32 +01:00
James R
1f70b9c63c Merge remote-tracking branch 'origin/bumpers-ARE-health' 2023-03-13 00:51:44 -07:00
James R
f19de81dd2 Merge branch 'fix-eggman-transfer-crash' into 'master'
Fix null ref in eggman transfer

See merge request KartKrew/Kart!1031
2023-03-09 07:56:22 +00:00
VelocitOni
23b04832ad Buff Spikes
Both Vertical and Wallspikes size and increase, vertical spikes tumble, speed is now TICRATE instead of 2*TICRATE
2023-03-08 22:02:24 -05:00
James R
700331fdd6 Drop Targets collide with Battle Monitors and Break the Capsules
Doesn't alter Capsule's path along its waypoints. I think
the interaction with capsules is funny even if it wouldn't
happen normally.
2023-03-08 19:01:02 -08:00
AJ Martinez
d8670bae20 Fix nonfunctional wizard guard for wizards 2023-03-08 16:58:15 -07:00
AJ Martinez
6d983852d9 Fix null ref in eggman transfer 2023-03-08 15:58:56 -07:00
James R
a3c64068e6 Replace bumpers completely with health
Adds some functions:

- K_Bumpers, bumper count for the count, intended for
  where player->bumpers was used in HUD and visual
  contexts.
- K_BumpersToHealth, converts bumper count to health
  points.

player->mo->health replaces player->bumpers where it was
used in health contexts.

Removes some functions:

- K_HandleBumperChanges
- K_DestroyBumpers

Everything K_HandleBumperChanges did has either been
removed or moved elsewhere. P_KillMobj also already called
K_CheckBumpers.

K_DestroyBumpers became pointless after player->bumpers
was removed.
2023-03-07 22:54:33 -08:00
toaster
e11738b481 Merge branch 'droptarget-collide-plus' into 'master'
More fun with Drop Target punting

See merge request KartKrew/Kart!995
2023-03-02 13:34:02 +00:00
James R
7a8a377d93 Bubble reflect Drop Targets 2023-03-01 09:03:04 -08:00
James R
b2268157fd Fix type check for Land Mines vs Drop Target/Bubble Shield expand
Fixes Drop Targets not pushing Land Mines.
2023-03-01 08:21:30 -08:00
James R
b3511a9149 Player orbiting physics 2023-02-28 20:27:11 -08:00
AJ Martinez
00aa69ca0a Buff eggbox speed, allow contact transfers 2023-02-21 23:00:56 -07:00
James R
5cce81f4cd Add fuse to Pogo Spring
15 seconds, flickers for the last second.
2023-02-18 16:09:05 -08:00
James R
b8a41fa509 Fix negative reference counting in P_RestoreTMStruct
This fixes some thinkers never being removed due to having
negative reference counts.

And here's a breakdown of why the old code could produce
negative reference counts:

Consider P_CheckPosition. This function calls P_SetTarget
on tm.thing but does not call P_RestoreTMStruct. This
means that tm.thing will not be NULL the next P_SetTarget
is called on it. What are the implications of this?
Consider the following series of events:

- P_CheckPosition is called, tm.thing != NULL afterward
- Another function saves the tm struct and sets tm.thing to a different mobj
- - the old tm.thing will have its references decremented
- - the new tm.thing will have its references incremented
- This function calls P_RestoreTMStruct

What should happen when P_RestoreTMStruct is called? The
*new* tm.thing should have its references *decremented*
and the *old* tm.thing should its references
*incremented*, of course, for symmetry with P_SetTarget.

The old code correctly decremented new tm.thing's
references but did not increment old tm.thing's
references.
2023-02-14 04:17:04 -08:00
Sally Coolatta
1caf255f5c Merge branch 'master' into acs 2023-01-05 22:23:51 -05:00
James R
3491bd0b1d Add Battle monitors
- Includes a struct definition for symmetrical objects
made out of papersprite sides.
- Dimensions of papersprite sides are looked up using
sprite cache.

- Monitors may contain multiple types of items.
- Item RNG is deterministic from the time the monitor is
spawned but the item types are not stored in memory.
Instead the RNG seed is restored every time an item type
needs to be determined. Item types need to be determined
every time the icon on the monitor's screen changes and
when the monitor is popped and drops all its items.
- Monitors sparkle like emeralds if there is an emerald
inside.

- Monitors take damage from players simply bumping into
them. The damage scales up with speed and weight.
- Activating a lightning shield in proximity decimates the
monitor into being able to be destroyed in one hit by
anything thereafter.
- All throwable / deployable items destroy a monitor in
one hit.
2023-01-03 05:31:30 -08:00
Sally Coolatta
d5155e3d83 Add Hexen line activation flags
- Lines can be set to activate when crossing or bumping into them, with distinctions for players, enemies, and missiles+items.
- A new flag has been added to determine if a line special can activate more than once.
- Finish Line + Respawn Line are now handled like other specials. This means that:
    - They follow the new line activation rules (so you can potentially have a finish line that you have to bump instead of cross)
    - More importantly, they can be called as functions in ACS. (Player_FinishLine and Player_Respawn)
- Fixed linedef flags not being saved in save games.
2022-12-31 13:41:17 -05:00
Sally Coolatta
82df346417 Merge branch 'master' into special-stages 2022-12-22 05:18:56 -05:00
Oni
7af133d378 Merge branch 'spring-overflow' into 'master'
Fix spring stack overflow

Closes #377

See merge request KartKrew/Kart!831
2022-12-22 07:43:39 +00:00
Oni
58c4f6009f Merge branch 'noclip-isnt-noclipthing' into 'master'
Alter MF_NOCLIP behavior

See merge request KartKrew/Kart!829
2022-12-22 07:25:54 +00:00
Sally Coolatta
0d8e13e942 Fix spring stack overflow
Closes #377
2022-12-22 01:35:08 -05:00
Sally Coolatta
9d350c64c8 Allow SPB to attack the UFO properly 2022-12-19 04:49:53 -05:00
Sally Coolatta
b0598c2182 Merge branch 'noclip-isnt-noclipthing' into special-stages 2022-12-19 04:45:51 -05:00
Sally Coolatta
65e6e54e7d Alter MF_NOCLIP behavior
- Things with MF_NOCLIP can still run code when touching things, but won't be blocked by them.
- Things need both (MF_NOCLIP|MF_NOCLIPTHING) to do a single movement step, since MF_NOCLIP can do thing collision now.
2022-12-19 04:39:46 -05:00
Sally Coolatta
e959ff954c Merge branch 'master' into capsules-improvement 2022-12-19 03:27:13 -05:00
Sally Coolatta
85604cfd2e Merge branch 'master' into special-stages 2022-12-19 01:53:41 -05:00
Sally Coolatta
a7ff0afc8b Merge branch 'master' into capsules-improvement 2022-12-19 01:12:07 -05:00
James R
8d39f0e60f Add springStrength and springStarColor to TERRAIN 2022-12-18 21:09:29 -08:00
James R
4281adc60d Separate most of P_DoSpring into P_DoSpringEx 2022-12-18 21:09:29 -08:00
James R
12052a48de Fix spring stars not spawning for upside down vertical springs 2022-12-17 20:09:23 -08:00
Sally Coolatta
a524422071 First pass on UFO visuals 2022-12-15 23:17:38 -05:00
Sally Coolatta
eab34651bf Sneakers deal contact damage to the UFO 2022-12-15 23:16:27 -05:00
VelocitOni
c5372f4ce3 Merge branch 'master' into capsules-improvement 2022-12-14 23:19:34 -05:00
Sally Coolatta
b62ed33655 Fix Battle mode Egg Capsules bumping
Old vanilla-ass code for platform-like objects that is conflicting super hard with bumping / horizontal momentum. If we ever have a moving platform object this code should be brought back only for that object, and not solid objects as a whole.
2022-12-02 03:56:15 -05:00
Sally Coolatta
81cefa2697 Gachabom initial pass
They simply use Kitchen Sink's item icon and Orbinaut's sprites.

The forward toss behavior needs fine-tuning to use more MT_BANANA style behavior.
2022-11-28 02:41:42 -05:00
Sally Coolatta
e331910fe3 Reduce VFX toggle
Can be used to disable VFX, so it can only appear if its owner is a display player. If no owner is provided, then it will be removed entirely.

Applied to most things that Ivo asked for
2022-11-26 20:12:00 -05:00
Sally Coolatta
c41f231de0 No reference count for TryMoveResult_t 2022-11-21 16:12:53 -05:00
Sally Coolatta
8f5e0f63e9 Evict the wall gremlin
Gremlins happened whenever P_TryMove and P_SlideMove/P_BounceMove disagreed on what an object collided with. When TryMove said you collided with a line, but P_BounceMove said that you didn't, then you'd get gremlin'd.

To fix this, P_TryMove now can edit a struct to contain information on what it collides with. P_SlideMove and P_BounceMove no longer try to detect walls on their own and now requires this result from P_TryMove. If a slide/bounce is needed without moving the object, then you'd want to use P_CheckMove to get the result.

Lua is not supported right now.
2022-11-21 16:12:53 -05:00
Sally Coolatta
35f1fe580c P_RestoreTMStruct 2022-11-21 15:59:19 -05:00