"hit a racer drafting off you while looking back at them"
Self-explanatory set of conditions
Wrote a commented out more compicated check for valid angles between player and target, but lastdraft probably is good enough for these purpses
Insta-Whip another racer while you yourself are invisible from Hyuudoro, it's shrimple
Also updates the phrasing used for UCRP_TRIPWIREHYUU to match ("afflicted by Hyudoro")
- `Condition1 = Faulted Yes`
- `FAULT during POSITION`
- for example, combine with "& finish in 1st"
- `Condition1 = Faulted No`
- `don't FAULT during POSITION`
"when cursed with Eggmark, blow up the racer responsible"
Just a simple condition. Either it happens or it doesn't.
MT_SPBEXPLOSION now tracks whether it was made by KITEM_EGGMAN or KITEM_SPB, too!
Break a target (Prison Egg/UFO) using exactly one Gachabom again and again
Becomes invalid if an Insta-Whip collides with a target, or you throw two at the same time
`Condition1 = UfoAttackMethod [type]`
- "smash a UFO Catcher using only [type]"
- Combine with `Prefix_SealedStar` or `Prefix_IsMap [special stage stage]`
- Shows up as "???"
- Types supported:
- `Boost` - "boost power" (sneakers)
- `Whip` - "Insta-Whip"
- `Banana` - "Bananas"
- `Orbinaut`- "Orbinauts"
- `Jawz` - "Jawz"
- `SPB` - "Self Propelled Bombs"
- Other types could be added on request, these were just the easy ones
In addition, the prototype for P_MobjWasRemoved was moved to `p_mobj.h`.
It's EXTREMELY important that we're able to safely check mobj pointers anywhere a mobj_t is possible to observe, without including the full `p_local.h`...
A series of 100 booleans on the roundconditions struct, one per possible lap.
Allows for a full suite of track hazard touching conditions - see the following examples.
- `Condition1 = Prefix_IsMap RR_MOTOBUGMOTORWAY
- `Condition1 = TrackHazard No`
- `Condition1 = IsMap RR_MOTOBUGMOTORWAY`
- "MOTOBUG MOTORWAY: Don't touch any track hazard"
- `Condition1 = Prefix_GrandPrix`
- `Condition1 = IsMap RR_HARDBOILEDSTADIUM`
- `Condition1 = TrackHazard Yes`
- `Condition1 = And`
- `Condition1 = FinishPlace 1`
- "GRAND PRIX: On HARD-BOILED STADIUM, touch a track hazard every lap & finish in 1st"
- `Condition1 = Prefix IsMap RR_DEATHEGG`
- `Condition1 = Trackhazard No 8`
- "DEATH EGG ZONE: Don't touch any track hazard on lap 8"
- `Condition1 = Prefix_IsMap RR_SPEEDHIGHWAY
- `Condition1 = TrackHazard No Final`
- "SPEED HIGHWAY: Don't touch any track hazard on the final lap"
- Change the phrasing from "activate the ancient shrine" to "play a melody for the ancient shrine in"
- Add ~~Morbius~~ Mystic Melody Orb decorations
- A_FireShrink has been fixed to use mapobjectscale (and prevent dividing by 0)
- `UnlockPercent 40 AltMusic` - "Get 40% of alternate music"
- `UnlockPercent 1 Color` - "Get 1% of Spray Cans"
- `UnlockPercent 20 Map` - "Get 20% of Courses"
- `UnlockPercent 55 Cup` - "Get 55% of Cups"
- `UnlockPercent 100` - "Get 100% completion"
- Provide a percentage and, optionally, an Unlockable type
- This only works for Unlockable Types where there are expected to be more than one per board
- "DescriptionOverride" (new!)
- Provide a full description in place of the params and this will be used
- Any conditions that are before it will not be wiped, so you can prefix it if you need to
- Can be used with any other set of Conditions
- `Condition1 = DescriptionOverride Complete the sentence: "ring racers (???)"`
- "Password"
- Now supports passwords that contain spaces
- `Condition1 = Password race as a ring!`
- "WetPlayer"
- Now supports liquids that contain spaces
- HOWEVER, it comes with the following caveats as part of the change:
- The strictness level must be provided first.
- You can't leave the strictness out. The previous default behaviour now requires STANDARD to be explicitly written.
- `Condition1 = WetPlayer Standard Mega Mack` can be used, now.
Gamedata minor version was updated again.
(God this was a weirdly big amount of work and it's not even polished.)
- Condition1 = PrisonEggCD [Level that has to be unlocked]
- Approximately every 30 Prison Eggs destroyed, you get a shot at a Prison Egg Drop.
- The only Prison Egg Drop implemented right now is an Alt Music CD.
- Your [Wild Prize] is guaranteed to be selected only from conditions associated with levels that are unlocked!
- Only spawns in Grand Prix Bonus Rounds, for netsync and game design.
- The number is fuzzed. If you start the level with 0 Prison Eggs to destroy, it selects a random number of Prisons in the level to bust.
- If you miss the pickup (such as into a deathpit), you'll get another shot in the immediate next Bonus Round you play.
Also:
- The number of Chao Keys you start your gamedata with is now part of the header file, not buried in the wiping function.
- Removed the ACTUAL last object definition vestiges of the Emerald Hunt gamemode.
Was messing around with part-duplicating this code for Prison Egg CDs, and realised a corruption/overwriting bug if you had more freebie Spray Cans than the standard ones.
Determining whether a map or cup is unlocked or not is now linear-time.
- Attempted to cache SECRET_SKIN et al as well, but skins are loaded after unlocks... oh well.
- Was staring down the barrel of a triple-nested loop for implementing SECRET_ALTMUSIC, so did this first to set good precedent.
- `Condition1 = MakeRetire Eggrobo`
- Fires when:
- Not a cooperative context
- You've finished in good standing
- Another player has both
- PF_NOCONTEST
- The skin specified in the condition
Also makes rivalname-handling for K_InitGrandPrixBots `const char *`, since the author of this commit had to reference that code.
- Remove pointless "BUILDCONDITIONTITLE" macro for M_BuildConditionTitle
- Replace simple R_SkinUsable checks with M_GetConditionCharacter
- Supports knowing a character's name via them being the Rival for a currently unlocked character, if that Challenge doesn't require them unlocked to interact
Currently exists for:
- Generating a Chao Key
- Attempting to use a Chao Key on a Major Challenge
- Only shows after Generating a Chao Key just so it doesn't fire before you know what's going on
Text is preliminary
- M_UpdateChallengeGridExtraData: Register whether major unlock tiles have had every surrounding Challenge cleared (CHE_ALLCLEAR)
- M_DrawChallengeTile: For locked tiles with CHE_ALLCLEAR, show a little dot (temporary drawer)
The prepended colour list passed to M_Shuffle_UINT16 was off by one, leading to possible pollution of the region with an uninitialised value.
For some reason, some people's machines guarantee clean stack memory on game startup, while other people's do not. This is why some people were crashing on Spray Can list generation and some weren't.
The stack memory was DEFINITELY not clean by the time you could navigate to the gamedata clear menu, which is why that was crashing without fail.
Just in case I don't get to do a major pass on adding a ton of extra unlockable conditions later, this is an easy, quick add featuring a stat gamedata and the statistics menu has been tracking for a while.
Instead of being specific to each level, Spray Cans are stored in a list on gamedata that will be stepped along each Spray Can you collect.
They are only assigned to a level on collection - which prevents you from farming the same easy location for every colour in the game.
In addition, this new system is one step short of dehardcoding them entirely. Now only Spray Cans specifically asked for by the existence of UC_SPRAYCAN will be put in the list, and if a secondary parameter is either "Yes" or "True", it will be put at the head of the list. This could technically support custom skincolours one day, but the author of this commit doesn't care to do the last bit of work necessary to make it happen.
There's a slight extra overhead in that skincolor_t now also holds a `cache_spraycan` (renamed from `cachedcan`, which maps had previously)
Currently, there's no safeguard against grabbing it on a custom course - you'll lose the Spray Can as soon as you load a fresh game again - but I consider that easy to fix (tomorrow) and necessary before merger, because the author of this commit does NOT want complaints on release because we forgot to protect users who keep on losing their skincolors.
Increments gamedata minor version, be aware
- M_AssignSpraycans
- Called in M_FinaliseGameData.
- Attaches a hardcoded set of colours to all race maps in cup order, stopping once we run out.
- The colours are shuffled, with some "freebies" always at the head of the list.
- Integrates partial lists pretty well.
- In DEVELOP builds, I_Errors if it produces corrupted state.
- G_LoadGameData, G_SaveGameData
- Save & Load is implemented for these assignments
Creates a central landing point where gamedata loads/creates can be finalised properly.
In addition, gamedata wipes caused by data erase or custom SOC gamedata can no longer be saved in a partway corrupted state if they were to crash midway through.
- The function is back to producing zone-allocated memory copies, like its precursor V_WordWrap
- The author of this commit got rid of that dependency originally because it seemed like a fair part of the API, and meant static buffers could be used in certain circumstances, but it was necessary to revert for the following change.
- Newlines can now be inserted mid-word, treating the width provided as ironclad except in the case of single characters wider than the region.
- This will be necessary for future work with the in-game chat.
- Reserves 8 characters at first, then Z_Reallocs double that every time it runs out.
Moves WordWrap to the font/V_GetFontSpecification system.
Much healthier long-term for our purposes, including the possibility of changing fonts for various contexts freely.