Skip to content

Add INSCRIBED Difficulty Support - #66

Draft
283375 wants to merge 5 commits into
masterfrom
feat/inscribed-diff
Draft

Add INSCRIBED Difficulty Support#66
283375 wants to merge 5 commits into
masterfrom
feat/inscribed-diff

Conversation

@283375

@283375 283375 commented Sep 4, 2026

Copy link
Copy Markdown
Collaborator

Closes #61

Changes

Database (schema 14 → 15)

  • Add nullable rating_class_alias column to difficulties
  • Replace the charts DatabaseView with explicit join queries returning Chart as a plain POJO
  • ChartFactory.fakeChart carries the alias

Songlist parsing

  • Read ratingClassAlias from difficulty entries and store it on Difficulty

UI

  • toRatingClassSelectorItems() now takes List<Difficulty>
  • ratingText renders INSCRIBED via ArcaeaRatingClassDisplay; the chart card difficulty label color follows the display form

Tests

  • Songlist importer test for alias parsing
  • ratingText INSCRIBED and unknown-alias fallback cases
  • Migration test for 14 → 15

…view

- Difficulty gains a nullable rating_class_alias column (schema 14 -> 15);
  the raw upstream value is interpreted only by ArcaeaRatingClassDisplay.
- The `charts` DatabaseView is replaced by explicit join queries returning
  Chart as a plain POJO. Views force their definition to be recreated in
  every migration that touches the joined tables; DAO-level joins avoid
  that and let consumers of the query stay unchanged. The view is dropped
  in the migration so a future `CREATE VIEW charts` cannot collide with a
  stale definition.
- Duplicate columns shared by play_results and the chart join (song_id,
  rating_class, date) resolve to the play_results value, as before.

Refs #61
Pass the raw upstream value through to Difficulty; interpretation stays
in ArcaeaRatingClassDisplay. Adds the first songlist importer test with
a trimmed fixture covering alias parsing and unknown-key tolerance.
- toRatingClassSelectorItems now takes List<Difficulty> and feeds the
  alias into ArcaeaRatingClassDisplay.of; ArcaeaChartSelector derives
  charts from the same difficulties query it already ran, and the
  calculator screen reads difficulties for the selector items.
- ratingText gains an ArcaeaRatingClassDisplay-based overload so an
  INSCRIBED chart renders "INSCRIBED" instead of "BEYOND"; the chart
  card colors follow the display form as well.

Refs #61
Room generates the same statements (drop the removed charts view, add
the nullable rating_class_alias column), so the hand-written migration
was redundant. The migration test now relies on the registered
AutoMigration via the database class and keeps its assertions.
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.

INSCRIBED (ratingClassAlias) data layer and app-wide display follow-ups

1 participant