Feature: leaderboard hide, ability animations, card sounds, BGM, in-game settings

Server:
- Account.IsHiddenFromLeaderboard: filter bots/devs from leaderboard
- AbilityAnimationDefinition: type, effect, dimensions, asset/sound URLs per ability
- CardAnimationBinding: CastSoundCdnUrl + ImpactSoundCdnUrl per card action
- GameAudioConfig entity: admin-configurable BGM tracks per context
- GetGameAudioConfigHandler (content.get_audio_config) + ServiceRegistration
- Admin pages: AccountDetail toggle, AudioConfig CRUD, CardEditor + AbilityBuilder UI
- Migrations: AddLeaderboardHide, AddCardActionSounds, AddGameAudioConfig

Client:
- Music.gd autoload: fetches BGM config, crossfades between context tracks
- InGameSettings overlay: audio sliders, camera follow toggle, concede with confirm
- GameScreen: gear button opens settings; ConcedeBtn moved into settings panel
- project.godot: Music autoload registered

Generated with [Claude Code](https://claude.ai/code)
via [Happy](https://happy.engineering)

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Happy <yesreply@happy.engineering>
This commit is contained in:
dingo
2026-03-13 23:31:10 -04:00
co-authored by Claude Happy
parent c44dadec45
commit 3810742fe6
27 changed files with 1086 additions and 25 deletions
@@ -32,5 +32,11 @@ public sealed class CardAnimationBinding
/// </summary>
public bool IsAiGenerated { get; set; }
/// <summary>CDN URL to the sound played when this action begins (e.g. cast, attack swing).</summary>
public string? CastSoundCdnUrl { get; set; }
/// <summary>CDN URL to the sound played on impact or effect resolution.</summary>
public string? ImpactSoundCdnUrl { get; set; }
public CardDefinition CardDefinition { get; set; } = null!;
}
@@ -0,0 +1,26 @@
namespace SOR.Database.Entities.Catalog;
/// <summary>
/// Configures a background music track for a specific game context.
/// Contexts are free-form strings matched by the client (e.g. "Lobby", "Game", "Matchmaking").
/// Multiple tracks per context are allowed; the client picks one at random or plays them in order.
/// </summary>
public sealed class GameAudioConfig
{
public Guid Id { get; set; } = Guid.NewGuid();
/// <summary>
/// Scene/context identifier as expected by the client.
/// Examples: "Lobby", "Game", "Matchmaking", "CharacterSelect".
/// </summary>
public string Context { get; set; } = string.Empty;
/// <summary>Human-readable name for the track (shown in admin UI).</summary>
public string TrackName { get; set; } = string.Empty;
/// <summary>CDN URL to the audio file (mp3, ogg, etc.).</summary>
public string TrackCdnUrl { get; set; } = string.Empty;
/// <summary>When false, the track is excluded from the client response.</summary>
public bool IsActive { get; set; } = true;
}
@@ -44,4 +44,10 @@ public sealed class Account : IdentityUser<Guid>
/// Starts at 1000. Adjusted after each ranked game using K=32 factor.
/// </summary>
public int RankScore { get; set; } = 1000;
/// <summary>
/// When true, this account is excluded from the public leaderboard.
/// Use for bots, dev accounts, and internal test accounts.
/// </summary>
public bool IsHiddenFromLeaderboard { get; set; }
}