Commit graph

21801 commits

Author SHA1 Message Date
toaster
ff926440d5 UCRP_WETPLAYER: Adjust SOC load to not Z_StrDup before confirming other data is valid, to prevent memory leak 2023-03-06 22:38:37 +00:00
toaster
f6a83d2161 M_GetConditionString: All non-allcaps messages have had their first letter lowercased
Instead, M_BuildConditionSetString uppercases the first lowercase letter, so it's always (approaching) grammatical correctness.
2023-03-06 22:32:02 +00:00
toaster
baeb48ca1f roundconditions_t - State tracking for events which occour mid-match and don't stay that way
- Exists on every player struct to simplify writes, but A) not netsynced and B) only checked for local players
- Updated in the relevant locations - no centralised ticking at the moment
- Has a number of new associated conditions that require playing (UCRP's).
    - The following require [True/False] as supplementary information.
        - FallOff
        - TouchOffroad
        - TouchSneakerPanel
        - RingDebt
    - The following have no supplementary information because they're universally a specific achievement.
        - TripwireHyuu
        - SPBNeuter
        - LandmineDunk
        - HitMidair
    - The following has specific requirements that can be set.
        - WetPlayer [name of fluid]
             - Append "Strict" to forbid even skimming the surface of the map's fluid.
2023-03-06 22:31:35 +00:00
toaster
d540921f78 M_PopulateChallengeGrid: Since I actually got a scenario where two tiles weren't able to be populated, just do the rejiggering fix in a while loop. 2023-03-06 22:18:12 +00:00
toaster
a355445592 condition_t: Make pendingstring into stringvar in anticipation of second, less angry application 2023-03-06 20:11:45 +00:00
toaster
1e67f75f14 P_Ticker: Adjust bracketing of Gamedata save conditional to handle deferred saves even during intro turnaround 2023-03-05 21:00:27 +00:00
toaster
60968b2f08 UC_AND, UC_COMMA: Fix not combining with UCRP_REQUIRESPLAYING
Fixes
2023-03-05 20:59:56 +00:00
toaster
87b80a62f2 SPB Attack: Integrate into conditions-cascading affairs
- All `cv_dummyspbattack`-related material is now gated with the assistance of SECRET_SPBATTACK.
    - SPB_ATTACK
- Add UC_MAPSPBATTACK condition.
    - Both this and emblems with MV_SPBATTACK have the string "SPB ATTACK: Conquer [LEVEL NAME]", compared to the regular round completion conditions having "Finish a round on [LEVEL NAME]".
        - If SPBATTACK is not unlocked, shows ???: Conquer [LEVEL NAME] instead
2023-03-05 20:48:31 +00:00
toaster
99b5fe7bf4 M_EraseData: Fix va() being passed to va() 2023-03-05 19:56:52 +00:00
toaster
0f715454fa Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into conditions-cascading 2023-03-05 19:51:48 +00:00
toaster
80555e3738 P_Ticker: Do not evaluate interesting player conditions during introtime 2023-03-05 19:51:33 +00:00
toaster
b005649d71 Copyright notices update regarding the author of this commit
- For cross-file consistency in the author of this commit's name and username
- To note that the author of this commit performed significant work on code that would eventually be compiled into r_skins.c on several occasions since 2016 up to the present day
- To catch work performed by the author of this commit in 2023
2023-03-05 18:13:39 +00:00
toaster
0c75c40060 Rework how Bots handle their skin availabilities
Before we can add extra unlock features, we need to make sure we're not building on a house of sand.
- R_SkinUsable: Use Net Unlock system if playernum is -1
- R_BotDefaultSkin: Move to r_skins.c, cache skin search
- R_GetSkinAvailabilities: Use Net Unlock when called for bots (and always permit R_BotDefaultSkin)
- Got_AddBot: Call R_GetSkinAvailabilities for summoned bots to guarantee sync status of available skins
- K_UpdateMatchRaceBots: Tidy up to match grand prix bot skin selection system, hiding server-locked skins and defaulting to R_BotDefaultSkin if you don't have enough unlocked for the remaining player slots
2023-03-05 18:06:09 +00:00
James R
d45ba09ac0 Merge branch 'spb-attack' into 'master'
SPB Attack

See merge request KartKrew/Kart!992
2023-03-05 01:26:32 +00:00
James R
f94559a24e Merge branch 'replay-tooltip-buttons' into 'master'
Update replay save prompts to use the new button graphics (resolves #458)

Closes #458

See merge request KartKrew/Kart!1015
2023-03-05 01:24:18 +00:00
James R
27a4f96d13 Merge branch 'fix-avrecorder-wipe-capture' into 'master'
Fix white flash in webm videos when fades start

See merge request KartKrew/Kart!1013
2023-03-05 01:22:46 +00:00
toaster
1ae5df651d UC_ADDON
- If you add a file (and you've unlocked Addons on non-DEVELOP builds) this gets achieved
- Also, Custom # of Rounds Played conditions will show "Custom" only if Addons are loaded
2023-03-04 21:36:58 +00:00
toaster
f7617e7530 Clear records, stats, and secrets on new in-SOC gamedata creation
- Pre-emptive sanity check to some impending work
- Move M_UpdateUnlockablesAndExtraEmblems out of M_ClearSecrets
2023-03-04 21:11:13 +00:00
toaster
5296ab1397 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into conditions-cascading 2023-03-04 20:09:48 +00:00
toaster
e994b920c6 gamedata->roundsplayed: Split into multiple roughly-gametype-aligned categories
- Race, Capsule, Battle, Special, Custom
- All categories can now be used for Rounds Played condition
- UCRP_SEALEDSTAR now hides if you haven't beaten a single Sealed Star yet
In addition, introduce M_ClearStats
- As more statistics get added, clearing them manually in G_LoadGameData and M_EraseDataResponse is just going to get annoying
- Change around the options on the Erase Data screen to
    - Make it clear that erasing all game data won't clear your Profiles
    - Add an option to clear stats by themselves, rather than only permitting via complete gamedata wipe
    - Move to the "Challenges" terminology over SRB2's "Secrets" terminology
- Move some entries that were previously handled in M_ClearSecrets into M_ClearStats
2023-03-04 20:09:29 +00:00
toaster
22f9467e71 M_ClearConditionSet: fix memory leak 2023-03-04 17:33:56 +00:00
AJ Martinez
4121b4c385 SPB Attack: fix double cvar callback 2023-03-04 06:43:52 -07:00
AJ Martinez
320685cf97 SPB Attack: review fixup omnibus 2023-03-04 06:41:44 -07:00
SteelT
65e8315bd9 Update thin strings to use V_6WIDTHSPACE 2023-03-04 01:02:21 -05:00
SteelT
e8d6d7f632 Fix missing draw call for DSM_NOTSAVING 2023-03-03 23:43:06 -05:00
SteelT
31e2c1567e Update replay save prompts to use the new button graphics
- A K_drawButtonAnim function is also provided for convince, since I figured it would have more future uses
- This also makes all of the button patches global, in addition
2023-03-03 23:19:46 -05:00
Sal
0fa1e99a82 Merge branch 'fix-twodee-dedicated' into 'master'
Fix dedicated server crashes + disable GP

See merge request KartKrew/Kart!1009
2023-03-04 02:59:03 +00:00
James R
17bf7d0935 Do not start dedicated server in GP if -warp is used 2023-03-03 18:56:07 -08:00
James R
5efce73680 Do not run ST_Ticker if dedicated 2023-03-03 18:56:07 -08:00
James R
546f8d88c3 Do not reset twodee context if dedicated server 2023-03-03 18:56:05 -08:00
toaster
eeb6e40909 Add totalrings to gamedata
- Added to Statistics screen
- Caps at "999,999,999+".
- Controls UC_TOTALRINGS condition
- Improve description for UC_MATCHESPLAYED condition
    - Says "Rounds" now
- Improve Statistics text for playtime
    - Dynamically changes visible units of time (seconds, minutes, hours, days.......)
2023-03-03 22:35:28 +00:00
AJ Martinez
c1baff583c Don't abort SPB Attack on postrace death, idiot 2023-03-03 12:17:11 -08:00
AJ Martinez
8739d3076a Use more fitting name for SPB Attack menu patch 2023-03-03 12:17:11 -08:00
AJ Martinez
211206ba6f Fix menus, fix failure condition 2023-03-03 12:17:10 -08:00
AJ Martinez
f3f4ac16de SPB Attack: medals, emblems, and fixes 2023-03-03 12:15:00 -08:00
AJ Martinez
6173ca47aa SPB Attack: emblems/medals preliminary 2023-03-03 12:15:00 -08:00
AJ Martinez
79d8e4e109 WIP: SPB Attack - temp menu draws OOB, no unlocks 2023-03-03 12:14:58 -08:00
James R
9f46c705f0 Merge branch 'fix-double-race-print' into 'master'
Fix the "player has finished the race" message being printed to log twice

See merge request KartKrew/Kart!1012
2023-03-03 20:01:24 +00:00
SteelT
386e32891f Fix the "player has finished the race" message being printed to log twice 2023-03-03 12:00:08 -08:00
James R
1cbc4944ba Merge branch 'improve-msdos-83-error' into 'master'
Add instructions to the 'Are you using MSDOS 8.3 filenames in Zone Builder?' error

See merge request KartKrew/Kart!1011
2023-03-03 19:58:35 +00:00
James R
64e6583a74 Merge branch 'connect-screen-reset-2d' into 'master'
Reset twodee contexts when drawing connect screen

Closes #461

See merge request KartKrew/Kart!1007
2023-03-03 19:54:33 +00:00
James R
e65c2ba7a8 Merge branch 'improve-misc-game-testing' into 'master'
Improvements for testing/debugging

See merge request KartKrew/Kart!1004
2023-03-03 19:54:16 +00:00
James R
833a51b384 Merge branch 'fix-fault-freespin' into 'master'
Fix chasecam desyncs during hitlag/death/FAULT

See merge request KartKrew/Kart!1002
2023-03-03 19:53:50 +00:00
James R
8d25820c91 Move screenshot pass out of basic_rendering, into normal_rendering
This fixes a bug with avrecorder capturing a mostly white
frame at the beginning of a wipe. This was because
wipe_capture_start_rendering depends on basic_rendering
and a wipe could occur before any 2d elements are batched
for the current frame, thus producing a white frame when
basic_rendering is passed. It only lasted for one frame
because the PREVIOUS frame is used for the wipe itself.
This is also why the white frame was not visible
on screen.
2023-03-03 11:24:57 -08:00
toaster
74336efc74 UC_CRASH: Adjust condition string to handle newlines better 2023-03-03 16:38:01 +00:00
toaster
8603094664 M_PopulateChallengeGrid: Attempt to recover from one major tile too many for the amount of space left, which is relatively trivial only in the height == 4 case. 2023-03-03 16:37:35 +00:00
toaster
002de8c948 G_LoadGameData: Regenerate challengegrid from previous minor versions 2023-03-03 16:00:45 +00:00
toaster
4f8df12403 M_PopulateChallengeGrid: Remove bad challengegrid when I_Erroring to prevent corrupted save 2023-03-03 15:59:25 +00:00
toaster
06bde8b40e M_CheckCondition, conditiontype_t, etc: More fine-grained control over your condition string
- UCRP_PREFIX_ISMAP: a prefix version of UCRP_ISMAP
    - The condition string for UC_EMBLEM has been updated to match other relevant prefixes.
- UC_COMMA: a second string-relevance-only condition, for inserting a comma where only a human could find it natural
2023-03-03 15:40:10 +00:00
toaster
bd54a789a2 M_BuildConditionSetString, M_StartMessage: Fix occasionally spurious injected newlines 2023-03-03 15:31:36 +00:00