Commit graph

20811 commits

Author SHA1 Message Date
toaster
ac15d4caa3 Icon selection + Extras menu access
* Icon selection
    * You can use up, down, left, right, etc to select icons on the Challenges menu
    * The text at the top changes based on the highlighted icon
        * This text is now ??? if not yet unlocked
    * Uses the border for character rank icons
* Challenges are now accessible on the Extras menu alongside Addons and Replay Hut.
    * Previously there was a "Extras Checklist" dummy which did nothing when selected
    * Now I won't have to clear my gamedata every time I want to check this menu!
* M_ChallengeGridExtraData's array is modified to now contain specific info on whether a given tile is connected to above or left (or both).
2022-12-02 20:13:52 +00:00
Sally Coolatta
e8e02058ef Bigger Egg Capsule hitbox 2022-12-02 04:21:23 -05:00
Sally Coolatta
bdbd79dd41 Fix Egg Capsule interp 2022-12-02 04:15:56 -05:00
Sally Coolatta
b62ed33655 Fix Battle mode Egg Capsules bumping
Old vanilla-ass code for platform-like objects that is conflicting super hard with bumping / horizontal momentum. If we ever have a moving platform object this code should be brought back only for that object, and not solid objects as a whole.
2022-12-02 03:56:15 -05:00
Sally Coolatta
dbedd66259 Fix solid midtextures
UDMF's ML_MIDPEG == Binary's (!!(linedef->flags & ML_DONTPEGBOTTOM) ^ !!(linedef->flags & ML_MIDPEG)). This is converted in P_ConvertBinaryLinedefFlags
2022-12-02 02:01:02 -05:00
Sally Coolatta
7794f0956e Reset pitch/roll on springs + trick panels 2022-12-02 00:27:34 -05:00
Sal
dbf11e228d Merge branch 'vsync-default-off' into 'master'
Make vsync default to off

See merge request KartKrew/Kart!794
2022-12-02 05:06:25 +00:00
toaster
85160b1dc1 M_ChallengeGridExtraData
Precalculates adjacency rules for challengegrid instead of doing it in the drawer
- Simplifies `M_DrawChallenges` a lot, at the expense of a pretty complicated function living in `m_cond.c`
- Handles registering entries both not to be drawn (for non-primary components of `majorunlock` unlockables) and for hint highlights (new for this commit)
    - Hint highlights are a sky blue
2022-12-01 21:55:05 +00:00
toaster
b8674e35e1 Challenge tilegrid rendering fundamentals now down
- Shows 16x16 or 32x32 grey areas of checkerboarding brightness for locked
- Shows SECRET_SKIN face icons when a challenge of that type is unlocked
- Don't re-render if entry above or to the left is also that challenge (`majorunlock`)
2022-12-01 17:47:52 +00:00
toaster
8dc2b6bf81 I_Error on failed challengegrid malloc 2022-12-01 16:57:30 +00:00
toaster
1391cbe01e M_PopulateChallengeGrid
Basic challenge grid data is now generated the first time you head to the challenges menu.
- Large tiles are placed first.
    - `UINT8 majorunlock` in `unlockable_t`.
    - Builds a list of all possible positions the first large tile could be plonked at.
    - Randomly selects from that list, then removes every position that overlaps the given spot before the next large tile is handled.
- Smaller tiles are filled into all the remaining gaps.
    - Currently bubbles gaps through the random list if empty spots after large tile placement > number of small tiles to place, but all the gaps could be forced to the end.
- Has a REALLY prelim drawer, literally just enough to confirm the tilegrid data is correct visually.
- DEVELOP: Can be regenerated by pressing (C) while the challenges are up.
Also, general maintenance.
- Remove `showconditionset`, `nocecho`, and `nochecklist` from `unlockable_t` for not fitting with our new intent for challenges
- Remove M_AnySecretUnlocked - Not currently used, but its eventual use - stopping a player from seeing a completely blank challenges grid - isn't in the spirit.
- M_MapLocked no longer permits all map transitions in DEVELOP, so unlocks can actually be tested.
2022-12-01 16:04:12 +00:00
toaster
f0e5e1b71a Save gamedata once all pending unlocks have been updated 2022-11-30 19:27:26 +00:00
toaster
5ba1d4c197 Unlocks now only get marked unlocked when heading to the main menu
EXTREMELY early, but...
- M_InterruptMenuWithChallenges hijacks certain transitions
    - Currently only initial profile selection and title screen, but the intercept is low-profile enough to add wherever necessary
- M_GetNextAchievedUnlock gets the first unlock in the listing that has all its conditions achieved but isn't unlocked
- Preliminary Challenges menu
    - Currently only ticks between Achieved but not Unlocked unlocks with the above function, no tilegrid yet
2022-11-30 17:26:33 +00:00
toaster
0aa85bf291 Unused variable in Got_AddBot 2022-11-30 17:17:40 +00:00
toaster
8b1407c096 Proper MP emblem support
- Also adapted from (STJr/SRB2!1756)
- Unlike that MR, absolutely no sharing - this is a game of exclusively competitive gametypes.
2022-11-30 14:32:33 +00:00
toaster
845fe12b52 Conversion to using gamedata_t
A small piece of (STJr/SRB2!1756).
Due to how RR currently handles time attack records and how it WILL handle unlocks, it's not currently feasible to split everything such that you can have two independent gamedata_t... but what's done so far is certainly more sane and less dependent on global variables
Other minor refactors:
- M_UpdateUnlockablesAndExtraEmblems and M_SilentUpdateUnlockablesAndEmblems are now one function with a boolean for loudness
- Unlock prints are currently living in the console, since the cecho stuff was a little broken
2022-11-30 13:19:21 +00:00
Sal
4ae1309fd7 Merge branch 'cmake-fix-override-exe-name' into 'master'
cmake: let SRB2_SDL2_EXE_NAME override git branch

See merge request KartKrew/Kart!796
2022-11-30 00:55:45 +00:00
James R
3d500148cd Make Test Run the default map in DEVELOP builds
This makes testing easy by starting the game with -server
2022-11-29 16:54:31 -08:00
toaster
6a2aa87e95 Fix unlock bounds check for linedef type 319
Fix from (STJr/SRB2!1767)
2022-11-29 17:44:25 +00:00
toaster
3dc2ad64d6 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into unlockables-undefeatable 2022-11-29 17:42:33 +00:00
James R
ef442e06b7 cmake: let SRB2_SDL2_EXE_NAME override git branch
SRB2_SDL2_EXE_NAME is now "" by default. Internally
defaults to ringracers.
2022-11-28 22:02:33 -08:00
James R
07c30a20c2 Move all sources into CMakeLists.txt
Changing Sourcefile did not automatically update the CMake
cache.
2022-11-28 21:46:43 -08:00
Sal
50a1dcf979 Merge branch 'cmake-overhaul' into 'master'
cmake: Rollup of srb2-side changes

See merge request KartKrew/Kart!758
2022-11-29 04:42:58 +00:00
SteelT
7b0361a6f2 Make vsync default to off 2022-11-28 23:05:54 -05:00
toaster
bb66a536a9 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into unlockables-undefeatable 2022-11-28 22:32:13 +00:00
toaster
49c71962f5 Update linedef type 441 to only not happen in MP (or demo playback)
Only areas missed from the precursor to the "multiplayer emblems" MR
2022-11-28 22:29:36 +00:00
toaster
b074d6cbdd Fix the actual problem with saving in DEVELOP: cv_cheats didn't have CV_NOINIT
Also fixes a likely waiting-in-the-wings crash for the next time we make a non-DEVELOP build.
2022-11-28 19:21:02 +00:00
Sally Coolatta
81cefa2697 Gachabom initial pass
They simply use Kitchen Sink's item icon and Orbinaut's sprites.

The forward toss behavior needs fine-tuning to use more MT_BANANA style behavior.
2022-11-28 02:41:42 -05:00
Sally Coolatta
a0bcd52bf1 Break the Capsules HUD tracking 2022-11-28 01:47:00 -05:00
James R
404aa0b5fe Hide MT_OVERLAY with drawpickups 2022-11-27 21:19:04 -08:00
James R
479f9e4d57 S_ReducedVFXSoundAtVolume: use player_t* 2022-11-27 17:27:22 -08:00
James R
051b4f8935 Always use typedef name instead of struct name
mobj_t instead of struct mobj_s
2022-11-27 17:21:40 -08:00
James R
0d0310a140 typedef.h: typedef node_t
d_net.c: rename node_t to netnode_t
2022-11-27 17:21:40 -08:00
James R
b5310a1f68 Add typedef.h
All typedefs for structs that were present in other header
files have been moved to here. (Except node_t because the
renderer and netcode both define node_t LOL.)
2022-11-27 17:21:40 -08:00
Oni
bc2d4a2d83 Merge branch 'more-bot-crudules' into 'master'
More bot crudules

See merge request KartKrew/Kart!788
2022-11-28 01:15:45 +00:00
toaster
6d0637d39d Unlockable skins (in a way friendly to #define MAXSKINS 255)
Mammoth commit, sorry. I only realised halfway through writing it that SECRET_SKIN was only partially merged.

Ports from 2.2:
- Merge SECRET_SKIN (STJr/SRB2!1474)
    - Default skin is now handled by checking all skins for unlock status, and I_Erroring if none are available
    - Don't show skin names on game startup, to keep our secrets hidden
    - Unlockables now have string variables zallocated.
         - For skin names rather than numbers.
    - Correctly clean up memory when freeing unlockables and emblems.

Bespoke code:
- For temporary testing. `unlocks.pk3`
    - Using this for rapid testing gameboot SOC instead of patch.pk3 because of the intent to turn that into scripts.pk3
- Don't not save gamedata in DEVELOP builds, even if you've used cheats!
- `player->availabilities` is now an array of UINT8
    - (MAXSKINS + 7)/8 entries, or 32 bytes.
    - Included with XD_ADDPLAYER instead of XD_NAMEANDCOLOR.
         - Simplifies a lot of logic with respect to demos, skin changes mid-game, etc.
             - Seriously, there's a lot of random places in the code that just iterate over MAXSPLITSCREENPLAYERS and g_localplayers to update availabilities in real time in a way that's not particularly netsafe...
         - Lines up with the plan for handling unlocks when returning to menus.
         - Was included with XD_ADDBOT, but that actually overruns the netxcmd buffer at first mapload with 7 bots. We might need to consider expanding the size of the netxcmd buffer...
    - In demos, can be interpreted as both relative to the original replay and the current skin list depending on boolean context provided to R_SkinUsable.
    - Used for SF_IRONMAN (and will crash if all other skins are inaccessible).
- Grand Prix bot randomisation uses the host's unlocks.
- Don't show locked characters on the fancy new character select.
-  DXD_JOINDATA for demos
    - Replaces the dual-purpose behaviour of DXD_PLAYSTATE
    - Contains availabilities
    - Handles bot material in a different way
- Forceskin restrictions
    - Won't run in demos, because it's assumed recorded DXD_SKIN will handle all the conversions the original match had
    - Won't run if K_CanChangeRules says no
- Correctly set `mapvisited` on level visit, even in [fake gasp] MULTIPLAYER/NETGAMES!! 🥹
- Added updating unlockables and extra emblems on `mapvisited` update.
    - Currently fails to produce the cecho, but that'll be stripped out entirely in a future commit so I'm not bothered.
2022-11-27 22:53:29 +00:00
James R
ebd9ea579f Merge branch 'fix-499' into 'master'
Fix linedef type 499 binary->UDMF conversion

See merge request KartKrew/Kart!787
2022-11-27 22:14:22 +00:00
toaster
8179b39773 ForceAllSkins cleanup 2022-11-27 16:21:45 +00:00
toaster
990a3500bc SetSkin refactor for skin setting
Port from 2.2. Prevents some infinite loops caused by skin 0 being marked unusable.
2022-11-27 15:50:41 +00:00
James R
8742150f2f cmake: change library link name casing
Fixes linux mingw cross compile
2022-11-27 03:42:43 -08:00
James R
a8ccedbbc0 cmake: remove -Waggregate-return 2022-11-27 03:27:10 -08:00
James R
63069ce710 cmake: set C std and enable pedantic warnings
see d262190faf and cd5946be73
2022-11-27 03:20:37 -08:00
Eidolon
93aaa77de3 cmake: disallow in-source builds 2022-11-27 02:44:11 -08:00
Eidolon
adfbdbf10d cmake: gitignore /build
Too common of a build pattern to ignore
2022-11-27 02:44:11 -08:00
Eidolon
9fecb93c3a cmake: disable debug symbols for openmpt 2022-11-27 02:44:11 -08:00
Eidolon
757e3650eb cmake: copy build shared internal libs to bin/ 2022-11-27 02:44:11 -08:00
Eidolon
e52a13bf39 cmake: link Rpcrt4 (for uuid) to openmpt on win32 2022-11-27 02:44:11 -08:00
Eidolon
8116edc5a1 cmake: Port misc options from Makefiles
- DEBUGMODE
- MOBJCONSISTANCY
- PACKETDROP
- ZDEBUG
- PROFILEMODE (likely moot, dunno how profiling with cmake works
though)
2022-11-27 02:44:11 -08:00
Eidolon
146344e7de cmake: Port warning configuration from make
Adds SRB2_CONFIG_ERRORMODE to replace ERRORMODE too.
2022-11-27 02:44:11 -08:00
Eidolon
d31037abc9 cmake: Remove asset hashing, CMAKE_ASSETS_DIR
Simplifies build setup for cmake.

# Conflicts:
#	assets/CMakeLists.txt
#	src/config.h.in
#	src/sdl/i_system.c
2022-11-27 02:44:10 -08:00