I meant to fix the previous method, but I didn't even understand how it knew it was in a vote or not... so I just did it my own way :V
(Shouldn't FLUSHMAPBUFFEREARLY be on now...?)
Shadowed declarations
Unsuffixed float constants
There's an unsuffixed float constant I can't fix because the define is outside of SRB2. We could have our own copy of Pi if we really wanted.
* Use CV_NOSHOWHELP as an obstacle for CV_CompleteVar (so the hidden variables don't show up and ruin our party or anything).
* Hack around the karteliminatelast thing so we don't have to hex-edit the netids, and can release with current assets (but a different executable, of course, to get the credits).
* Fix M_HandleConnectIP not saving your current position on the menu if you use it while it's empty.
- Swap order of Silver & Gold, for menu appearances & bug fixing
- Ensure that totalplaytime and matchesplayed aren't kept when M_ClearSecrets getss called in M_EraseDataResponse
- Set sensible defaults for emblem sprite/color
* Make the maximum number of staff ghosts 99 instead of 100. It's a minor thing, and insignificant in the grand scheme of things, but it fixes a bugbear I haven't been able to get out of my head since originally starting to maintain this code. (In the case of 100, it'd do S00, which'd have some fucky effects on ordering. If we WANTED to start with S00, we shoulda used that slot in the first place.)
(Huge change: NO_MIDI is now a define, simply because that makes it easier for me to resolve merge conflicts if I can see the original code and the new code. Also means that people who REALLY miss MIDI can compile & fix it themselves :P)
* Rename "suicide" command to "respawn" so the game doesn't tell you to kill yourself when you try to get help for it.
* Add a "manual" command to open the manual.
Also: Remove playercolor being set to the replay's color. No need to kill your settings, seeing as it makes no tangible effect on your replay (doesn't even lose colour when you die, so I don't even know...)
* Oni's new 1x Bumpers and Out-Of-Bumpers competition-style 'X'!
* Modify alignment for `GOTITx` emblem drawing to match new Chaos Coin sprites.
* Adjust m_cond.c list to use new Chaos Coin Emblem sprite slots.
* Do that thing where the character icons are ALWAYS 1x sized, through having two seperate lumps.
* Revamp the S_SKIN parameters to be `facerank` (rankings - equivalent of half-scale old face), `facewant` (WANTED - equivalent of old face), and `facemmap` (equivalent of old iconprefix).
* Do that thing Oni wanted where it shows two postions above and two positions below your current ranking (and you) to the left of the screen, instead of always the top 4, with some limits to avoid drawing outside of everything.
* Replace the last few shitty Mario numbers (for the left rankings) with cool, new Oni numbers.
* Change a bunch of offsets and things so the tab rankings and the intermission work nicer with 9+ players.
* gr_md2 on the menu.
* Disable interpolerated model option completely for now.
Also, tweaked the GL menus a bit to suck less, since I was ferreting around in that area.
Learned the cause of the seemingly random crashes it causes; doesn't seem easy to fix, so it can stay a relatively-unknown console command until it does
* Fixed the conditionals for `suicide` and `retry` commands - `suicide` is now allowed in singleplayer, and `retry` no longer checks your lives (for now).
* Disable the "traditional" level reload method (which `retry` tried to use), since it was completely broken with the other changes we've made. Mapchanges only.
* Made retries cause a mapchange, per the above.
* Disable the last source of skincolor trampling in the game - loading a level while not netgame or record attacking.
The Menu Queen is in the house~ ✨
* Magical, single-page player select and general netgamey stuff, while still remaining both pretty and functional.
* Death to NOFOURPLAYER, now that the cat's out the bag.
* Clean up NONET, assuming people try to make DD builds on release.
* Minor tweaks across the board, mostly places where I wanted to pilfer minor code from and realised it wasn't done optimally originally.
* Multiplied rain speed by 3, per Oni's request.
* Disable weather density - force to 1 if weather draw distance, otherwise zero
* Move the ceilingpic check into a more convenient part of the weather spawning loop.
* `drawdist_precip_cons_t` - replaces "Infinite" with "None".
* Disable the lowest normal draw distance (256), given... both kart and srb2 are basically unplayable like that.
* Disable cv_drawdist_nights entirely.
Also: temporarily cleaned up the M_CanShowLevelInList record attack conditions to automatically match what we want, instead of requiring us to apply a bunch of vanilla flags just to emulate our "available unless explicitly hidden" MP mechanism like is currently in maps.kart.
You can now remap Change Viewpoint, Screenshot, and Toggle GIF Recording to other keys, mainly for gamepads
They also pushed me to my breaking point and I couldn't tolerate the control menu anymore, thanks to toaster for the scrolling backport
* S_Init -> S_InitSfxChannels because it did mostly SFX anyway
* S_MusicPlaying, S_MusicPaused, S_MusicName, S_MusicExists new status methods
* I_MusicPlaying, I_MusicPaused
(cherry picked from commit f5f0b5e76c2fd405c8cc895dde653c5ed2652622)
* Add `kartvoterulechanges`, or "Voting Rule Changes" on the menu, to allow some user control over event frequency.
* "Never" - does what it says on the tin.
* "Sometimes" - 1/8 chance of Encore if host has unlocked it, only gametype change when buffer is full
* "Frequent" - 1/2 chance of Encore if host has unlocked it, gametype change every 5 maps
* "Always" - If host has unlocked Encore, alternates between Encore and Gametype. Otherwise, always a gametype change
* There's probably room for a setting between "Sometimes" and "Frequent", but I didn't want to overload the host with options and these were the ones that made sense.
* Better handling of buffer refreshes, to prevent two of the same map appearing next to each other in the voting unless there literally aren't that many maps.
* Mostly unrelated: Minor bugfix for Y_SetupVoteFinish, preventing music changes/random sounds playing on the You Will Join Next Race screen. (Branch-appropriate, at least.)
* Some visual ordering fixes for the item menu, plus a #define-toggleable option for the bottom right slot to be traversable for ease-of-use purposes (even if it doesn't do anything).
* Uses the in-game timer element to draw its times.
* This includes showing them time emblems-to-get!
* good night sweet prince
* Make the emblem time use the same ' and " as the normal time.
* A better representation of an Encore level, now with inverted graphics (a special remapping we can now use elsewhere whenever if we want!) and a floating Ruby!
* Decouple encore's setting from cv_kartencore on mapload. Instead, bake it into D_MapChange and related, which will only some of the time be fed by cv_kartencore's value.
* Encore mode now has a special mapheader palette setting, "encorepal", rather than using the same one as non-encore.
* HOWEVER, we should seriously address this again later, because the antialiasing DOES result in some unfortunate bullshit...
* Encoremap maces per Oni's request and Sal's suggestion
* Make unlockables have a "showing" conditionset, for when you're able to see them on the Extras screen.
* A shorter Encore ruby-pulse fade, for when encore mode is already active!
* Fix minor additional error in tab rankings.
* Remove FREE PLAY from intermission drawer, per Sal's request.
* Remove "second%s" from the end of the "Start in %d"/"Vote ends in %d" string.
* Rename cv_advancemap's "Off" value to "Same", to make the behaviour clearer.
* Make the "Start in %d" string now begin with cv_advancemap's string (ie, "Vote in %d", "Same in %d", "Random in %d, Next in %d"...
* "kartvoices" cvar. Possible values "Never", "Tasteful" (default), and "Meme".
* Added a way to move quickly through the credits, rather than skip them entirely (hold spacebar or down arrow).
* Fix a few mistakes in M_ChangeCvar, some of which I introduced and some of which were weird in the first place.
* Tweak the offset of the arrows that let you know you can modify a cvar by pressing left or right (some via a patch.kart change, but others via tweaking the drawing location).
These are both huge boons for gamepad functionality. If we can add a way to add a menu key, then all of the controller requirements for v1 will be covered.
* Palette remaps.
* Branding.
TODO:
* Doesn't work in GL. (Mostly.) I have SOME ideas on how to tackle this, but...
* Transmaps are broken in Encore for some reason.
* I tried to make in-level colormaps shimmy over, but it didn't quite work, so I commented it out and only semi-fixed it.
* Stop respawning spectators when their PF_WANTSTOJOIN request hasn't been processed yet.
* Handle PF_WANTSTOJOIN requests in GS_WAITINGPLAYERS.
* Refactor K_CheckSpectateStatus, and make it so PF_WANTSTOJOIN requests are processed if there's only one player in the server, even if they're on lap 2 or up.
* Make the player entry mechanism in P_SpawnPlayer use the PF_WANTSTOJOIN mechanism so that it can also take advantage of the level refresh mechanism with no extra code.
* NOTE: This does a bad hack in order to not send multiple mapchanges while the joining timer is low! If you can think of a better way to do this, please let me know/commit it.
* Change the timer until you can hit ITEM again when a spectator who has to wait to join shorter.
* (controversial, but I think necessary) - flash the ITEM text when the above-mentioned timer is nonzero.
* Record Attack Input display!
* Show Record Attack emblem and emblem time on the HUD! Changes colours with the player, just like vanilla internal's.
* Remove the ugly dark blue box on the singleplayer (including pause screen) whose only purpose in Kart was to contain the Record Attack emblem info!
* Unrelated shit!
* Improve loading Kart HUD graphics.
* Fix mirrored HUD graphics being one screen pixel (not basevid pixel) offset.
* Remove FUNCMATH from all void-returning functions, given GCC80 specifically complains about this case.
* Extend the length of all extant buffers to the safety threshold recommended by the compiler.
* Add void casts to WS_getaddrinfo's setting to prevent complaints about incompatible typecasts.
* Extend the charsel, face, and superface buffer sizes and writes to include the null terminator. (I didn't really want to do this because it's not even particularily NEEDED, but there was literally zero way to get around the request that I could find with multiple online searches. I tried.)
Updated my compile setup to GCC 6.3, makes it as far as m_misc.c now with ERRORMODE and DEBUGMODE, stops at some gettext related stuff I don't know how to fix now
* Make MT_GHOST's dispoffset -1, so that at the starting line in record attack your player is always visible even when you have multiple ghosts in play.
* Fixed the issue where your runs would be saved as belonging to the wrong character.
* Make the Ghost menu always visible. This isn't PERFECT, but it's better than hiding the option to toggle ghosts just because you're doing your first run as a new character.
* Fix the number of laps carrying over from MP(!!!!!!!!! plugged a huge security hole for the authenticity of replays...)
Other stuff!
* Hide map hell maps in the statistics.
* Clean up some nonet stuff in the menu.
* Put player setup last again, and tweaked its wording.
* Disable the special Kart waiting for players behaviour when not playing a netgame - seeing a double gamestate transition in record attack is weird.
* Fix all the bugs with skin not being set properly or kept synchronised with the multiplayer setup in record attack.
* Reduce the amount of flashing on the voting screen.
* Do the gametype change stuff on the voting screen.
* Make all the picking sound and setting stuff one function, rather than in two seperate places that need to be kept identical.
* Have the timer at the bottom be the highlight colour.
* Map hell! LF2_HIDEINMENU is craftily reused...
* Less allocation and deallocation for the adjacent G_RandMaps.
Other stuff...
* Fix command_map_f not resetting players' score in battle.
* Shiny titlescreen!
* Fix a random bonus newline in one of the quit messages.
More menu/highlight things:
* Rename "Default" to "Game type", to make clearer what it's doing.
* Tweak race colouring slightly.
* Put a highlight around the level select icon, and make it consistent with voting.
* Allow setting the highlight colour to affect the intermissions.
* Fix bug with gametype colour getting for record attack.
A handful of skincolour things:
* Rename Turqouise to Aqua, because it resembles one of my fav 2.2 colours with that name.
* Fix incomplete Steel Blue -> Steel rename.
* Merge the very similar Blueberry and Sapphire...
* ... so Sapphire can be backported!
* And Ruby too.
* Center level selection.
* Re-work Record Attack screen.
* Re-order MP Main menu, hide in NONET.
* Combined yeeeah on vote screen.
* Colour gametype on tab and tally.
* (unrelated) Don't show "CHECK" if exiting.
* Bar of levels.
* Colourisation!
* New V_SKYMAP, which hasn't been put in dehacked lists but is otherwise valid!
* New single page statistics screen!
* V_DrawFixedPatch now works at the edge of the screen!
Ghost fixes!
* On minimaps!
* Free memory after use!
* Don't spawn in midair on slopes!
* Lots of menu changes!
* Little arrows next to changeable cvars!
* Show default value for sliders!
* Pretty pretty pretty.
* I don't know how to describe some of these changes.
* Effectively nuke MIDI music support!
* Skiddown at the start of a race is more interesting!
* Spinning in waterslides!
* Tiny bugfix in voting, plus a little celebration...
* Improve control menus significantly - a more layout-neutral, gameplay importance based order, with spacing, and less depth to get to the important stuff.
* Port over the improved MP main menu from internal, including flattening the IP connect onto its level.
* Allow for selecting the number of splitscreen players using a menu option, rather than three seperate menu choices.
* Improve the layout of all of the level/gametype select menus slightly.
* (unrelated) Make fourth player area in 3p splitscreen use the tiling background instead of a pure black area.
* (unrelated) Tweak minimap ordering slightly.
* Combine the numlaps and usemapnumlaps functionality on the menu into basenumlaps, which numlaps is set to every race start, except when it's map default value (0) in which case it loads the map's lap count.
- Secrets renamed to Extras
- Extras leads to the checklist instead of another menu
- Credits & Sound Test are on the Options menu now
- New title screen cheat for unlocking everything ("banana", or "← ↑ → →
↑ ← ↓ → Enter")
BUT with more tweaks on top of that:
- matchesplayed can go up & unlock stuff regardless of modifiedgame
- votetime added to menu
- flame jets are fullbright (been meaning to do this for a while)
- screenshots are prefixed with kart instead of srb2 (ditto)
No more weapon number buttons, button constants reordered, and BT_JUMP
renamed to BT_DRIFT, and removed a lot of commented out stuff or stuff
we didn't need. Spectator-only support for looking up/down soon.
Keyboard defaults are just what I use, plan on adjusting it further
after more feedback
- Record Attack replays now save best lap time
- Removed instances of NiGHTS Attack
- Removed a lot of unlockable that have no use in Kart (ultimate mode,
perfect bonus, score emblems, etc)
- Removed all methods of activating ultimate mode
- Menus now have all of the Kart cvars
- Removed any cvars that aren't useful for Kart from the menu (they
still exist in the console, though)
- Removed SP and NiGHTS Mode options from the main menu
- "kartcc" is renamed "kartspeed", uses values 0-2 instead of multiples
of 50, or the terms "Relaxed", "Standard", and "Turbo"
- Many gametype options (game speed, frantic, mirror, & karma comeback)
are now changed on map load instead of instantly
- New cvar, "kartminimap", for disabling the minimap
- The maxplayers cvar now actually matches up with our 16 player limit
- Game now keeps track of matches played. Has a condition type
associated with it, as well.
- Game checks for unlocks and saves gamedata when finishing a match,
even in MP
- Removed most of the normal emblems, added a single emblem for Green
Hills. Didn't know what to do with extra emblems and such so I just left
them (FOR NOW c:<)
There's a small fix for V_DrawFixedPatch that makes it account for scale when blacking out the rest of the screen, for when scale is 50% or 25%, but can theoretically work with any scale