mirror of
https://github.com/zkldi/Tachi.git
synced 2026-09-22 23:18:05 +03:00
fix: dynamic baseline for ongeki score graphs (#1705)
* fix: dynamic baseline for ongeki score graphs * format iidx seeds per request
This commit is contained in:
+1078
-1079
File diff suppressed because it is too large
Load Diff
+1080
-1080
File diff suppressed because it is too large
Load Diff
+192
-192
@@ -15,6 +15,98 @@
|
||||
],
|
||||
"title": "Lagrangian Point Ø"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Rainy。",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "COLOR DANCE POP"
|
||||
},
|
||||
"id": "S191de0bc75be28bf112",
|
||||
"legacySongID": 2605,
|
||||
"searchTerms": [],
|
||||
"title": "COLOR BURST"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "BlackY feat. Risa Yuzuki",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "LIGHTNING Hi-TECH"
|
||||
},
|
||||
"id": "S1920f6348d8557a1085",
|
||||
"legacySongID": 2595,
|
||||
"searchTerms": [],
|
||||
"title": "THUNDERSTRIKE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "DÉ DÉ MOUSE",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "Nu-NRG / FUTUREDISCO"
|
||||
},
|
||||
"id": "S19251aaf95d83b22774",
|
||||
"legacySongID": 2593,
|
||||
"searchTerms": [],
|
||||
"title": "Get Into The Groove feat.WaMi"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Juggernaut",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "GLHF"
|
||||
},
|
||||
"id": "S193608b356794611ada",
|
||||
"legacySongID": 2599,
|
||||
"searchTerms": [
|
||||
"GO"
|
||||
],
|
||||
"title": "GO!"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "暁Records",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "JAPANESE ALTERNATIVE ROCK"
|
||||
},
|
||||
"id": "S19418561db2805a0592",
|
||||
"legacySongID": 2596,
|
||||
"searchTerms": [],
|
||||
"title": "Wizards!"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Tatsunoshin",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "STAR☆CORE"
|
||||
},
|
||||
"id": "S195b41082f57a270a83",
|
||||
"legacySongID": 2602,
|
||||
"searchTerms": [
|
||||
"Meteor Shower"
|
||||
],
|
||||
"title": "Meteor☆Shower"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "BlackY",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "GOLDEN FORCE"
|
||||
},
|
||||
"id": "S1966940525062bf23cb",
|
||||
"legacySongID": 2603,
|
||||
"searchTerms": [
|
||||
"Rizing Gamers",
|
||||
"Rizing-Gamers",
|
||||
"Rising Gamers"
|
||||
],
|
||||
"title": "RIZING-GAMERS."
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Ryu☆ feat.青龍",
|
||||
@@ -53,6 +145,54 @@
|
||||
"searchTerms": [],
|
||||
"title": "Juicy"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Numb'n'dub",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "ブレイクコア"
|
||||
},
|
||||
"id": "S198323427fea95b582f",
|
||||
"legacySongID": 2601,
|
||||
"searchTerms": [],
|
||||
"title": "King of Tribe"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "SOUND HOLIC feat. Nana Takahashi",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "FUTURE VIBES"
|
||||
},
|
||||
"id": "S19858e92318551cd3f9",
|
||||
"legacySongID": 2600,
|
||||
"searchTerms": [],
|
||||
"title": "HORIZON BEATZ"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "nora2r feat. Liqo & DD\"ナカタ\"Metal",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "HYBRID METALCORE"
|
||||
},
|
||||
"id": "S1990f414129cbbe810d",
|
||||
"legacySongID": 2594,
|
||||
"searchTerms": [],
|
||||
"title": "Mighty Beat Monsterz"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "DJ Shimamura",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "HARDCORE RAVE"
|
||||
},
|
||||
"id": "S19942cd2d4bb159f3cd",
|
||||
"legacySongID": 2604,
|
||||
"searchTerms": [],
|
||||
"title": "SILKY BRAVE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Another Infinity feat. Mayumi Morinaga",
|
||||
@@ -65,6 +205,46 @@
|
||||
"searchTerms": [],
|
||||
"title": "It's my Miracle"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "森羅万象",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "DANCE POP"
|
||||
},
|
||||
"id": "S19a9fc151bbcaf0cd7c",
|
||||
"legacySongID": 2597,
|
||||
"searchTerms": [
|
||||
"Meteora",
|
||||
"Meteora -meteor-",
|
||||
"meteor"
|
||||
],
|
||||
"title": "メテオラ-meteor-"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "SOUND HOLIC feat. STEVIE(44MAGNUM)",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "CYBER ROCK"
|
||||
},
|
||||
"id": "S19bd502dae9343e2f7f",
|
||||
"legacySongID": 2592,
|
||||
"searchTerms": [],
|
||||
"title": "ESPRIT ONE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "MK",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "DRUMSTEP"
|
||||
},
|
||||
"id": "S19beaf6181b5eb809e6",
|
||||
"legacySongID": 2598,
|
||||
"searchTerms": [],
|
||||
"title": "Astra Blaze"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "kors k",
|
||||
@@ -31520,6 +31700,18 @@
|
||||
],
|
||||
"title": "繚乱ヒットチャート"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "OSTER project feat. 花たん",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "TRIUMPHAL ANTHEM"
|
||||
},
|
||||
"id": "S19dd4acb6dc336ea454",
|
||||
"legacySongID": 2591,
|
||||
"searchTerms": [],
|
||||
"title": "blue anthem"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "SOUND HOLIC feat. Nana Takahashi",
|
||||
@@ -31597,197 +31789,5 @@
|
||||
"Rush"
|
||||
],
|
||||
"title": "Rush!!"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "OSTER project feat. 花たん",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "TRIUMPHAL ANTHEM"
|
||||
},
|
||||
"id": "S19dd4acb6dc336ea454",
|
||||
"legacySongID": 2591,
|
||||
"searchTerms": [],
|
||||
"title": "blue anthem"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "SOUND HOLIC feat. STEVIE(44MAGNUM)",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "CYBER ROCK"
|
||||
},
|
||||
"id": "S19bd502dae9343e2f7f",
|
||||
"legacySongID": 2592,
|
||||
"searchTerms": [],
|
||||
"title": "ESPRIT ONE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "DÉ DÉ MOUSE",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "Nu-NRG / FUTUREDISCO"
|
||||
},
|
||||
"id": "S19251aaf95d83b22774",
|
||||
"legacySongID": 2593,
|
||||
"searchTerms": [],
|
||||
"title": "Get Into The Groove feat.WaMi"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "nora2r feat. Liqo & DD\"ナカタ\"Metal",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "HYBRID METALCORE"
|
||||
},
|
||||
"id": "S1990f414129cbbe810d",
|
||||
"legacySongID": 2594,
|
||||
"searchTerms": [],
|
||||
"title": "Mighty Beat Monsterz"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "BlackY feat. Risa Yuzuki",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "LIGHTNING Hi-TECH"
|
||||
},
|
||||
"id": "S1920f6348d8557a1085",
|
||||
"legacySongID": 2595,
|
||||
"searchTerms": [],
|
||||
"title": "THUNDERSTRIKE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "暁Records",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "JAPANESE ALTERNATIVE ROCK"
|
||||
},
|
||||
"id": "S19418561db2805a0592",
|
||||
"legacySongID": 2596,
|
||||
"searchTerms": [],
|
||||
"title": "Wizards!"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "森羅万象",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "DANCE POP"
|
||||
},
|
||||
"id": "S19a9fc151bbcaf0cd7c",
|
||||
"legacySongID": 2597,
|
||||
"searchTerms": [
|
||||
"Meteora",
|
||||
"Meteora -meteor-",
|
||||
"meteor"
|
||||
],
|
||||
"title": "メテオラ-meteor-"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "MK",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "DRUMSTEP"
|
||||
},
|
||||
"id": "S19beaf6181b5eb809e6",
|
||||
"legacySongID": 2598,
|
||||
"searchTerms": [],
|
||||
"title": "Astra Blaze"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Juggernaut",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "GLHF"
|
||||
},
|
||||
"id": "S193608b356794611ada",
|
||||
"legacySongID": 2599,
|
||||
"searchTerms": [
|
||||
"GO"
|
||||
],
|
||||
"title": "GO!"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "SOUND HOLIC feat. Nana Takahashi",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "FUTURE VIBES"
|
||||
},
|
||||
"id": "S19858e92318551cd3f9",
|
||||
"legacySongID": 2600,
|
||||
"searchTerms": [],
|
||||
"title": "HORIZON BEATZ"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Numb'n'dub",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "ブレイクコア"
|
||||
},
|
||||
"id": "S198323427fea95b582f",
|
||||
"legacySongID": 2601,
|
||||
"searchTerms": [],
|
||||
"title": "King of Tribe"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Tatsunoshin",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "STAR☆CORE"
|
||||
},
|
||||
"id": "S195b41082f57a270a83",
|
||||
"legacySongID": 2602,
|
||||
"searchTerms": [
|
||||
"Meteor Shower"
|
||||
],
|
||||
"title": "Meteor☆Shower"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "BlackY",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "GOLDEN FORCE"
|
||||
},
|
||||
"id": "S1966940525062bf23cb",
|
||||
"legacySongID": 2603,
|
||||
"searchTerms": [
|
||||
"Rizing Gamers",
|
||||
"Rizing-Gamers",
|
||||
"Rising Gamers"
|
||||
],
|
||||
"title": "RIZING-GAMERS."
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "DJ Shimamura",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "HARDCORE RAVE"
|
||||
},
|
||||
"id": "S19942cd2d4bb159f3cd",
|
||||
"legacySongID": 2604,
|
||||
"searchTerms": [],
|
||||
"title": "SILKY BRAVE"
|
||||
},
|
||||
{
|
||||
"altTitles": [],
|
||||
"artist": "Rainy。",
|
||||
"data": {
|
||||
"displayVersion": "33",
|
||||
"genre": "COLOR DANCE POP"
|
||||
},
|
||||
"id": "S191de0bc75be28bf112",
|
||||
"legacySongID": 2605,
|
||||
"searchTerms": [],
|
||||
"title": "COLOR BURST"
|
||||
}
|
||||
]
|
||||
@@ -71,6 +71,23 @@ const getScoreYAxisNotch = (game: GameGroup) => (s: number) => {
|
||||
return "";
|
||||
};
|
||||
|
||||
const getBaseline = (_game: "ongeki", data: Serie[]) => {
|
||||
const dataset = data[0].data;
|
||||
const dv = dataset[dataset.length - 1].y;
|
||||
const finalValue: number = typeof dv === "number" ? dv : 0;
|
||||
|
||||
if (finalValue >= 1007_500) {
|
||||
return 1007_500;
|
||||
}
|
||||
if (finalValue >= 1000_000) {
|
||||
return 1000_000;
|
||||
}
|
||||
if (finalValue >= 990_000) {
|
||||
return 990_000;
|
||||
}
|
||||
return 970_000;
|
||||
};
|
||||
|
||||
const strokeColor = (
|
||||
type: "BELLS" | Difficulties["chunithm"] | Difficulties["maimaidx"] | Difficulties["ongeki"],
|
||||
) => {
|
||||
@@ -238,16 +255,17 @@ export default function GekichumaiScoreChart({
|
||||
|
||||
if (type === "Score") {
|
||||
if (game === "ongeki") {
|
||||
const baseline = getBaseline("ongeki", data);
|
||||
component = (
|
||||
<ResponsiveLine
|
||||
{...commonProps}
|
||||
areaBaselineValue={970000}
|
||||
areaBaselineValue={baseline}
|
||||
axisLeft={{
|
||||
tickValues: [970_000, 990_000, 1000_000, 1007_500, 1010_000],
|
||||
format: getScoreYAxisNotch(game),
|
||||
}}
|
||||
colors={strokeColor(difficulty)}
|
||||
data={limitScoreGraph(data, 970_000)}
|
||||
data={limitScoreGraph(data, baseline)}
|
||||
enableGridY={true}
|
||||
gridYValues={[970_000, 980_000, 990_000, 1000_000, 1007_500, 1010_000]}
|
||||
tooltip={(d: PointTooltipProps) => (
|
||||
@@ -259,7 +277,7 @@ export default function GekichumaiScoreChart({
|
||||
</ChartTooltip>
|
||||
)}
|
||||
yFormat={">-,.0f"}
|
||||
yScale={{ type: "linear", min: 970_000, max: 1010_000 }}
|
||||
yScale={{ type: "linear", min: baseline, max: 1010_000 }}
|
||||
/>
|
||||
);
|
||||
} else if (game === "chunithm") {
|
||||
|
||||
Reference in New Issue
Block a user