Commit graph

355 commits

Author SHA1 Message Date
NepDisk
911afb22a6 Move freecam state to camera_t
Based on fa89576f34 p1 still controls both cameras for now.
2025-04-01 13:57:27 -04:00
Alug
9587afa23b let postimg stuff also apply to freecam 2025-03-30 10:41:03 -04:00
Alug
7656b519bf fix postimg data types mismatch
also remove the "postimgflag_t" typedef since its useless
and use smoler type for everything we dont need much space lol
2025-03-30 10:38:36 -04:00
Alug
6b1de73341 move postimg flags to camera struct
- also dont let water and heat be applied on top of each other since it does not look good (water postimg takes priority over heat)
- also save a little time in opengl splitscreen since it does not support heat or wöter effects
2025-03-30 10:33:48 -04:00
James R
872b31563d P_DemoCameraMovement: even out vertical angle after toggling
After turning on freecam, the vertical angle is tilted
slightly downward (this is carried over from normal
chasecam).

Interpolate that angle back to normal while moving
forward. This makes it so you don't need to manually
adjust the vertical angle, since it would cause forward
movement to send you into the ground.
2025-03-30 09:02:15 -04:00
James R
c84d9f24fd P_DemoCameraMovement: don't let A button press from menu carry over to rise camera 2025-03-30 09:01:29 -04:00
James R
e0a191f4d5 Replace spectator movement with demo freecam 2025-03-30 08:55:40 -04:00
James R
6531cc065e Fix sound handling in demo freecam
- Object sounds are audible from the location of the
  camera
- Certain HUD sounds should no longer be audible
  - For instance, lap complete sfx
2025-03-30 08:44:56 -04:00
NepDisk
9ca6075a9e Fix thundershield not killing the spb and add DMG_VOLTAGE
Ported the fix from RR since it made the most sense
2025-03-18 01:11:28 -04:00
NepDisk
76ec93f957 Allow Mobjs to waterrun
Waterrunning has been moved over to flag2 MF2_WATERRUN
Applying the flag allows to stand/move on water.
2025-03-17 14:16:44 -04:00
NepDisk
ec6a3d2716 Small turn code refactor 2025-03-07 11:50:10 -05:00
James R
05e926f540 Merge branch 'overlay-offsets' into 'master'
MT_OVERLAY exception flags

See merge request KartKrew/Kart!878
2025-02-27 12:49:23 -05:00
NepDisk
0d4c4a74f6 Merge branch 'blankart-dev' into bortsport 2025-02-22 22:21:09 -05:00
NepDisk
e562d838b5 bumpspark, bumpspring and small code refactoring and cleanup 2025-02-22 21:53:09 -05:00
NepDisk
51154e346c rename tm to g_tm to fix C conflict 2025-02-22 01:24:53 -05:00
toaster
b4dcc12e4f Support for user-specified minimap bounds
The totally-not-a-secret reason I made this branch.
- doomednum 770 (associated with polyobject anchors 760/761 and skybox centerpoint 780)
- Place exactly two in a map to draw an implicit rectangle.
    - Supports top-left/bottom-right AND bottom-left/top-right placements.
    - I_Errors if you place too many (or only one).
- You don't *have* to have these, this is just a bonus if you're a map like Power Plant or CDSS1 negatively affected by your skybox.
2025-02-18 23:48:18 +01:00
toaster
8ed510ca88 Precalculate as much shared minimap/automap data on level load as possible
- `P_InitMinimapInfo`
    - Writes to `p_local.h` extern struct
    - Handles everything previously distributed across multiple K_drawKartMinimapIcon calls (and most of AM_findMinMaxBoundaries)
- Reduces complexity of drawKartMinimapIcon significantly
- Last prerequisite before implementing user-placable minimap boundaries...
2025-02-18 23:48:18 +01:00
NepDisk
122b269601 Step up code shit again 2025-02-12 21:29:47 -05:00
NepDisk
a5f4a85ce0 Implement stplyrnum and refactor K_drawBattleFullscreen to use it
Thanks Saturn and GHG as per usual
2025-02-09 11:58:15 -05:00
GenericHeroGuy
a27f90c717 Fix the elevator in Diamond Square 2025-01-25 00:34:54 +01:00
Sally Coolatta
713ac093bf devmode cheat online 2025-01-10 11:36:04 -05:00
NepDisk
0ee728c1eb Fix speedpad and spring angle updates online 2025-01-09 10:14:21 -05:00
James R
5cb20f5480 P_TryMove: sweep collided lines to find nearest normal 2024-12-25 13:30:59 -05:00
NepDisk
4b1324da69 Remove Battle capsule stuff and turn it into Item Breaker
You have to smash every itembox in a map as fast as you can. When you mash you get a pogospring and waiting gives a sneaker
2024-12-17 00:24:20 -05:00
NepDisk
83fc4e8342 Port some callfuncs from base SRB2 ACS merge
This could be handy for all sorts of stuff
2024-11-25 11:40:20 -05:00
NepDisk
b5c21c8d88 Read-only mapthing_t 2024-10-16 13:11:13 -04:00
toaster
bdc50487b7 thinker_era
A first pass in attempts to fix crashes when ACS causes map changes.
Frustratingly still got a crash, but I think this is definitely the right foundation to work with.
2024-10-15 22:15:30 -04:00
Sally Coolatta
1f6574e9a3 Copy first mapthing tag to their mobjs
Allows the ThingCount and ThingSound ACS functions to fully work now, and adds significantly more possibilities for scripting later.
2024-10-15 15:13:50 -04:00
Eidolon
d08b923f06 Merge branch 'extern-c-everything' into 'master'
Add extern "C" in C++ to all headers

See merge request KartKrew/Kart!842
2024-10-15 14:14:43 -04:00
James R
9e801c66d5 Merge branch 'universal-typedef' into 'master'
Move all typedef into one file

See merge request KartKrew/Kart!791
2024-10-15 04:16:58 -04:00
NepDisk
9d6c643f6c Remove DMG_WUMBO comboing and fix respawn lua value 2024-10-08 21:38:59 -04:00
Sally Coolatta
b21352d8ac 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.

Nep Note: I tried implementing lua support, its probably shit lmao
2024-09-13 11:49:12 -04:00
Sally Coolatta
e4534dcf50 P_RestoreTMStruct 2024-09-13 11:32:41 -04:00
Sally Coolatta
55a8643dd3 Put tm* variables into a struct
This makes it significantly easier to save/restore the state of these variables, whenever we need to do so for calling movement functions in the middle of other movement functions. This will also make it easier to move it out of global variable hell if desired later.
2024-09-13 11:29:30 -04:00
Oni
4c994de722 Merge branch 'loops' into 'master'
Sonic Loops

See merge request KartKrew/Kart!991
2024-09-12 12:10:40 -04:00
toaster
0532cc8484 Remove P_InitAngle and its kin, considered on a case-by-case basis for also setting old_angle as well. 2024-09-04 01:18:51 -04:00
NepDisk
b76c87005b Fix kartspeed in udmf maps and implement spring terrain type 2024-09-03 21:18:12 -04:00
Sally Coolatta
fd4348f5be Don't allow nextwaypoint to be past finish linedef 2024-09-02 05:34:45 -04:00
Sally Coolatta
25a9b5cfa9 Copy first mapthing tag to their mobjs
Allows the ThingCount and ThingSound ACS functions to fully work now, and adds significantly more possibilities for scripting later.
2024-08-22 18:00:14 -04:00
NepDisk
ccfa90677c Merge branch 'v2dev3' into udmf-cherrypick-cherrypick 2024-08-21 22:13:53 -04:00
James R
35a181e0db Let Drop Targets collide with other players immediately after being thrown 2024-08-21 17:20:34 -04:00
Sally Coolatta
0a9f3b452a Make MAXRADIUS bigger
MAXRADIUS was previously an arbitrary value id Software set as whatever their biggest object would be (which they broke that rule anyway). It is now the radius of a blockmap block, which should be a large enough of a nudge value to handle all cases. (Still don't recommend making objects any bigger than a Spider Mastermind though.)
2024-08-21 16:30:33 -04:00
NepDisk
a2fcc4bc20 UDMF cherry-pick cherry-pick 2024-08-20 02:47:00 -04:00
NepDisk
2ace452df6 Stop calling P_NullPrecipThinker
9eab5317f3
2024-08-01 16:00:12 -04:00
James R
ed75d3946d Render precip through blockmap instead of during BSP
There can be very many precipmobjs in a sector. During BSP
rendering, for each sector reached by BSP (the entire
visible level at least), all the precipmobjs would be
iterated and their distance from the camera calculated, to
determine whether they are within draw distance.

The issue with the old approach is that there really are
too many precipmobjs in each sector. By iterating the
blockmap within a certain range instead, precipmobjs
out of view are not iterated at all, saving some time.

Caveat: drawdist_precip is no longer respected as an
exact value, since it must round to the precision of the
blockmap.

List of potentially scary changes:

- Removes snext/sprev for precipmobj_t
- Removes preciplist for sector_t

- Adds bnext/bprev for precipmobj_t
  - mobj_t and precipmobj_t field offsets are symmetrical

- Modified P_SetPrecipitationThingPosition and P_SetThingPosition
  - The syntax in these functions is kind of wacky
2024-08-01 14:56:36 -04:00
Gustaf Alhäll
a047144c4d Cache and reuse removed mobjs when spawning mobjs 2024-08-01 14:21:41 -04:00
NepDisk
ac72e705a6 Reimplement squishing damange 2024-07-31 17:05:16 -04:00
Sal
1d8475a958 Merge branch 'hooklib-port' into 'master'
Hooklib refactor ported and (mostly) squashed

See merge request KartKrew/Kart!662
2024-07-31 02:30:20 -04:00
NepDisk
48871a8b68 Remove tumble. 2024-07-29 03:40:28 -04:00
Sally Coolatta
ebb34ff9d4 Lap based power level 2022-08-14 06:00:37 -04:00