Commit graph

20546 commits

Author SHA1 Message Date
James R
ae02579b09 Fix menu start button closing the chat 2022-10-23 13:20:13 -07:00
toaster
4851b8e697 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into udmf-cherrypick 2022-10-22 20:25:13 +01:00
toaster
78c8e27542 Merge branch 'wadname-maps' into 'master'
WADNAME map definition lump special case

See merge request KartKrew/Kart!730
2022-10-22 19:12:21 +00:00
toaster
b686137d12 Correctly NULL thumbnailPic and minimapPic when map lumpnum changes
Fixes the core part of Chengi's graphical issue
2022-10-22 19:58:10 +01:00
toaster
e5365339da Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into wadname-maps 2022-10-22 19:53:05 +01:00
Eidolon
c1f0be719e make: Fix ifdef check from dummy target changes 2022-10-20 21:12:58 -05:00
James R
19a6ea8478 Do not multiply TERRAIN speedPad value 2022-10-18 18:20:19 -07:00
James R
7ceef19f74 Fix 42f9443de 2022-10-17 23:50:38 -07:00
James R
42f9443de1 UDMF: Add back #900 and #901 additive, subtractive special alpha values for FOFs
Fix fourth digit blend mode being off by one.

see ebe38ff518
2022-10-16 18:07:39 -07:00
James R
8a8126567b Fix -Wformat 2022-10-16 16:50:13 -07:00
toaster
fca6dc2c6f No contesters use the position of their broken kart on the minimap
This is instead of their flung body, which drifts significantly from where you died and muddies the "LOL YOU DIED THAT CLOSE TO THE FINISH!?" voicecall laughter moments
2022-10-16 14:54:13 +01:00
toaster
3bb78ad46d Always show timelimit if timelimitintics is set, to allow spotting weird bugs before they cause problems 2022-10-16 14:34:13 +01:00
toaster
59094f73fb Clean up K_TimerInit()
- Fix not being able to change timelimit in MP break the capsules
- Use more readable variable name (singleplayercontext --> domodeattack)
- Reset timelimitintics in K_TimerReset()
2022-10-16 14:23:21 +01:00
toaster
735c487b65 Fix modeattacking being assumed to be boolean in K_CanChangeRules 2022-10-16 14:22:51 +01:00
toaster
ce020d7207 timelimitintics-related shenanigans
- Play a countdown sound (same as introcountdown) per each of the last 3 seconds
- Jitter the time display HUD extra strong in a two-tic window around the above
- Fix timelimitintics not being set in TESTOVERTIMEINFREEPLAY builds (which is now all DEVELOP builds)
2022-10-16 14:21:52 +01:00
toaster
6ed9ddc069 Add comment to Titlecard code for future changes if we add other bonusgames for GP 2022-10-16 13:23:53 +01:00
toaster
a7a2956b89 Add extra minimap icons
- Battle Capsules for Break The Targets, to improve conveyability
- No Contest players have a special X icon
Also fixes a few issues with minimap rendering
- obviously written before netsplits and bots
- mixing up array indices and loop iteration for local players
- mixing up SPB object and target
- old version of hyudoro with double time in Race
- using explicit gametype comparisons instead of gametype rules
- SPBs with hitlag disappeared from the minimap
2022-10-16 13:21:12 +01:00
toaster
a100987940 Completely prevent bots from utilising PF_WANTSTOJOIN 2022-10-15 16:51:16 +01:00
toaster
6c9c6eeaf8 Also tick (almost) all karthud array timers even during hitlag
Only exception is timers relating to ring usage, as that's intended to signify ring boost power (which is obviously paused during hitlag)
2022-10-15 16:49:51 +01:00
toaster
ec437b199c Rearrange P_PlayerThink to make some things occur even in Hitlag
Notably REALTIME - prevents the timer stopping when you get hit, but also:
- Typing indicator
- Airtime tracking
- Kickstart accel
- No Contesting due to racecountdown
- Spectator data wipe
- Stronger preventative measure for possible finish line multi-hit events
2022-10-15 16:29:53 +01:00
toaster
287c018790 If timelimit is being modified before starttime, tick the secret timer but don't modify the total limit. 2022-10-15 16:03:39 +01:00
toaster
02884d235c If timelimit is set while being modified (extremely unlikely but technically possible), stop adding extra time. 2022-10-15 15:58:24 +01:00
toaster
31bba30dcc No time limit in Capsule timeattack 2022-10-15 15:55:31 +01:00
toaster
52c0e145be Fix pointlimit messages occouring in singleplayer contexts
Still an awful child that hasn't shaped up like their sister cv_timelimit, but this will do for now.
2022-10-15 15:51:57 +01:00
toaster
414550dc3b Don't make gptest behaviour apply in Record Attack. 2022-10-15 15:45:59 +01:00
toaster
21be55e924 Fix cup level list behaviour
- Frees existing string data
- Unbinds cup backreference here instead of in p_setup
2022-10-15 15:43:11 +01:00
toaster
19e427f5db Compilation warning: disambiguating parens in A_AttractChase 2022-10-15 15:15:58 +01:00
toaster
ca2ecf6e9f Add "allowdemos" option to K_CanChangeRules()
It's been used interchangably as "this is a singleplayer gameplay context" and "This is a no cvar changing context". This addition repairs some behaviour which might have been inconsistent between netgame and netreplay.
2022-10-15 15:15:22 +01:00
toaster
e7f111c25a Fix the case where GP coop would cause no Capsules + possibly DUELs in eventmode
Also reduces some of the dead time before Break The Capsules begins by cutting out the majority of POSITION!! and hiding the one measly bulb that would otherwise appear
2022-10-15 14:57:35 +01:00
toaster
54a1ac9944 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into special-stages 2022-10-14 18:40:30 +01:00
toaster
f281f47c6f Support alternate gameplay events during GP
- Implementation details:
    - grandprixinfo.eventmode is the reference point
    - All bots have spectator applied and removed at map start depending on eventmode, and I've done my best to guard against side effects of not removing them entirely
    - You shouldn't turn off grandprixinfo.gp when turning on things like specialStage.active or bossinfo.boss when pursuing eventmode behaviour
    - Probably needs to be integrated into XD_MAP for any future netplay support, is currently disabled.
    - You technically don't have to assign a Capsules map to be the bonus and a Special Stage to be the special. A Capsules map can be assigned to a Special Stage too, and a Boss can be assigned to either of them.
    - Special Stages are still just as incomplete as they were before.
- Break the Capsules has special behaviour.
   - Timelimit starts at 20 seconds.
   - Earn 10 seconds (plus a little extra cheaty time) every capsule you destroy.
   - WIN + extra life if you bust all the capsules, COOL if you get some but run out of time, LOSE if you lose your bumper or run out of time without breaking a single capsule.
   - Supposed to also give you rings, but ran into a LOT of difficulty with this and didn't want to commit half-baked stuff, so it'll be a later project.
Also:
- Fix a long standing bug where totalring was reset between maps, preventing the sum from adding up across GP rounds and depriving you of extra lives you were owed.
- Fix an issue where Break the Capsules record attack was KARTSPEED_HARD.
- Send timelimitintics in savegames, since it's handled seperately now.
2022-10-14 18:34:43 +01:00
toaster
f926842b30 Fix replacing cups' map lists not properly reassigning the cachedlevels 2022-10-14 13:19:20 +01:00
toaster
b129e21fb4 Merge branch 'demo-path-buffer-too-small' into 'master'
Fix buffer overflow related to time attack demos

See merge request KartKrew/Kart!732
2022-10-14 09:09:54 +00:00
James R
01faa52162 Clean up instances of malloc replay file path
- Fix allocating only enough for "MAPXX".
- Fix memory leak in M_StartTimeAttack.
- Use va instead of malloc + sprintf, strdup where needed.
Some of these pass gpath to va anyway so that should be
enough room.
2022-10-13 16:34:24 -07:00
Eidolon
4bf008b59f Add missing .mk for dummy target
(cherry picked from commit d46c2013329c219e62ae19c819eee293671b3293)
2022-10-13 18:20:21 -05:00
GoldenTails
59ea961f58 Make dummy compile again, if SDL is explicitly set to 0
(cherry picked from commit ba55947ee6ab36efc04598953a78a11173103bcf)

# Conflicts:
#	src/doomtype.h
#	src/dummy/i_system.c
2022-10-13 18:06:48 -05:00
toaster
cf6ffcf15d Improved Battle Capsule pop visual
- Play a sound on initial hitlag, since pops are now delayed
- Add hitlag visual to sides
- Add horizontal momentum based on:
    - Deflection of the object damaging it
    - Whatever its momentum was before destruction
2022-10-13 21:34:36 +01:00
SteelT
e004633fe6 Fix double-free in W_Shutdown 2022-10-13 13:15:06 -04:00
toaster
c2ef5a32e9 Seperate FINISH text from khud_cardanimation
- Fixes an issue where the card animation and the FINISH animation operating on two different timers, but using the same variable, would intefere with each other
- Also makes khud_fault use the same drawer, so it can benefit from interpolation
2022-10-13 18:14:48 +01:00
toaster
c8471c7c27 Rework exit timing nittygritty
- exitcountdown is now used for both No Contest and regular exits
    - Set in P_DoPlayerExit
    - Handles sending XD_EXITLEVEL in P_Ticker
- player->exiting is now 0 or 1 (we can make it a bool or a new timer later)
- Fixes a longstanding bug where failing a GP round could restart multiple times
Also:
- Fix a possible waiting-in-the-wings issue where mapchanges would occour client-side in K_CheckBumpers
- Add `gptest` cheat - sets numlaps to 1 lap on mapload for quick but legitimate(ish) progression
2022-10-13 17:37:35 +01:00
toaster
5103b804ba Simplify intermission timer code
- We had two ways of ending the intermission, but only one would actually be used, and it resulted in code duplication.
- Combine the two ways.
- Disable the reached-but-didn't-do-anything-before-now code path for setting endtic.
2022-10-13 13:12:07 +01:00
toaster
a22d3b201d Make what's going on with K_RetireBots in Y_Ticker/Y_EndIntermission more explicit, in case we add anything else here later. 2022-10-13 12:41:27 +01:00
toaster
9f4ced146a Make intermission timer-dependent material consistent via K_CanChangeRules()
Prevents setting inttime 0 in singleplayer contexts
2022-10-12 20:17:20 +01:00
toaster
00b73d4a48 Rework nextmap a little further
- Set gamemap after intermission, rather than before.
    - Fixes a bug where the NO CONTESTed player wouldn't get cycled out on the 4th round, because it had already been incremented by G_GetNextMap.
- Make the vote screen a special NEXTMAP_VOTING constant, for sanity, and to make cv_advancemap handled all in one place.
    - Along with the above, fixes a bug where changing cv_advancemap would only enable or disable the voting screen, not change the nextmap.
- Call G_EndGame in G_NextLevel, since they were never used seperately.
- Add Special Stage and marathonmode to K_CanChangeRules.
2022-10-12 19:48:01 +01:00
toaster
df467a4a32 Bot skin selection fixes
- The case where entries on the end of the `grabskins` list were invalid
- Double ++ for botskinlistpos meant any successful skin-rival placement also guaranteed an Eggrobo (default skin)
2022-10-12 12:52:08 +01:00
toaster
99705faea6 Add a goofy little jitter to the HUD
- Medium strength at 5 seconds to go
- Big strength in overtime
2022-10-11 23:03:56 +01:00
toaster
243f38227c Rework time limit a bit
- Make timelimitintics handled a bit more like gamespeed, encore, frantic, etc - update on mapload/starttime, not during gameplay
    - Use default setting if can't change rules - this is a surprise tool that will help us later
- Have it properly update when adjusting gametype from the menu
    - Cleaned up SV_StartSinglePlayerServer to do this
- Remove CV_SAVE to prevent time limit bruh moments
2022-10-11 23:00:44 +01:00
toaster
13c8d45764 Rework bot skin randomisation
- Instead of picking over numskins and adjust the number if it picks an already used skin, build and shuffle a list of allowed skins and pick over that instead.
- Fixes some issues with increased weighting towards the skins immediately after your rivals' skins.
- Use PR_RULESCRAMBLE instead of PR_UNDEFINED.
- Why am I doing it in this branch? I'm getting re-acquainted with how bots are handled between matches in advance of disabling them for bonus events without losing or corrupting data.
2022-10-11 18:42:04 +01:00
toaster
dbc067f87a Use GP difficulty str values instead of hardcoded "Master" exception 2022-10-11 16:47:56 +01:00
toaster
44eb099cfb Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into special-stages 2022-10-11 15:44:32 +01:00