Skip to content

Add sprays#388

Merged
GooberRF merged 7 commits into
masterfrom
sprays
Jul 12, 2026
Merged

Add sprays#388
GooberRF merged 7 commits into
masterfrom
sprays

Conversation

@GooberRF

@GooberRF GooberRF commented Jul 12, 2026

Copy link
Copy Markdown
Owner
  • Fix overlapping decals rendering with the oldest on top instead of the newest
  • Add sprays with bindable Spray control
    • cl_sprays console command to toggle local display and dedicated server [sprays] config section
    • spray console command to select spray, and in-game spray picker in advanced options

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new “sprays” feature (client/server support, configurable enable + cooldown, bindable control, console commands, and an in-game spray picker), and also fixes overlapping decal rendering so newer decals draw on top.

Changes:

  • Implement sprays end-to-end: gameplay action, networking packets/state sync, server config gating + cooldown enforcement, and client-side decal creation with sound.
  • Add UI/UX for selecting sprays (options panel button + modal spray picker) and persist selection/toggle in player settings.
  • Fix decal draw order by changing decal poly insertion to render newest decals on top, and ensure spray state is cleared on level transitions / disconnects.

Reviewed changes

Copilot reviewed 31 out of 42 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
resources/licensing-info.txt Adds attribution for the new spray sound asset.
resources/CMakeLists.txt Packs new spray audio and decal texture assets into the VPP.
game_patch/sound/sound.h Exposes a helper to retrieve the spray sound ID.
game_patch/sound/sound.cpp Registers the spray sound and caches its resolved sound ID.
game_patch/rf/player/player.h Adds per-player spray cooldown timestamp storage.
game_patch/rf/player/control_config.h Adds a new bindable control action for spraying.
game_patch/rf/geometry.h Adds engine function reference for decal destruction.
game_patch/multi/sprays.h Declares the new sprays feature interface.
game_patch/multi/sprays.cpp Implements spray decal creation/rendering, server validation/cooldown, state sync, and decal order fix hook.
game_patch/multi/server.h Exposes sprays config accessors for other subsystems.
game_patch/multi/server.cpp Implements sprays enable/cooldown accessors and avoids spawning spectators.
game_patch/multi/server_internal.h Adds dedicated server [sprays] configuration structure.
game_patch/multi/network.h Adds join-accept feature flag to advertise sprays support.
game_patch/multi/network.cpp Sends/consumes allow_sprays flag and syncs spray state for late joiners.
game_patch/multi/multi.h Stores allow_sprays in server info for clients.
game_patch/multi/multi.cpp Installs the sprays patch as part of MP patch initialization.
game_patch/multi/lms.cpp Excludes spectators from LMS “enough players loaded” logic.
game_patch/multi/kill.cpp Clears spray state on level init.
game_patch/multi/dedi_cfg.cpp Parses/prints dedicated server [sprays] config settings.
game_patch/multi/alpine_packets.h Adds new client/server request payloads and flags for sprays.
game_patch/multi/alpine_packets.cpp Serializes/deserializes spray packets and applies received sprays client-side.
game_patch/misc/ui.cpp Adds “Select spray” control in advanced options and routes input to the spray picker modal.
game_patch/misc/spray_picker.h Declares the spray picker modal interface.
game_patch/misc/spray_picker.cpp Implements the spray picker modal (layout, scrolling grid, selection).
game_patch/misc/player.cpp Clears per-player spray state on disconnect/destroy.
game_patch/misc/alpine_settings.h Adds spray display/selection settings and clamps selection by available count.
game_patch/misc/alpine_settings.cpp Loads/saves spray display + selection to the player settings file.
game_patch/main/main.cpp Renders the spray picker each frame.
game_patch/input/key.cpp Adds default keybind + dispatch path for the new Spray action (including high action indices).
game_patch/CMakeLists.txt Adds new sprays and spray picker sources to the build.
docs/CHANGELOG.md Documents sprays feature and decal rendering order fix for 1.4.0.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread game_patch/multi/sprays.cpp
Comment thread game_patch/multi/sprays.cpp
Comment thread game_patch/multi/sprays.cpp
Comment thread game_patch/multi/sprays.cpp

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 31 out of 42 changed files in this pull request and generated 3 comments.

Comment thread game_patch/input/key.cpp Outdated
Comment thread resources/licensing-info.txt
Comment thread game_patch/multi/sprays.cpp

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 31 out of 42 changed files in this pull request and generated 4 comments.

Comment thread game_patch/multi/sprays.cpp
Comment thread game_patch/multi/sprays.cpp Outdated
Comment thread game_patch/misc/alpine_settings.h
Comment thread game_patch/multi/sprays.cpp

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 31 out of 42 changed files in this pull request and generated 1 comment.

Comment thread game_patch/multi/sprays.cpp
@GooberRF GooberRF marked this pull request as ready for review July 12, 2026 09:52
@GooberRF GooberRF requested a review from Copilot July 12, 2026 09:52

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 31 out of 42 changed files in this pull request and generated 2 comments.

Comment thread game_patch/multi/sprays.cpp
Comment thread game_patch/multi/sprays.cpp
@GooberRF GooberRF merged commit a08ae77 into master Jul 12, 2026
5 checks passed
@GooberRF GooberRF deleted the sprays branch July 12, 2026 10:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants