Commit graph

360 commits

Author SHA1 Message Date
Antonio Martinez
8a87f0ed7d Apply gamestochat restrictions to voice 2025-08-27 20:38:45 -04:00
Antonio Martinez
7b39fc4b7e "Staffsync" command to test staff ghost playback 2025-08-19 18:52:13 -04:00
VelocitOni
29d1dcef2d "Deafen" and "Server Voice Chat" now have new variables
cv_voice_chat -> cv_voice_selfdeafen & cv_voice_servermute -> cv_voice_allowservervoice
2025-07-24 22:54:43 -04:00
Antonio Martinez
4af7ab2555 Lower Duel HUD, global option to disable/enable Duel 2025-06-06 21:32:37 -04:00
toaster
830cfe76da Round Queue UI on Level Select
- Only works in Match Race and Online level selects
- Shows in-progress state on Pause and Cup Grid, but no direct influence available on those screens
- Z to queue current highlighted map
    - Pending until you press A, then sent to server
    - When done online, tries to send one at a time to avoid overloading connection
- C to clear
    - Removes one from pending first
    - If you're out of pending maps, prompts whether you want to clear server's queue
2025-06-01 00:25:20 +01:00
Antonio Martinez
3d39ab5225 more Duel 2025-05-24 21:19:33 -04:00
Oni VelocitOni
82a542fe33 Merge branch 'duel-shuffle' into 'master'
Shuffle Loser

See merge request kart-krew-dev/ring-racers-internal!2278
2025-04-09 03:34:12 +00:00
Eidolon
cb7f437e60 Merge public master 2025-02-13 15:48:11 -06:00
Eidolon
a4d304a1f5 Update copyright years to 2025 2025-02-13 15:32:26 -06:00
Eidolon
22b20b5877 Add netgame voice chat
Implemented using libopus for the Opus codec, same as is used in Discord.
This adds the following cvars:

- `voice_chat` On/Off, triggers self-deafen state on server via weaponprefs
- `voice_mode` Activity/PTT
- `voice_selfmute` On/Off, triggers self-mute state on server via weaponprefs
- `voice_inputamp` -30 to 30, scales input by value in decibels
- `voice_activationthreshold` -30 to 0, if any peak in a frame is higher, activates voice
- `voice_loopback` On/Off, plays back local transcoded voice
- `voice_proximity` On/Off, enables proximity effects for server
- `voice_distanceattenuation_distance` distance in fracunits to scale voice volume over
- `voice_distanceattenuation_factor` distance in logarithmic factor to scale voice volume by distance to. e.g. 0.5 for "half as loud" at or above max distance
- `voice_stereopanning_factor` at 1.0, player voices are panned to left or right speaker, scaling to no effect at 0.0
- `voice_concurrentattenuation_factor` the logarithmic factor to attenuate player voices with concurrent speakers
- `voice_concurrentattenuation_min` the minimum concurrent speakers before global concurrent speaker attenuation
- `voice_concurrentattenuation_max` the maximum concurrent speakers for full global concurrent speaker attenuation
- `voice_servermute` whether voice chat is enabled on this server. visible from MS via bitflag
- `voicevolume` local volume of all voice playback

A Voice Options menu is added with a subset of these options, and Server Options has server mute.
2024-12-13 17:12:14 -06:00
Oni
d9bf5d26dd Merge branch 'rqdx' into 'master'
Roundqueue DX

Closes #1411

See merge request KartKrew/Kart!2473
2024-10-20 18:52:35 +00:00
Sally Coolatta
5dd41db100 Add CVar for loser shuffle 2024-10-18 14:58:58 -04:00
Sal
323452df73 Merge branch 'vote-anger-fix' into 'master'
Fix map anger race condition

See merge request KartKrew/Kart!2447
2024-10-18 01:13:42 +00:00
toaster
512ec6c2eb XD_REQMAPQUEUE --> PT_REQMAPQUEUE
It was technically possible for custom clients to spoil future rounds of a tournament queued while they are connected to a server.
Making it a PT direct packet to the servernode both solves this problem AND reduces irrelevant NetXCmd traffic for clients.
2024-10-11 13:46:26 +01:00
toaster
8bd50ddb65 clearscores is now setscore
- `setscore 0 50` will set the player in slot 0's score to 50 points
- `setscore 0 50 -add` will add 50 points to their score
- `setscore -clear` will clear all players' score, as per the old function
- Command will error if PWR is in use (no roundqueue/`usepwrlv 0`/cheats off in GP)
- The previous cheat `setscore` is renamed to `setroundscore`
2024-10-11 13:40:11 +01:00
Sal
653766010d FRIENDCODE (aka, Teamplay) 2024-09-17 01:41:26 +00:00
Sally Coolatta
3020f9c3ef Fix map anger race condition
Was making angry maps never actually get picked. Dang.
2024-09-02 04:20:39 -04:00
AJ Martinez
683f5016fb Level Skull 2024-05-03 20:15:21 -07:00
Sally Coolatta
7dfa597c7d SRB2 -> DRRR copyright in src, acs, android folder
Be consistent with toaster's recent changes to copyright
2024-04-05 02:08:23 -04:00
toaster
dea698a276 Tasteless Taunts
Uninhibited voices/horns (see the "meme" setting in v1).
Removes the SECRET_MEMETAUNTS unlock, which didn't fit the general level of cohesion main game content should have.
2024-04-02 23:26:57 +01:00
James R
28cd56f24c Add cheats
Co-authored-by: toaster <rollerorbital@gmail.com>
Co-authored-by: AJ Martinez <aj@worldsbe.st>
2024-03-28 00:09:12 -07:00
James R
11dc5b7318 Fix line endings 2024-03-28 00:09:02 -07:00
AJ Martinez
ec2a685475 Remove residual cvar 2024-03-22 20:53:04 -07:00
James R
5fbb32442b Fix Alternate Title Screen unlockable not saving preference
- Remove CV_NOSHOWHELP, so the config file can load
- Do not stealth set the cvar, so it is not dependent on
  order of operations of config loading and challenge
  loading
2024-03-03 22:20:12 -08:00
Oni
d631f62da9 Merge branch 'bot-hold-instawhip' into 'master'
Bot behavior for charged instawhip

Closes #1035

See merge request KartKrew/Kart!1974
2024-03-03 08:07:39 +00:00
AJ Martinez
81bb3500a4 Merge remote-tracking branch 'origin/master' into shitty-signs 2024-03-02 04:32:05 -07:00
AJ Martinez
47a9cce133 Add shittysigns cheat 2024-03-02 04:27:41 -07:00
AJ Martinez
840c8d497e Bot behavior for charged instawhip 2024-02-29 21:46:29 -07:00
AJ Martinez
d4d426e64b Add "let's get fired up!" cheat (4th Gear) 2024-02-29 17:43:07 -07:00
James R
4ee00d4333 Pass const pointer to all netxcmd handlers
Ensure buffer data is read-only and not modified by
handler
2024-02-11 05:42:07 -08:00
AJ Martinez
0c6820b350 "mental sonic" cheat 2024-01-23 00:28:08 -07:00
AJ Martinez
cd638fd5e2 Move screenshake adjustments to "screenshake" cvar 2023-12-30 16:22:04 -07:00
James R
b6c7a42a97 Pause menu: changing gametype goes to vote screen
- If you change it during the vote screen, voting
  restarts.
2023-12-06 00:00:54 -08: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
c194ccb81a Remove more unused cvars
- respawnitem
- respawnitemtime
- respawndelay
- startinglives
2023-08-25 17:18:21 -07:00
James R
0a9d15ceb0 Remove remnants of LJOYSTICK 2023-08-24 04:34:19 -07:00
AJ Martinez
7a2841c407 "debugstart" cvar to skip POSITION/intro 2023-08-12 15:35:10 -07:00
AJ Martinez
4b0a9ce7a6 Register the fucking cvar 2023-08-07 19:19:59 -07:00
AJ Martinez
1cdb498862 DEVELOP cvar to turn off encore palettes (readability testing) 2023-08-07 19:06:21 -07:00
toaster
36e0a23c09 Remove console script support from maps
The linedef's behaviour was broken horribly by long map names, and it's not worth the effort to fix it for the following reasons.
- It was considered a security vulnerability to have free access to the console when it was written.
- The game literally had a cvar to disable running console scripts. That's "I am willingly distributing ActiveX Word Documents in 2023" levels of foolhardery.
- Anything GOOD it can do, both Lua and ACS can do better.
2023-07-12 16:32:23 +01:00
toaster
e7ee979f1a Horncode
A much more focused replacement for Hornmod, specc'd out by Tyron and Oni working together and implemented by the author of this commit because it's pretty funny.

- Followers have `hornsound` in their SOC configuration.
    - The default sound for all followers without a provided one is sfx_horn00.
- They'll play this sound if you use lookback with one following you, and there's nearby players to get the player looking all the way around.
    - Only the players who are successfully considered for lookback will hear it.
- Has a v1-like visual with less randomisation, but still netsynced.
- Also controlled by the cvar `taunthorns`, which, like `tauntvoices`, takes "Tasteful" (default), "Meme", and "Off".

TODO: make the condition for horn a little delayed, so you have to hold lookback for a little bit.
2023-06-28 17:54:23 +01:00
Oni
1217934693 Merge branch 'zvote-menu' into 'master'
Call Vote + Admin Tools Menus

See merge request KartKrew/Kart!1303
2023-06-28 00:24:32 +00:00
toaster
ec8a6247c2 Z-vote is now server-authoriative
- Only calls callback if you're the server (and not demo.playback, forward thinking for stored xcmd netreplays)
- G_GamestateUsesExitLevel() for homogenising the conditions that permit XD_EXITLEVEL to be dispatched and recieved
2023-06-27 14:16:48 +01:00
AJ Martinez
0a6bac0dcc Ringbox: HUD, transform time define, ring-box-only, scaling rewards 2023-06-26 17:36:41 -07:00
Sally Coolatta
724beb0ffe Bots: Improve rubberbanding further
- Use easing functions for the rubberbanding values themselves, for more fine-control over the end-points and the curves.
- Fixed K_UpdateRubberband being broken from using shift instead of divide.
- Rename `debugbotpredict` to `debugbots`, it now displays some of the bots' botvars values as well. If the player isn't a bot, it will show them from the first place bot (for inspecting the rubberband value).
- Bot turning buff was increased, from x1.25 to x2.0. Noticed that Tails bots were failing turns on Popcorn Workshop. I personally think that Tails bots shouldn't be failing very many turns unless if they're finding objects, and constant wall-bumping should be reserved for Eggman and Metal :P
2023-05-19 01:00:55 -04:00
toaster
b72bc73d28 Two new command automation events
- "QueueStart"
    - Activates just before RoundStart, but only if a roundqueue is being started
- "QueueEnd"
    - Activates just before IntermissionStart, but only if the roundqueue has just finished its final map
I chose before in both instances because Automate_Run runs off COM_BufAddText, and I don't completely trust that the buffer won't overflow for particularly complicated server commands, so prioritising the rarer event. However, this is open for discussion
2023-05-03 22:08:13 +01:00
toaster
ab68be49e1 cv_antigrief
- Increments a timer on human players who aren't making progress, does it even faster if they're going backwards.
    - Only applies in:
        - Netgames
        - GTR_CIRCUIT after the timer starts
        - If there's no timelimit, pointlimit, or K_Cooperative (because unproductive behaviour there will be punished by other rules)
    - The rate at which this changes needs trial and error, but getting the feature functional is more important to start out with.
- If this timer reaches cv_antigrief's value in seconds , the player gets a "Grief Strike"
    - This doesn't happen if:
        - There's only one active player in the server, so FREE PLAY permits mappers to test what increments/decrements the counter
            - Turn `debugwaypoints` on to observe this
        - The cvar is set to 0
    - Less than 3 grief strikes is a forced spectate
    - Anything more is a kick via "automatic grief detection"
        - Unless your node is the host (or an admin)
    - Remove grief strike strike for finishing normally

# Conflicts:
#	src/d_clisrv.h
2023-05-01 16:57:35 +01:00
toaster
15b0141700 Spectator re-entry timer
- On becoming a spectator in a netgame, there is a delay before you can de-spectate.
    - 30 seconds by default.
        - This can be changed using the cvar `spectatorreentry`.
    - ...unless there's only two people left including you, in which case it's three minutes!!
        - This can be changed using the cvar `duelspectatorreentry`.
        - If spectatorreentry is set to greater than duelspectatorrentry, the former is used instead.
    - This timer is wiped on mapload and intermission, so NEW CHALLENGER APPROACHING !! and level changes in general allow people in.
- General purpose cleanup of K_CheckSpectateStatus
2023-05-01 16:57:34 +01:00
Sally Coolatta
996ca9adad Z Voting 2023-04-20 15:55:38 -04:00
toaster
2d46112c58 Merge branch 'master' of https://git.do.srb2.org/KartKrew/Kart into round-queue
# Conflicts:
#	src/d_netcmd.h
2023-04-17 20:08:37 +01:00