Commit graph

21226 commits

Author SHA1 Message Date
Eidolon
ac7ca10061 cmake: Separate cpm xmp-lite setup 2023-01-04 17:30:45 -06:00
Eidolon
181a159f33 Merge branch 'new-audio-mixer' into 'master'
New Audio Mixer

See merge request KartKrew/Kart!847
2023-01-04 22:52:50 +00:00
Eidolon
b95fd459b9 cmake: Remove SDL2_mixer and OpenMPT
Libraries superceded by libxmp-lite and new mixer.
2023-01-04 16:51:12 -06:00
Eidolon
8c259487b2 audio: Add pure-ISO C++17 audio mixer and backend
This replaces SDL2_mixer.
2023-01-04 16:51:12 -06:00
Eidolon
ba109d8981 core: Catch and I_Error uncaught exceptions in main 2023-01-04 16:51:12 -06:00
Eidolon
9806df5883 cmake: Add stb-vorbis
This is a lightweight single-file Ogg Vorbis decoder which will be used
for Ogg playback instead of libogg/libvorbis.
2023-01-04 16:51:12 -06:00
Eidolon
210b513c8b cmake: Add xmp-lite
This is a very lightweight module playback engine which will replace
OpenMPT.
2023-01-04 16:51:12 -06:00
Eidolon
25e3b4239c io: Allow span and vec stream to seek past end 2023-01-04 16:51:12 -06:00
Eidolon
2a0e183340 legal: Add copyright notice to io/streams 2023-01-04 16:51:12 -06:00
toaster
91a4026871 Remove now-unused definition for challengesbordercolor 2023-01-04 18:04:38 +00:00
toaster
c628014c47 Add an extra guard for unlock condition string drawing to prevent hypothetical out of bounds read 2023-01-04 17:52:28 +00:00
toaster
6274b1f31f Fast forward through the unlock sequence by holding the Extra button.
Based on VC complaints.
2023-01-04 17:45:24 +00:00
toaster
20b6a8389b Challenge grid population improvement
* Correctly identify that two columns with only one major unlock will have 6 empty tile slots, not two. This will result in less underutilised Challenges grid space.
2023-01-04 17:28:45 +00:00
toaster
06e7eb3567 Add a funny little rotating question mark ala SA1 character select 2023-01-04 17:23:18 +00:00
toaster
f9e0c0a444 Challenges menu visual adjustment
* Use the new background
* Use clipped rectangles instead of black pixel overdraw, so pre-baked darkened areas in the new background can be visible instead
2023-01-04 17:22:57 +00:00
toaster
2786c2095e More incorrect/inconsistent frees 2023-01-04 14:22:04 +00:00
James R
5ed30012ed cv_addons_option: rename RINGRACERS to IWAD
This maps to the srb2path folder, which is where the IWAD
is located.
2023-01-04 00:09:58 -08:00
James R
8b96612e43 Default addons menu to addons folder 2023-01-04 00:08:30 -08:00
James R
5c51ad77f6 Use P_SaveBufferFree everywhere
- Fixes PR_SaveProfiles calling stdlib free on zone
memory.
- Also touched g_demo.c
2023-01-03 23:23:34 -08:00
James R
66e2f3a8e9 Reduce stair janking loss of control if momentum angle drifts too far from facing 2023-01-03 22:43:58 -08:00
toaster
11b4fcdc1c Remove heinous pointer-sent-over-the-network hack remnants
This used to be used for `P_RelinkPointers()`, but was superseded by the far saner mobjnum. HOWEVER, its lingering effect was to leave `mobj->info` in an invalid state until a later `P_FinishMobjs()` was called. This is memory unsafety :D

After removing the last remnants of this ancient hack, it is now once again possible to connect to a server without crashing immediately. However, I did get a crash after a few seconds, so there is definitely still *something* nasty going on under the hood.
2023-01-03 20:20:22 +00:00
toaster
80d19a8458 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into save_p-unglobal-alt
# Conflicts:
#	src/g_demo.c
2023-01-03 19:45:18 +00:00
toaster
b573b6efbc Don't tie restoring mobj/waypoint pointers on player struct to existence of player object 2023-01-03 19:41:46 +00:00
toaster
9336e39350 Use Zone memory functions for sending compressed saves
Fixes an issue where `SF_RAM` meant `free()` was being called on Zone memory produced by `P_SaveBufferAlloc`
2023-01-03 19:41:27 +00:00
James R
691e84f489 Give item drops a trail upward, fall faster 2023-01-03 05:31:30 -08:00
James R
50d9bf7b7d Faster moving players hit monitors harder 2023-01-03 05:31:30 -08:00
James R
7ce12f37dc Spawn Battle monitors
- Item count has always scaled up with player count. Items
spawn every N tics. Previously, these items were evenly
distributed across all item spots. Now, only one monitor
is spawned at a time and the number of items inside scales
up.

- Emeralds spawn inside of monitors instead of loosely.
- Sphere boxes should spawn in the same way as before.

- Once a monitor has been spawned at an item spot, no more
monitors can be spawned there until that one is destroyed.
There's an additional delay of one spawn interval before
a monitor can be spawned in that location again. This is
so a monitor cannot ever instantly spawn back if one is
destroyed at just the right time.
2023-01-03 05:31:30 -08: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
James R
3549625095 Add item monitor states
SPR_MSHD
SPR_IMDB
SPR_MTWK

S_MONITOR_DAMAGE
S_MONITOR_DEATH
S_MONITOR_SCREEN1A
S_MONITOR_SCREEN1B
S_MONITOR_SCREEN2A
S_MONITOR_SCREEN2B
S_MONITOR_SCREEN3A
S_MONITOR_SCREEN3B
S_MONITOR_SCREEN4A
S_MONITOR_SCREEN4B
S_MONITOR_STAND
S_MONITOR_CRACKA
S_MONITOR_CRACKB

S_MONITOR_BIG_SHARD
S_MONITOR_SMALL_SHARD
S_MONITOR_TWINKLE

MT_MONITOR
MT_MONITOR_PART
MT_MONITOR_SHARD
2023-01-03 05:31:30 -08:00
James R
ae16f124db K_GetTotallyRandomResult: use NULL roulette data
This fixes random paper items spawner RNG not advancing.
2023-01-03 05:30:53 -08:00
James R
339cb1e8b8 K_KartGetItemOdds: apply GTR_CIRCUIT checks
- No restriction on whether more than one player may
receive the same type of shield outside of Race.
- SPB is now technically allowed outside of Race, if item
odds permit.
- powerItems and assorted checks no longer apply outside
of Race.
2023-01-03 05:29:59 -08:00
James R
a37eccd708 Split powerItem etc conditions from K_KartGetItemOdds 2023-01-03 04:42:48 -08:00
James R
aab661cad8 Split shields and SPB special conditions from K_KartGetItemOdds 2023-01-03 04:42:48 -08:00
James R
5bdbbd1695 Comptime.cmake: escape \backslashes and "quotes" in git subject line 2023-01-02 20:06:30 -08:00
Oni
e400625da8 Merge branch 'broly-sigfpe' into 'master'
Fix Broly SIGFPE

See merge request KartKrew/Kart!841
2023-01-03 02:49:58 +00:00
Oni
46005089f1 Merge branch 'rulesify' into 'master'
Rulesify (resolves #375)

Closes #360 and #375

See merge request KartKrew/Kart!836
2023-01-03 02:43:52 +00:00
Sal
2335c849fe Merge branch 'monitors-prep' into 'master'
Misc. changes for the sake of monitors

See merge request KartKrew/Kart!805
2023-01-03 00:52:52 +00:00
Sal
3f6cc8a183 Merge branch 'cmake-build-type-titlescreen' into 'master'
Show CMAKE_BUILD_TYPE on title screen

See merge request KartKrew/Kart!849
2023-01-03 00:51:30 +00:00
Sally Coolatta
aa4fd8ab13 Add functions to initialize savebuffer_t
g_demo.c is mostly unaltered because it is made of twigs.
2023-01-02 19:47:59 -05:00
Sal
cab15b7d07 Merge branch 'file-and-header-fix' into 'master'
File and header fix (resolves #370)

Closes #370

See merge request KartKrew/Kart!848
2023-01-03 00:40:38 +00:00
toaster
e73e0bd835 Don't treat players with 0 lives that are exiting (definitely just completed a race) as irrelevant in P_CheckRacers counts
Fixes special stages not booting you back to the title screen after running out of lives on them
2023-01-02 20:20:47 +00:00
toaster
26f3490ba8 Increased memory safety with cupgrid memory allocation
Also clearer variable name for length of cupgrid page in memory
2023-01-02 13:32:12 +00:00
toaster
4b9797fe26 Correct for recursive iteration of multiple mines in succession clobbering filescope minehitlag 2023-01-02 13:08:11 +00:00
James R
5887c36111 Show CMAKE_BUILD_TYPE on title screen
Includes a hint if optimizations may have been turned off.
2023-01-02 01:46:05 -08:00
James R
8a92f03f7b Set fuse for Battle items 2023-01-01 18:38:53 -08:00
James R
71004d4b46 Halve spawn time for Battle items 2023-01-01 18:38:53 -08:00
James R
3965f77763 Add BATTLE_SPAWN_INTERVAL 2023-01-01 18:38:53 -08:00
James R
6eb8da1a56 Add K_GetTotallyRandomResult, for battle item spawners 2023-01-01 18:38:53 -08:00
James R
a94e18c277 Add K_UpdateMobjItemOverlay 2023-01-01 18:38:53 -08:00
James R
43aa162fcb Add K_GetChaosEmeraldColor 2023-01-01 18:38:53 -08:00