Commit graph

1999 commits

Author SHA1 Message Date
James R.
39a867b705 Double hyudoro invisibility time 2023-09-17 21:56:18 -07:00
toaster
467b5f831b Add GTR_CHECKPOINTS
- Prevents Checkpoint from spawning
- Prevents spawnpoint-handling code from occouring
2023-09-16 23:22:59 +01:00
James R
2bbf69ded3 Checkpoints: add respawning behavior for players
- Add checkpointId to player_t and netsave
- checkpointId persists if the map is reloaded, but not if
  the map is changed or if "resetplayers" is ticked
- Players spawn at the last touched checkpoint instead of
  at a player start
- Tether sparkles fly out of the player in a circle
2023-09-16 21:46:22 +01:00
James R.
3cdfa86b11 Make timing of level fade-in consistent, relative to title card 2023-09-12 05:19:27 -07:00
Sal
0675a4e527 Tally screen 2023-09-09 05:27:55 +00:00
Oni
1c0a6c719c Merge branch 'gp_buttone' into 'master'
Intermission Button Slide-in

See merge request KartKrew/Kart!1450
2023-09-03 23:35:24 +00:00
AJ Martinez
d3316ff614 Shrink growtime 2x, global darkness when using shrink 2023-09-01 20:40:52 -07:00
toaster
62ab7bc0f9 Move the Podium to the slide-in Intermission Button/Menu CMD system
Again, another hand-built Responder function falls to the efficiency of the MenuCMD Press [A] chad
2023-09-02 00:26:29 +01:00
toaster
4ad0beebb4 Credits and Evaluation: Replace dedicated Responder functions with Menu-style input processing
The former method responded with an arbitrary approximation of standard inputs.
This method benefits from the general-case stability of the Menu system to correctly parse triggers and other unique inputs.
The only major consequence of this change is that ESC is no longer hardcoded to activate these.
Otherwise, the game is cleaner for pure benefit.
2023-09-02 00:26:29 +01:00
toaster
c46889c924 G_Responder: Call HU_Responder in Playing(), instead of a whitelisted set of gamestates
Neatly sidesteps a class of bugs where whenever we added a new gamestate accessible in netplay, chat was console-only.
2023-09-02 00:26:29 +01:00
toaster
94db9ac3a6 Add skipping to Evaluation
- Includes the sliding intermission button
    - Can only skip after the savedata has been updated
    - Always update the savedata at the same duration into the Evaluation
2023-09-02 00:26:29 +01:00
toaster
75900e4891 Credits: Add the sliding intermission button for skipping
Rules of skipping are slightly changed to match the slidein.
- No skipping in the first two seconds
- Automatically shuffles away once it gets to the end
2023-09-02 00:26:29 +01:00
Eidolon
428fa11231 Merge branch 'rhi-remove-passes' into 'master'
hwr2: Remove pass infrastructure

See merge request KartKrew/Kart!1440
2023-09-01 23:17:54 +00:00
toaster
898a659c78 Merge branch 'initplayers-reorder' into 'master'
Fix Splitscreen GP Prison Break

See merge request KartKrew/Kart!1446
2023-09-01 20:43:10 +00:00
Eidolon
6f580606cd hwr2: Remove pass infrastructure
It's not worth trying to force the engine to conform to deferred
drawing.
2023-09-01 15:30:04 -05:00
VelocitOni
8845700c06 Starpost Gentrification
Replaced all mentions of starpostnum and Starpost w/ cheatchecknum and CheatCheck (so Ivo can stop asking why we still need it when its going to save our asses on release patches)
2023-09-01 00:31:49 -04:00
toaster
60ce81f00d Fix the order of operations so K_TimerInit is ready for P_InitPlayers
Guarantees players in splitscreen GP Prison Break rounds are always deterministically placed (as long as the non-battle spawnpoints exist)
2023-08-31 19:24:49 +01:00
toaster
a7b065c4d8 P_InitPlayers: Tidy up the barely-significant difference between G_DoReborn and G_SpawnPlayer
Only kills objectplace at map start, not general respawn
2023-08-31 17:30:05 +01:00
toaster
43eb61dfcb Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into prisons-death-fix
# Conflicts:
#	src/p_inter.c
2023-08-31 14:02:38 +01:00
James R
ecbb6f3af2 G_DoLoadLevelEx: fix compiler error on HU_DoTitlecardCEcho after merge 2023-08-28 00:53:47 -07:00
James R
1db1eaedff Merge branch 'sealed-star-lose-text' into 'master'
Sealed Stars: show text on the screen for loss conditions; improved titlecard cecho centering, splitscreen support

See merge request KartKrew/Kart!1404
2023-08-28 07:48:47 +00:00
toaster
6869496843 Fade to white before the Podium if you successfully get the Emerald/Prize
Further Sealed Star polish requested on the gitlab.
2023-08-26 23:30:12 +01:00
toaster
e123ed7480 MAJOR cleanup of Spectator set/unset
- G_AddPlayer now contains CL_ClearPlayer, G_DestroyParty, and playeringame set
- Instead of a nasty, complicated block in P_SpawnPlayer, externalise it into G_SpectatePlayerOnJoin
- All mid-game human player-to-spectator transitions are handled by P_SetPlayerSpectator, instead of lots of `spectator = true` and associated boilerplate
    - Simplifies Got_Teamchange MASSIVELY
        - Of course this is helped by also stripping back team change
    - This is called by P_KillPlayer, too
- P_KillPlayer no longer eats DMG_SPECTATOR when lightsnaking or exiting
- G_GametypeHasSpectators condition tidied
2023-08-26 19:48:20 +01:00
James R
cb06fedc18 Make -writetextmap a console command, call it "writetextmap"
- Convert multiple maps at once
- The game cheers for you when it's done and tells you
  where it saved the TEXTMAP files
2023-08-26 06:05:09 -07:00
James R
6c0b042eed Refactor cvar definitions completely, move everything to cvars.cpp
- No need to call CV_RegisterVar
- Cvar definitions live in only one file, easier to locate
- Organized into sections -- netvars, cheats, etc.
- Use builder pattern to initialize cvars
- Still need to extern if you want to read the cvar value
2023-08-25 17:22:40 -07:00
Oni
b63f3f6f16 Merge branch 'majin-box' into 'master'
Auto Roulette (resolves #618)

Closes #618

See merge request KartKrew/Kart!1411
2023-08-25 19:24:42 +00:00
Oni
148b56eccf Merge branch 'kill-dead-shit' into 'master'
Remove some unused code

See merge request KartKrew/Kart!1420
2023-08-24 22:10:43 +00:00
James R
c5e341769b Remove unused cvars
- growmusicfade
- invincmusicfade
- music_resync_powerups_only
- music_resync_threshold
- renderstats (wasn't even registered in the console!)
- resetspecialmusic
- resume
- samplerate
- stretch
- tailspickup
2023-08-24 04:52:41 -07:00
toaster
a3640110ae Only permit Spray Cans to be grabbed on base game levels
I would not be so heavy handed against preventing players from grabbing Spray Cans on custom levels, but designing a system that permits unloaded headers to retain their cans is frankly overkill. There are plenty of other ways the same kind of level-scouring play can be experienced on custom levels.
2023-08-23 17:16:07 +01:00
toaster
e1b7cb66cb Rework the Spray Can system to ACTUALLY be what we want
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.
2023-08-23 00:46:46 +01:00
toaster
3ccf668fda Rename numspraycans to nummapspraycans
- Consistency with nummaprings
- Prevents confusion with incoming gamedata struct variable
2023-08-22 23:12:02 +01:00
toaster
f7635c4399 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into spraycans 2023-08-22 19:57:28 +01:00
Oni
852e2c1035 Merge branch 'acs-game-over' into 'master'
ACS script type for game over (lose GP round with no extra lives), improve MapWarp and add a handful of functions

Closes #591 and #572

See merge request KartKrew/Kart!1403
2023-08-21 16:50:18 +00:00
James R
78ee9a7e0b G_StartTitleCard: don't play titlecard sfx for Podium 2023-08-20 17:18:39 -07:00
AJ Martinez
3900189199 Auto Spin -> Auto Roulette 2023-08-20 16:26:34 -07:00
AJ Martinez
fbfc75df71 Item box autospin 2023-08-20 05:08:53 -07:00
James R
2ffc41b52e G_MapNumber: let parse NEXTMAP 2023-08-20 00:36:00 -07:00
James R
9b4367773c Add GAMEOVER ACS script type
Triggered when the level ends with a losing condition and
there are no extra lives.
2023-08-20 00:36:00 -07:00
James R
8a72f42818 Split G_ExitLevel into G_BeginLevelExit and G_FinishExitLevel
- Save retry condition in G_BeginLevelExit
- Apply condition in G_FinishExitLevel

Preparation for ACS level end scripts, since the exit
condition will need be known when the countdown starts,
not when it ends (that'd be too late to do anything in the
level).
2023-08-20 00:36:00 -07:00
toaster
dc695e7acf First pass at implementing Spray Can pickups
- Replaces a few D00DKart objects because the doomednum specifically replaced one of these
- Reports on load if the map has too many, or if one's assigned but the object doesn't exist
2023-08-19 22:21:20 +01:00
toaster
1d06637a38 First pass at assigning unique spraycans to level headers
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
2023-08-19 15:08:55 +01:00
toaster
be1d3e49e8 Change indentation/bracketing on gamedata load for map records
To make the next commit less painful to parse.
Also fixes signedness of mapnum from INT16 to UINT16
2023-08-19 15:04:46 +01:00
toaster
fb8795c8da M_FinaliseGameData
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.
2023-08-19 14:32:11 +01:00
James R
01e2a26689 DEVELOP: let us spectate or pause the game at all times
TODO: This should be available as a debugging option at
release, since it would be useful for addon authors.
I don't want to make more cvars, those are getting
cluttered and should maybe be coalesced into a single
debugging option.
2023-08-19 05:01:40 -07:00
James R
5a973734d0 Move software shearing conditions from R_SetupFreelook into G_FinalClipAimingPitch 2023-08-19 05:01:40 -07:00
James R
89c503135a Tweak spectator vertical aiming
- Decrease vertical aiming speed to match turning speed
- Reduce software aiming bounds to 45 degrees
  - (Even) less distortion due to extreme angles
2023-08-19 05:01:39 -07:00
James R
368ffb79b8 Move ticcmd generation code from g_game.c to g_build_ticcmd.cpp 2023-08-13 16:03:09 -07:00
James R
e75204a899 Replace instances of itemRoulette.active = false with K_StopRoulette
Properly clear ringbox state so it doesn't override egg
transfer item HUD.
2023-08-11 19:21:59 -07:00
Oni
21d00050a6 Merge branch 'quiet-ring-spam' into 'master'
Reduce ring sound volume as it's repeated

See merge request KartKrew/Kart!1370
2023-08-11 07:23:52 +00:00
toaster
b669f8484f Realname for Cups
Permits prefixing them like maps AND giving them spaces instead of underscores, fixing the "RECYCLE_A" issue.
2023-08-10 00:28:17 +01:00