Commit Graph

37 Commits

Author SHA1 Message Date
Copilot
d9d26d0523 feat(statistics): store ranked_score & total_score under classic scoring mode (#68)
* Initial plan

* feat(calculator): add classic score simulator and scoring mode support

- Add ScoringMode enum with STANDARDISED and CLASSIC modes
- Add scoring_mode configuration to game settings
- Implement GetDisplayScore function in calculator.py
- Add get_display_score method to Score model
- Update score statistics to use display scores based on scoring mode

Co-authored-by: MingxuanGame <68982190+MingxuanGame@users.noreply.github.com>

* fix(calculator): apply scoring mode to TotalScoreBestScore delete method

- Update delete method to use display score for consistency
- Ensures all UserStatistics modifications use configured scoring mode

Co-authored-by: MingxuanGame <68982190+MingxuanGame@users.noreply.github.com>

* refactor(calculator): address code review feedback

- Move MAX_SCORE constant to app/const.py
- Implement is_basic() as method in HitResult enum
- Move imports to top of file in Score model
- Revert TotalScoreBestScore storage to use standardised score
- Apply display score calculation in tools/recalculate.py
- Keep display score usage in UserStatistics modifications

Co-authored-by: MingxuanGame <68982190+MingxuanGame@users.noreply.github.com>

* chore(linter): auto fix by pre-commit hooks

* Don't use forward-ref for `ScoringMode`

* chore(linter): auto fix by pre-commit hooks

* fix(calculator): update HitResult usage in get_display_score and adjust ruleset value in PerformanceServerPerformanceCalculator

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: MingxuanGame <MingxuanGame@outlook.com>
2025-11-08 20:56:29 +08:00
MingxuanGame
33f321952d feat(custom-rulesets): support custom rulesets (#23)
* feat(custom_ruleset): add custom rulesets support

* feat(custom-ruleset): add version check

* feat(custom-ruleset): add LegacyIO API to get ruleset hashes

* feat(pp): add check for rulesets whose pp cannot be calculated

* docs(readme): update README to include support for custom rulesets

* fix(custom-ruleset): make `rulesets` empty instead of throw a error when version check is disabled

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* chore(custom-ruleset): apply the latest changes of generator

c891bcd159

and

e25041ad3b

* feat(calculator): add fallback performance calculation for unsupported modes

* fix(calculator): remove debug print

* fix: resolve reviews

* feat(calculator): add difficulty calculation checks

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-26 21:10:36 +08:00
MingxuanGame
8790ccad64 feat(pp-calculator): support other pp calculators (#57)
New configurations:

- CALCULATOR="rosu": specific pp calculator
- CALCULATOR_CONFIG='{}': argument passed through into calculator
2025-10-18 19:10:53 +08:00
MingxuanGame
38671cd471 feat(user): implement /users/{user_id}/beatmaps-passed
close #9
2025-10-04 09:52:15 +00:00
MingxuanGame
dfd656f2fb style(project): remove from __future__ import annotations 2025-10-03 17:15:41 +00:00
MingxuanGame
8d9f1d2750 feat(ranking): support team ranking 2025-08-26 10:51:31 +00:00
MingxuanGame
545fc9e0c6 fix(recent_activity): fix rank & achievement event
运行 tools/fix_user_rank_event.py 修复现存的 event
2025-08-22 11:00:36 +00:00
MingxuanGame
598fcc8b38 refactor(project): make pyright & ruff happy 2025-08-22 08:21:52 +00:00
咕谷酱
ce465aa049 整理代码 2025-08-22 05:57:28 +08:00
咕谷酱
49ac399180 fix Failed to refresh user cache after score submit 2025-08-22 00:25:58 +08:00
MingxuanGame
6ac9a124ea feat(tools): add tools to add daily-challenge 2025-08-20 08:59:14 +00:00
MingxuanGame
1c65b21bb9 refactor(app): update database code 2025-08-18 16:37:30 +00:00
MingxuanGame
219f19d623 feat(beatmap,score): support failtime & more exact playtime 2025-08-18 08:48:13 +00:00
MingxuanGame
e1d42743d3 feat(chat): support BanchoBot 2025-08-16 10:31:46 +00:00
MingxuanGame
d87839f86e fix(ranking): fix missing user causing client crash 2025-08-15 06:34:35 +00:00
MingxuanGame
1251ba31a2 feat(score): support rx for taiko & catch 2025-08-15 05:59:21 +00:00
MingxuanGame
46a1d049fe refactor(score): replace MODE_TO_INT INT_TO_MODE with int(mode) GameMode.from_int 2025-08-14 13:04:59 +00:00
MingxuanGame
69e9927ea0 fix(score): fix incomplete statistics in leaderboard & wrong statistics in replay 2025-08-13 04:01:19 +00:00
MingxuanGame
efc784d903 feat(score): support osu-rx & osu-ap & all beatmap leaderboard like osu.ppy.sb 2025-08-10 07:03:49 +00:00
MingxuanGame
d9cf522f40 feat(score): support custom pp calculator 2025-08-10 05:05:08 +00:00
MingxuanGame
9f7ab81213 feat(signalr): support json & msgpack protocol for all hubs 2025-08-03 09:45:04 +00:00
MingxuanGame
1635641654 feat(score): support leaderboard for country/friends/team/selected mods 2025-07-31 14:11:42 +00:00
MingxuanGame
70399a2e50 feat(score): update statistics & return user in score 2025-07-29 07:36:33 +00:00
MingxuanGame
3ee95b0e7c feat(spectator): support save replays 2025-07-27 09:03:23 +00:00
MingxuanGame
ec241ac200 fix(solo-score): fix submit solo-score & Bigint 2025-07-27 04:11:41 +00:00
MingxuanGame
0b8beade5d refactor(mods): move models from app.models.score to app.models.mods 2025-07-27 03:01:17 +00:00
MingxuanGame
b359be3637 feat(solo-score): support submit solo scores 2025-07-27 02:33:42 +00:00
MingxuanGame
900a17f815 feat(beatmap): implement get beatmap arrtibutes 2025-07-26 17:31:23 +00:00
MingxuanGame
585cb9d98a fix(database): fix score database 2025-07-26 12:05:54 +08:00
jimmy-sketch
3b697785fc fix(api): 使/beatmaps/{beatmap}/score能够正常工作 2025-07-26 08:47:05 +08:00
MingxuanGame
2260d9265e fix(score): move db only fields to DB model 2025-07-25 21:38:51 +08:00
MingxuanGame
92f8a3a416 fix(score): rewrite DB model & API model 2025-07-25 21:28:43 +08:00
陈晋瑭
674b79cc91 Merge branch 'main' into score-database-model 2025-07-25 20:04:13 +08:00
jimmy-sketch
9a19027cc1 feat(models): 为scores类添加mp相关的两个字段 2025-07-25 20:02:21 +08:00
MingxuanGame
376d98ad5a feat(beatmap,beatmapset): get beatmap & beatmapset information by id 2025-07-25 17:01:01 +08:00
jimmy-sketch
94d53b2a20 feat(models): 添加 Score 类型定义
- 在 score.py 中定义了 Score 类,用于表示游戏分数信息
2025-07-25 14:18:02 +08:00
MingxuanGame
1655bb9f53 feat: 基础 SignalR 服务器支持 2025-07-24 18:45:08 +08:00