mirror of
https://github.com/zkldi/Tachi.git
synced 2026-10-01 03:18:06 +03:00
feat: add myt ongeki support (#1076)
* feat: add myt ongeki support * fix: import myt score * style: undo misc. prettier changes * fix: nit on logging * fix: use song-chart desync as the term here and severe as loglevel --------- Co-authored-by: zkldi <20380519+zkldi@users.noreply.github.com>
This commit is contained in:
@@ -18,6 +18,7 @@ const choices: Array<[string, string]> = (
|
||||
["CG MUSECA", "api/cg-prod-museca"],
|
||||
["CG Pop'n", "api/cg-prod-popn"],
|
||||
["MYT WACCA", "api/myt-wacca"],
|
||||
["MYT ONGEKI", "api/myt-ongeki"],
|
||||
] as Array<[string, string]>
|
||||
)
|
||||
|
||||
|
||||
@@ -342,7 +342,7 @@ function ImportInfoDisplayer({ game }: { game: Game }) {
|
||||
key="SL-ITG"
|
||||
/>
|
||||
);
|
||||
} else if (game === 'ongeki') {
|
||||
} else if (game === "ongeki") {
|
||||
Content.unshift(
|
||||
<ImportInfoCard
|
||||
name="ARTEMiS Exporter"
|
||||
@@ -355,9 +355,10 @@ function ImportInfoDisplayer({ game }: { game: Game }) {
|
||||
</>
|
||||
}
|
||||
key="ARTEMiS Exporter"
|
||||
/>
|
||||
/>,
|
||||
<ImportTypeInfoCard key="api/myt-ongeki" importType="api/myt-ongeki" />
|
||||
);
|
||||
}// else if (game === "jubeat") {
|
||||
} // else if (game === "jubeat") {
|
||||
// Content.unshift(
|
||||
// <ImportTypeInfoCard key="api/cg-dev-jubeat" importType="api/cg-dev-jubeat" />,
|
||||
// <ImportTypeInfoCard key="api/cg-prod-jubeat" importType="api/cg-prod-jubeat" />
|
||||
@@ -536,6 +537,16 @@ function ImportTypeInfoCard({
|
||||
key="myt-wacca"
|
||||
/>
|
||||
);
|
||||
case "api/myt-ongeki":
|
||||
return (
|
||||
<ImportInfoCard
|
||||
name="MYT Integration"
|
||||
href="myt-ongeki"
|
||||
desc="Pull your Ongeki scores from the MYT Network."
|
||||
moreInfo="Note: All networks are reduced to their first three letters for anonymity reasons."
|
||||
key="myt-ongeki"
|
||||
/>
|
||||
);
|
||||
case "file/eamusement-iidx-csv":
|
||||
return (
|
||||
<ImportInfoCard
|
||||
|
||||
@@ -222,6 +222,9 @@ export default function ImportRoutes() {
|
||||
<Route exact path="/import/myt-wacca">
|
||||
<MytIntegrationPage game="wacca" />
|
||||
</Route>
|
||||
<Route exact path="/import/myt-ongeki">
|
||||
<MytIntegrationPage game="ongeki" />
|
||||
</Route>
|
||||
|
||||
<Route exact path="/import/wacca-mypage-scraper">
|
||||
<WACCAMyPageScraperPage />
|
||||
|
||||
@@ -17,7 +17,7 @@ import ImportStateRenderer from "./ImportStateRenderer";
|
||||
|
||||
interface Props {
|
||||
// Other games will be added in the future.
|
||||
game: "wacca";
|
||||
game: "wacca" | "ongeki";
|
||||
}
|
||||
|
||||
export default function MytIntegrationPage({ game }: Props) {
|
||||
|
||||
@@ -34,6 +34,7 @@ const API_IMPORT_TYPES: Record<APIImportTypes, true> = {
|
||||
"api/flo-iidx": true,
|
||||
"api/flo-sdvx": true,
|
||||
"api/min-sdvx": true,
|
||||
"api/myt-ongeki": true,
|
||||
"api/myt-wacca": true,
|
||||
"api/cg-dev-museca": true,
|
||||
"api/cg-dev-popn": true,
|
||||
|
||||
@@ -13,6 +13,7 @@ export type APIImportTypes =
|
||||
| "api/flo-iidx"
|
||||
| "api/flo-sdvx"
|
||||
| "api/min-sdvx"
|
||||
| "api/myt-ongeki"
|
||||
| "api/myt-wacca"
|
||||
|
||||
// cg has dev and prod supported
|
||||
|
||||
@@ -80,6 +80,7 @@
|
||||
"api/cg-gan-sdvx",
|
||||
"api/cg-gan-popn",
|
||||
"api/cg-gan-museca",
|
||||
"api/myt-ongeki",
|
||||
"api/myt-wacca",
|
||||
],
|
||||
},
|
||||
|
||||
@@ -0,0 +1,203 @@
|
||||
import ConvertAPIMytOngeki from "./converter";
|
||||
import CreateLogCtx from "lib/logger/logger";
|
||||
import { ParseDateFromString } from "lib/score-import/framework/common/score-utils";
|
||||
import {
|
||||
OngekiBattleScoreRank,
|
||||
OngekiClearStatus,
|
||||
OngekiComboStatus,
|
||||
OngekiLevel,
|
||||
OngekiTechScoreRank,
|
||||
} from "proto/generated/ongeki/common_pb";
|
||||
import t from "tap";
|
||||
import { dmf } from "test-utils/misc";
|
||||
import ResetDBState from "test-utils/resets";
|
||||
import { TestingOngekiChartConverter, TestingOngekiSongConverter } from "test-utils/test-data";
|
||||
import type { MytOngekiScore } from "./types";
|
||||
|
||||
const logger = CreateLogCtx(__filename);
|
||||
|
||||
const parsedScore: MytOngekiScore = {
|
||||
playlogApiId: "806ca7ac-76f5-4d99-8760-770df60e1ff5",
|
||||
info: {
|
||||
musicId: 678,
|
||||
level: OngekiLevel.ONGEKI_LEVEL_MASTER,
|
||||
techScore: 1003385,
|
||||
battleScore: 4987905,
|
||||
overDamage: 13151,
|
||||
techScoreRank: OngekiTechScoreRank.ONGEKI_TECH_SCORE_RANK_SS_PLUS,
|
||||
battleScoreRank: OngekiBattleScoreRank.ONGEKI_BATTLE_SCORE_RANK_GREAT,
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_NONE,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_OVER_DAMAGE,
|
||||
isFullBell: true,
|
||||
isTechNewRecord: true,
|
||||
isBattleNewRecord: true,
|
||||
isOverDamageNewRecord: true,
|
||||
platinumScore: 893,
|
||||
userPlayDate: "2022-09-28T12:04:21.400Z",
|
||||
},
|
||||
judge: {
|
||||
judgeCriticalBreak: 967,
|
||||
judgeBreak: 19,
|
||||
judgeHit: 0,
|
||||
judgeMiss: 5,
|
||||
maxCombo: 525,
|
||||
bellCount: 174,
|
||||
totalBellCount: 174,
|
||||
damageCount: 0,
|
||||
},
|
||||
};
|
||||
|
||||
t.test("#ConvertAPIMytOngeki", (t) => {
|
||||
t.beforeEach(ResetDBState);
|
||||
|
||||
function convert(modifier: any = {}) {
|
||||
return ConvertAPIMytOngeki(dmf(parsedScore, modifier), {}, "api/myt-ongeki", logger);
|
||||
}
|
||||
|
||||
t.test("Should return a dryScore on valid input.", async (t) => {
|
||||
const res = await convert();
|
||||
|
||||
t.strictSame(res, {
|
||||
song: TestingOngekiSongConverter,
|
||||
chart: TestingOngekiChartConverter,
|
||||
dryScore: {
|
||||
service: "MYT",
|
||||
game: "ongeki",
|
||||
scoreMeta: {},
|
||||
timeAchieved: ParseDateFromString("2022-09-28T12:04:21.400Z"),
|
||||
comment: null,
|
||||
importType: "api/myt-ongeki",
|
||||
scoreData: {
|
||||
score: 1003385,
|
||||
noteLamp: "CLEAR",
|
||||
bellLamp: "FULL BELL",
|
||||
judgements: {
|
||||
cbreak: 967,
|
||||
break: 19,
|
||||
hit: 0,
|
||||
miss: 5,
|
||||
},
|
||||
optional: {
|
||||
damage: 0,
|
||||
bellCount: 174,
|
||||
totalBellCount: 174,
|
||||
platScore: 893,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.test("Should reject unspecified difficulty", (t) => {
|
||||
t.rejects(
|
||||
() =>
|
||||
convert({
|
||||
info: {
|
||||
level: OngekiLevel.ONGEKI_LEVEL_UNSPECIFIED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
message: /Can't process a score with unspecified difficulty/u,
|
||||
}
|
||||
);
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.test("note lamp", async (t) => {
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_ALL_BREAK,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_FAILED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { noteLamp: "ALL BREAK" } },
|
||||
}
|
||||
);
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_FULL_COMBO,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_FAILED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { noteLamp: "FULL COMBO" } },
|
||||
}
|
||||
);
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_NONE,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_OVER_DAMAGE,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { noteLamp: "CLEAR" } },
|
||||
}
|
||||
);
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_NONE,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_CLEARED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { noteLamp: "CLEAR" } },
|
||||
}
|
||||
);
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
comboStatus: OngekiComboStatus.ONGEKI_COMBO_STATUS_NONE,
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_FAILED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { noteLamp: "LOSS" } },
|
||||
}
|
||||
);
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.test("platinum score should be null if value is 0", async (t) => {
|
||||
t.hasStrict(
|
||||
await convert({
|
||||
info: {
|
||||
platinumScore: 0,
|
||||
},
|
||||
}),
|
||||
{
|
||||
dryScore: { scoreData: { optional: { platScore: null } } },
|
||||
}
|
||||
);
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.test("Should reject unspecified clear status", (t) => {
|
||||
t.rejects(
|
||||
() =>
|
||||
convert({
|
||||
info: {
|
||||
clearStatus: OngekiClearStatus.ONGEKI_CLEAR_STATUS_UNSPECIFIED,
|
||||
},
|
||||
}),
|
||||
{
|
||||
message: /Can't process a score with an invalid combo status and\/or clear status/u,
|
||||
}
|
||||
);
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.test("Should throw on missing chart", (t) => {
|
||||
t.rejects(() => convert({ info: { musicId: 999999 } }), {
|
||||
message: /Can't find chart with id 999999 and difficulty MASTER/u,
|
||||
});
|
||||
t.end();
|
||||
});
|
||||
|
||||
t.end();
|
||||
});
|
||||
@@ -0,0 +1,134 @@
|
||||
import {
|
||||
InternalFailure,
|
||||
InvalidScoreFailure,
|
||||
SongOrChartNotFoundFailure,
|
||||
} from "lib/score-import/framework/common/converter-failures";
|
||||
import { ParseDateFromString } from "lib/score-import/framework/common/score-utils";
|
||||
import {
|
||||
OngekiClearStatus,
|
||||
OngekiComboStatus,
|
||||
OngekiLevel,
|
||||
} from "proto/generated/ongeki/common_pb";
|
||||
import { FindChartOnInGameID } from "utils/queries/charts";
|
||||
import { FindSongOnID } from "utils/queries/songs";
|
||||
import type { ConverterFunction } from "../../common/types";
|
||||
import type { MytOngekiScore } from "./types";
|
||||
import type { DryScore } from "lib/score-import/framework/common/types";
|
||||
import type { EmptyObject } from "utils/types";
|
||||
|
||||
const DIFFICULTIES = {
|
||||
[OngekiLevel.ONGEKI_LEVEL_UNSPECIFIED]: undefined,
|
||||
[OngekiLevel.ONGEKI_LEVEL_BASIC]: "BASIC",
|
||||
[OngekiLevel.ONGEKI_LEVEL_ADVANCED]: "ADVANCED",
|
||||
[OngekiLevel.ONGEKI_LEVEL_EXPERT]: "EXPERT",
|
||||
[OngekiLevel.ONGEKI_LEVEL_MASTER]: "MASTER",
|
||||
[OngekiLevel.ONGEKI_LEVEL_LUNATIC]: "LUNATIC",
|
||||
};
|
||||
|
||||
const getNoteLamp = (comboStatus: number, clearStatus: number) => {
|
||||
if (
|
||||
comboStatus === OngekiComboStatus.ONGEKI_COMBO_STATUS_UNSPECIFIED ||
|
||||
clearStatus === OngekiClearStatus.ONGEKI_CLEAR_STATUS_UNSPECIFIED
|
||||
) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
if (comboStatus === OngekiComboStatus.ONGEKI_COMBO_STATUS_ALL_BREAK) {
|
||||
return "ALL BREAK";
|
||||
}
|
||||
|
||||
if (comboStatus === OngekiComboStatus.ONGEKI_COMBO_STATUS_FULL_COMBO) {
|
||||
return "FULL COMBO";
|
||||
}
|
||||
|
||||
if (
|
||||
clearStatus === OngekiClearStatus.ONGEKI_CLEAR_STATUS_OVER_DAMAGE ||
|
||||
clearStatus === OngekiClearStatus.ONGEKI_CLEAR_STATUS_CLEARED
|
||||
) {
|
||||
return "CLEAR";
|
||||
}
|
||||
|
||||
if (clearStatus === OngekiClearStatus.ONGEKI_CLEAR_STATUS_FAILED) {
|
||||
return "LOSS";
|
||||
}
|
||||
|
||||
return undefined;
|
||||
};
|
||||
|
||||
const ConvertAPIMytOngeki: ConverterFunction<MytOngekiScore, EmptyObject> = async (
|
||||
data,
|
||||
_context,
|
||||
importType,
|
||||
logger
|
||||
) => {
|
||||
if (data.info === undefined || data.judge === undefined) {
|
||||
throw new InvalidScoreFailure("Failed to receive score data from MYT API");
|
||||
}
|
||||
|
||||
const difficulty = DIFFICULTIES[data.info.level];
|
||||
|
||||
if (difficulty === undefined) {
|
||||
throw new InvalidScoreFailure(
|
||||
`Can't process a score with unspecified difficulty (musicId ${data.info.musicId})`
|
||||
);
|
||||
}
|
||||
|
||||
const noteLamp = getNoteLamp(data.info.comboStatus, data.info.clearStatus);
|
||||
|
||||
if (noteLamp === undefined) {
|
||||
throw new InvalidScoreFailure(
|
||||
"Can't process a score with an invalid combo status and/or clear status"
|
||||
);
|
||||
}
|
||||
|
||||
const chart = await FindChartOnInGameID("ongeki", data.info.musicId, "Single", difficulty);
|
||||
|
||||
if (chart === null) {
|
||||
throw new SongOrChartNotFoundFailure(
|
||||
`Can't find chart with id ${data.info.musicId} and difficulty ${difficulty}`,
|
||||
importType,
|
||||
data,
|
||||
{}
|
||||
);
|
||||
}
|
||||
|
||||
const song = await FindSongOnID("ongeki", chart.songID);
|
||||
|
||||
if (song === null) {
|
||||
logger.severe(`Song/chart desync: ${chart.songID} for chart ${chart.chartID}`, { chart });
|
||||
throw new InternalFailure(`Song/chart desync: ${chart.songID} for chart ${chart.chartID}`);
|
||||
}
|
||||
|
||||
const dryScore: DryScore<"ongeki:Single"> = {
|
||||
service: "MYT",
|
||||
game: "ongeki",
|
||||
scoreMeta: {},
|
||||
timeAchieved: ParseDateFromString(data.info.userPlayDate),
|
||||
comment: null,
|
||||
importType,
|
||||
scoreData: {
|
||||
score: data.info.techScore,
|
||||
noteLamp,
|
||||
bellLamp: data.info.isFullBell ? "FULL BELL" : "NONE",
|
||||
judgements: {
|
||||
cbreak: data.judge.judgeCriticalBreak,
|
||||
break: data.judge.judgeBreak,
|
||||
hit: data.judge.judgeHit,
|
||||
miss: data.judge.judgeMiss,
|
||||
},
|
||||
optional: {
|
||||
damage: data.judge.damageCount,
|
||||
bellCount: data.judge.bellCount,
|
||||
totalBellCount: data.judge.totalBellCount,
|
||||
// Set platinum score to explicitly null if the value is 0
|
||||
// There is no distinction between 0 and null/undefined in gRPC
|
||||
// Handles playlogs from older versions when Platinum Score didn't exist
|
||||
platScore: data.info.platinumScore || null,
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
return { chart, song, dryScore };
|
||||
};
|
||||
|
||||
export default ConvertAPIMytOngeki;
|
||||
@@ -0,0 +1,56 @@
|
||||
import {
|
||||
FetchMytTitleAPIID,
|
||||
GetMytHostname,
|
||||
StreamRPCAsAsync,
|
||||
} from "../../common/api-myt/traverse-api";
|
||||
import { credentials } from "@grpc/grpc-js";
|
||||
import ScoreImportFatalError from "lib/score-import/framework/score-importing/score-import-error";
|
||||
import { OngekiUserClient } from "proto/generated/ongeki/user_grpc_pb";
|
||||
import { GetPlaylogRequest } from "proto/generated/ongeki/user_pb";
|
||||
import type { ParserFunctionReturns } from "../../common/types";
|
||||
import type { MytOngekiScore } from "./types";
|
||||
import type { KtLogger } from "lib/logger/logger";
|
||||
import type { GetPlaylogStreamItem } from "proto/generated/ongeki/user_pb";
|
||||
import type { integer } from "tachi-common";
|
||||
import type { EmptyObject } from "utils/types";
|
||||
|
||||
async function* getObjectsFromGrpcIterable(
|
||||
iterable: AsyncIterable<GetPlaylogStreamItem>
|
||||
): AsyncIterable<MytOngekiScore> {
|
||||
for await (const item of iterable) {
|
||||
yield item.toObject();
|
||||
}
|
||||
}
|
||||
|
||||
export default async function ParseMytOngeki(
|
||||
userID: integer,
|
||||
logger: KtLogger
|
||||
): Promise<ParserFunctionReturns<MytOngekiScore, EmptyObject>> {
|
||||
const profileApiId = await FetchMytTitleAPIID(userID, "ongeki", logger);
|
||||
const endpoint = GetMytHostname();
|
||||
const client = new OngekiUserClient(endpoint, credentials.createSsl());
|
||||
const request = new GetPlaylogRequest();
|
||||
|
||||
request.setProfileApiId(profileApiId);
|
||||
|
||||
let iterable;
|
||||
|
||||
try {
|
||||
const stream = StreamRPCAsAsync(client.getPlaylog.bind(client), request, logger);
|
||||
|
||||
iterable = getObjectsFromGrpcIterable(stream);
|
||||
} catch (err) {
|
||||
logger.error(
|
||||
`Unexpected MYT error while streaming Ongeki playlog items for userID ${userID}: ${err}`
|
||||
);
|
||||
|
||||
throw new ScoreImportFatalError(500, `Failed to get scores from MYT.`);
|
||||
}
|
||||
|
||||
return {
|
||||
iterable,
|
||||
context: {},
|
||||
classProvider: null,
|
||||
game: "ongeki",
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
import type { GetPlaylogStreamItem } from "proto/generated/ongeki/user_pb";
|
||||
|
||||
export type MytOngekiScore = GetPlaylogStreamItem.AsObject;
|
||||
@@ -81,12 +81,8 @@ const ConvertAPIMytWACCA: ConverterFunction<MytWaccaScore, EmptyObject> = async
|
||||
const song = await FindSongOnID("wacca", chart.songID);
|
||||
|
||||
if (song === null) {
|
||||
logger.error(
|
||||
`WACCA: Can't find corresponding song ${chart.songID} for chart ${chart.chartID}`
|
||||
);
|
||||
throw new InternalFailure(
|
||||
`Can't find corresponding song ${chart.songID} for chart ${chart.chartID}`
|
||||
);
|
||||
logger.severe(`Song/chart desync: ${chart.songID} for chart ${chart.chartID}`, { chart });
|
||||
throw new InternalFailure(`Song/chart desync: ${chart.songID} for chart ${chart.chartID}`);
|
||||
}
|
||||
|
||||
const lamp = convertClearStatus(data.clearStatus);
|
||||
|
||||
@@ -39,7 +39,10 @@ export default async function ParseMytWACCA(
|
||||
// Note: I don't think this actually does anything on the network, so
|
||||
// it shouldn't really fail. Still, wrap just in case.
|
||||
|
||||
logger.error(`Unexpected MYT during WaccaUserClient creation for ${userID}: ${err}`);
|
||||
logger.error(`Unexpected MYT during WaccaUserClient creation for ${userID}: ${err}`, {
|
||||
userID,
|
||||
err,
|
||||
});
|
||||
|
||||
throw new ScoreImportFatalError(500, `Failed to connect to MYT.`);
|
||||
}
|
||||
|
||||
@@ -3,12 +3,14 @@ import type { Game } from "tachi-common";
|
||||
|
||||
export function GameToMytGame(game: Game): MytGame | undefined {
|
||||
switch (game) {
|
||||
case "wacca":
|
||||
return "wacca";
|
||||
case "chunithm":
|
||||
return "chunithm";
|
||||
case "maimaidx":
|
||||
return "maimai";
|
||||
case "ongeki":
|
||||
return "ongeki";
|
||||
case "wacca":
|
||||
return "wacca";
|
||||
default:
|
||||
return undefined;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import type { ConverterFailure } from "../../framework/common/converter-failures";
|
||||
import type { DryScore } from "../../framework/common/types";
|
||||
import type { MytOngekiScore } from "../api/myt-ongeki/types";
|
||||
import type { MytWaccaScore } from "../api/myt-wacca/types";
|
||||
import type { SDVXEamusementCSVData } from "../file/eamusement-sdvx-csv/types";
|
||||
import type { S3Score } from "../file/solid-state-squad/types";
|
||||
@@ -56,6 +57,7 @@ export interface ImportTypeDataMap {
|
||||
"api/eag-iidx": unknown;
|
||||
"api/eag-sdvx": unknown;
|
||||
|
||||
"api/myt-ongeki": MytOngekiScore;
|
||||
"api/myt-wacca": MytWaccaScore;
|
||||
|
||||
"api/cg-dev-sdvx": CGSDVXScore;
|
||||
@@ -99,6 +101,7 @@ export interface ImportTypeContextMap {
|
||||
"api/min-sdvx": KaiContext;
|
||||
"api/eag-iidx": KaiContext;
|
||||
"api/eag-sdvx": KaiContext;
|
||||
"api/myt-ongeki": EmptyObject;
|
||||
"api/myt-wacca": EmptyObject;
|
||||
|
||||
"api/cg-dev-jubeat": CGContext;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import ConvertAPIMytOngeki from "./api/myt-ongeki/converter";
|
||||
import ConvertAPIMytWACCA from "./api/myt-wacca/converter";
|
||||
import { ConverterAPICGMuseca } from "./common/api-cg/museca/converter";
|
||||
import { ConverterAPICGPopn } from "./common/api-cg/popn/converter";
|
||||
@@ -43,6 +44,7 @@ export const Converters: ConverterMap = {
|
||||
"api/flo-iidx": ConvertAPIKaiIIDX,
|
||||
"api/flo-sdvx": ConvertAPIKaiSDVX,
|
||||
"api/min-sdvx": ConvertAPIKaiSDVX,
|
||||
"api/myt-ongeki": ConvertAPIMytOngeki,
|
||||
"api/myt-wacca": ConvertAPIMytWACCA,
|
||||
|
||||
"ir/barbatos": ConverterIRBarbatos,
|
||||
|
||||
@@ -3,6 +3,7 @@ import { ParseEagSDVX } from "./api/eag-sdvx/parser";
|
||||
import { ParseFloIIDX } from "./api/flo-iidx/parser";
|
||||
import { ParseFloSDVX } from "./api/flo-sdvx/parser";
|
||||
import { ParseMinSDVX } from "./api/min-sdvx/parser";
|
||||
import ParseMytOngeki from "./api/myt-ongeki/parser";
|
||||
import ParseMytWACCA from "./api/myt-wacca/parser";
|
||||
import {
|
||||
ParseCGDevMuseca,
|
||||
@@ -65,6 +66,7 @@ export const Parsers = {
|
||||
"api/cg-gan-popn": ParseCGGanPopn,
|
||||
"api/cg-gan-museca": ParseCGGanMuseca,
|
||||
|
||||
"api/myt-ongeki": ParseMytOngeki,
|
||||
"api/myt-wacca": ParseMytWACCA,
|
||||
|
||||
"ir/barbatos": ParseBarbatosSingle,
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
// GENERATED CODE -- NO SERVICES IN PROTO
|
||||
@@ -0,0 +1 @@
|
||||
// GENERATED CODE -- NO SERVICES IN PROTO
|
||||
@@ -0,0 +1,85 @@
|
||||
// package: mythos.ongeki.v0
|
||||
// file: ongeki/common.proto
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
|
||||
export interface OngekiLevelMap {
|
||||
ONGEKI_LEVEL_UNSPECIFIED: 0;
|
||||
ONGEKI_LEVEL_BASIC: 1;
|
||||
ONGEKI_LEVEL_ADVANCED: 2;
|
||||
ONGEKI_LEVEL_EXPERT: 3;
|
||||
ONGEKI_LEVEL_MASTER: 4;
|
||||
ONGEKI_LEVEL_LUNATIC: 5;
|
||||
}
|
||||
|
||||
export const OngekiLevel: OngekiLevelMap;
|
||||
|
||||
export interface OngekiRankingTypeMap {
|
||||
ONGEKI_RANKING_TYPE_UNSPECIFIED: 0;
|
||||
ONGEKI_RANKING_TYPE_TECH_SCORE: 1;
|
||||
ONGEKI_RANKING_TYPE_BATTLE_SCORE: 2;
|
||||
ONGEKI_RANKING_TYPE_OVER_DAMAGE: 3;
|
||||
ONGEKI_RANKING_TYPE_PLATINUM_SCORE: 4;
|
||||
}
|
||||
|
||||
export const OngekiRankingType: OngekiRankingTypeMap;
|
||||
|
||||
export interface OngekiTechScoreRankMap {
|
||||
ONGEKI_TECH_SCORE_RANK_UNSPECIFIED: 0;
|
||||
ONGEKI_TECH_SCORE_RANK_D: 1;
|
||||
ONGEKI_TECH_SCORE_RANK_C: 2;
|
||||
ONGEKI_TECH_SCORE_RANK_B: 3;
|
||||
ONGEKI_TECH_SCORE_RANK_BB: 4;
|
||||
ONGEKI_TECH_SCORE_RANK_BBB: 5;
|
||||
ONGEKI_TECH_SCORE_RANK_A: 6;
|
||||
ONGEKI_TECH_SCORE_RANK_AA: 7;
|
||||
ONGEKI_TECH_SCORE_RANK_AAA: 8;
|
||||
ONGEKI_TECH_SCORE_RANK_S: 9;
|
||||
ONGEKI_TECH_SCORE_RANK_S_PLUS: 10;
|
||||
ONGEKI_TECH_SCORE_RANK_SS: 11;
|
||||
ONGEKI_TECH_SCORE_RANK_SS_PLUS: 12;
|
||||
ONGEKI_TECH_SCORE_RANK_SSS: 13;
|
||||
ONGEKI_TECH_SCORE_RANK_SSS_PLUS: 14;
|
||||
}
|
||||
|
||||
export const OngekiTechScoreRank: OngekiTechScoreRankMap;
|
||||
|
||||
export interface OngekiBattleScoreRankMap {
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNSPECIFIED: 0;
|
||||
ONGEKI_BATTLE_SCORE_RANK_NO_GOOD: 1;
|
||||
ONGEKI_BATTLE_SCORE_RANK_USUALLY: 2;
|
||||
ONGEKI_BATTLE_SCORE_RANK_GOOD: 3;
|
||||
ONGEKI_BATTLE_SCORE_RANK_GREAT: 4;
|
||||
ONGEKI_BATTLE_SCORE_RANK_EXCELLENT: 5;
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNBELIEVABLE: 6;
|
||||
}
|
||||
|
||||
export const OngekiBattleScoreRank: OngekiBattleScoreRankMap;
|
||||
|
||||
export interface OngekiClearStatusMap {
|
||||
ONGEKI_CLEAR_STATUS_UNSPECIFIED: 0;
|
||||
ONGEKI_CLEAR_STATUS_FAILED: 1;
|
||||
ONGEKI_CLEAR_STATUS_CLEARED: 2;
|
||||
ONGEKI_CLEAR_STATUS_OVER_DAMAGE: 3;
|
||||
}
|
||||
|
||||
export const OngekiClearStatus: OngekiClearStatusMap;
|
||||
|
||||
export interface OngekiComboStatusMap {
|
||||
ONGEKI_COMBO_STATUS_UNSPECIFIED: 0;
|
||||
ONGEKI_COMBO_STATUS_NONE: 1;
|
||||
ONGEKI_COMBO_STATUS_FULL_COMBO: 2;
|
||||
ONGEKI_COMBO_STATUS_ALL_BREAK: 3;
|
||||
}
|
||||
|
||||
export const OngekiComboStatus: OngekiComboStatusMap;
|
||||
|
||||
export interface OngekiBossAttributeMap {
|
||||
ONGEKI_BOSS_ATTRIBUTE_UNSPECIFIED: 0;
|
||||
ONGEKI_BOSS_ATTRIBUTE_FIRE: 1;
|
||||
ONGEKI_BOSS_ATTRIBUTE_AQUA: 2;
|
||||
ONGEKI_BOSS_ATTRIBUTE_LEAF: 3;
|
||||
}
|
||||
|
||||
export const OngekiBossAttribute: OngekiBossAttributeMap;
|
||||
|
||||
@@ -0,0 +1,118 @@
|
||||
// source: ongeki/common.proto
|
||||
/**
|
||||
* @fileoverview
|
||||
* @enhanceable
|
||||
* @suppress {missingRequire} reports error on implicit type usages.
|
||||
* @suppress {messageConventions} JS Compiler reports an error if a variable or
|
||||
* field starts with 'MSG_' and isn't a translatable message.
|
||||
* @public
|
||||
*/
|
||||
// GENERATED CODE -- DO NOT EDIT!
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
var jspb = require('google-protobuf');
|
||||
var goog = jspb;
|
||||
var global = (function() {
|
||||
if (this) { return this; }
|
||||
if (typeof window !== 'undefined') { return window; }
|
||||
if (typeof global !== 'undefined') { return global; }
|
||||
if (typeof self !== 'undefined') { return self; }
|
||||
return Function('return this')();
|
||||
}.call(null));
|
||||
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiBattleScoreRank', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiBossAttribute', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiClearStatus', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiComboStatus', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiLevel', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiRankingType', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.OngekiTechScoreRank', null, global);
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiLevel = {
|
||||
ONGEKI_LEVEL_UNSPECIFIED: 0,
|
||||
ONGEKI_LEVEL_BASIC: 1,
|
||||
ONGEKI_LEVEL_ADVANCED: 2,
|
||||
ONGEKI_LEVEL_EXPERT: 3,
|
||||
ONGEKI_LEVEL_MASTER: 4,
|
||||
ONGEKI_LEVEL_LUNATIC: 5
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiRankingType = {
|
||||
ONGEKI_RANKING_TYPE_UNSPECIFIED: 0,
|
||||
ONGEKI_RANKING_TYPE_TECH_SCORE: 1,
|
||||
ONGEKI_RANKING_TYPE_BATTLE_SCORE: 2,
|
||||
ONGEKI_RANKING_TYPE_OVER_DAMAGE: 3,
|
||||
ONGEKI_RANKING_TYPE_PLATINUM_SCORE: 4
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiTechScoreRank = {
|
||||
ONGEKI_TECH_SCORE_RANK_UNSPECIFIED: 0,
|
||||
ONGEKI_TECH_SCORE_RANK_D: 1,
|
||||
ONGEKI_TECH_SCORE_RANK_C: 2,
|
||||
ONGEKI_TECH_SCORE_RANK_B: 3,
|
||||
ONGEKI_TECH_SCORE_RANK_BB: 4,
|
||||
ONGEKI_TECH_SCORE_RANK_BBB: 5,
|
||||
ONGEKI_TECH_SCORE_RANK_A: 6,
|
||||
ONGEKI_TECH_SCORE_RANK_AA: 7,
|
||||
ONGEKI_TECH_SCORE_RANK_AAA: 8,
|
||||
ONGEKI_TECH_SCORE_RANK_S: 9,
|
||||
ONGEKI_TECH_SCORE_RANK_S_PLUS: 10,
|
||||
ONGEKI_TECH_SCORE_RANK_SS: 11,
|
||||
ONGEKI_TECH_SCORE_RANK_SS_PLUS: 12,
|
||||
ONGEKI_TECH_SCORE_RANK_SSS: 13,
|
||||
ONGEKI_TECH_SCORE_RANK_SSS_PLUS: 14
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiBattleScoreRank = {
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNSPECIFIED: 0,
|
||||
ONGEKI_BATTLE_SCORE_RANK_NO_GOOD: 1,
|
||||
ONGEKI_BATTLE_SCORE_RANK_USUALLY: 2,
|
||||
ONGEKI_BATTLE_SCORE_RANK_GOOD: 3,
|
||||
ONGEKI_BATTLE_SCORE_RANK_GREAT: 4,
|
||||
ONGEKI_BATTLE_SCORE_RANK_EXCELLENT: 5,
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNBELIEVABLE: 6
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiClearStatus = {
|
||||
ONGEKI_CLEAR_STATUS_UNSPECIFIED: 0,
|
||||
ONGEKI_CLEAR_STATUS_FAILED: 1,
|
||||
ONGEKI_CLEAR_STATUS_CLEARED: 2,
|
||||
ONGEKI_CLEAR_STATUS_OVER_DAMAGE: 3
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiComboStatus = {
|
||||
ONGEKI_COMBO_STATUS_UNSPECIFIED: 0,
|
||||
ONGEKI_COMBO_STATUS_NONE: 1,
|
||||
ONGEKI_COMBO_STATUS_FULL_COMBO: 2,
|
||||
ONGEKI_COMBO_STATUS_ALL_BREAK: 3
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.OngekiBossAttribute = {
|
||||
ONGEKI_BOSS_ATTRIBUTE_UNSPECIFIED: 0,
|
||||
ONGEKI_BOSS_ATTRIBUTE_FIRE: 1,
|
||||
ONGEKI_BOSS_ATTRIBUTE_AQUA: 2,
|
||||
ONGEKI_BOSS_ATTRIBUTE_LEAF: 3
|
||||
};
|
||||
|
||||
goog.object.extend(exports, proto.mythos.ongeki.v0);
|
||||
@@ -0,0 +1 @@
|
||||
// GENERATED CODE -- NO SERVICES IN PROTO
|
||||
@@ -0,0 +1 @@
|
||||
// GENERATED CODE -- NO SERVICES IN PROTO
|
||||
+274
@@ -0,0 +1,274 @@
|
||||
// package: mythos.ongeki.v0
|
||||
// file: ongeki/playlog.proto
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
import * as ongeki_common_pb from "../ongeki/common_pb";
|
||||
|
||||
export class PlaylogInfo extends jspb.Message {
|
||||
getMusicId(): number;
|
||||
setMusicId(value: number): void;
|
||||
|
||||
getLevel(): ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap];
|
||||
setLevel(value: ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap]): void;
|
||||
|
||||
getTechScore(): number;
|
||||
setTechScore(value: number): void;
|
||||
|
||||
getBattleScore(): number;
|
||||
setBattleScore(value: number): void;
|
||||
|
||||
getOverDamage(): number;
|
||||
setOverDamage(value: number): void;
|
||||
|
||||
getPlatinumScore(): number;
|
||||
setPlatinumScore(value: number): void;
|
||||
|
||||
getTechScoreRank(): ongeki_common_pb.OngekiTechScoreRankMap[keyof ongeki_common_pb.OngekiTechScoreRankMap];
|
||||
setTechScoreRank(value: ongeki_common_pb.OngekiTechScoreRankMap[keyof ongeki_common_pb.OngekiTechScoreRankMap]): void;
|
||||
|
||||
getBattleScoreRank(): ongeki_common_pb.OngekiBattleScoreRankMap[keyof ongeki_common_pb.OngekiBattleScoreRankMap];
|
||||
setBattleScoreRank(value: ongeki_common_pb.OngekiBattleScoreRankMap[keyof ongeki_common_pb.OngekiBattleScoreRankMap]): void;
|
||||
|
||||
getComboStatus(): ongeki_common_pb.OngekiComboStatusMap[keyof ongeki_common_pb.OngekiComboStatusMap];
|
||||
setComboStatus(value: ongeki_common_pb.OngekiComboStatusMap[keyof ongeki_common_pb.OngekiComboStatusMap]): void;
|
||||
|
||||
getClearStatus(): ongeki_common_pb.OngekiClearStatusMap[keyof ongeki_common_pb.OngekiClearStatusMap];
|
||||
setClearStatus(value: ongeki_common_pb.OngekiClearStatusMap[keyof ongeki_common_pb.OngekiClearStatusMap]): void;
|
||||
|
||||
getIsFullBell(): boolean;
|
||||
setIsFullBell(value: boolean): void;
|
||||
|
||||
getIsTechNewRecord(): boolean;
|
||||
setIsTechNewRecord(value: boolean): void;
|
||||
|
||||
getIsBattleNewRecord(): boolean;
|
||||
setIsBattleNewRecord(value: boolean): void;
|
||||
|
||||
getIsOverDamageNewRecord(): boolean;
|
||||
setIsOverDamageNewRecord(value: boolean): void;
|
||||
|
||||
getUserPlayDate(): string;
|
||||
setUserPlayDate(value: string): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogInfo.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogInfo): PlaylogInfo.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogInfo, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogInfo;
|
||||
static deserializeBinaryFromReader(message: PlaylogInfo, reader: jspb.BinaryReader): PlaylogInfo;
|
||||
}
|
||||
|
||||
export namespace PlaylogInfo {
|
||||
export type AsObject = {
|
||||
musicId: number,
|
||||
level: ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap],
|
||||
techScore: number,
|
||||
battleScore: number,
|
||||
overDamage: number,
|
||||
platinumScore: number,
|
||||
techScoreRank: ongeki_common_pb.OngekiTechScoreRankMap[keyof ongeki_common_pb.OngekiTechScoreRankMap],
|
||||
battleScoreRank: ongeki_common_pb.OngekiBattleScoreRankMap[keyof ongeki_common_pb.OngekiBattleScoreRankMap],
|
||||
comboStatus: ongeki_common_pb.OngekiComboStatusMap[keyof ongeki_common_pb.OngekiComboStatusMap],
|
||||
clearStatus: ongeki_common_pb.OngekiClearStatusMap[keyof ongeki_common_pb.OngekiClearStatusMap],
|
||||
isFullBell: boolean,
|
||||
isTechNewRecord: boolean,
|
||||
isBattleNewRecord: boolean,
|
||||
isOverDamageNewRecord: boolean,
|
||||
userPlayDate: string,
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogJudge extends jspb.Message {
|
||||
getJudgeCriticalBreak(): number;
|
||||
setJudgeCriticalBreak(value: number): void;
|
||||
|
||||
getJudgeBreak(): number;
|
||||
setJudgeBreak(value: number): void;
|
||||
|
||||
getJudgeHit(): number;
|
||||
setJudgeHit(value: number): void;
|
||||
|
||||
getJudgeMiss(): number;
|
||||
setJudgeMiss(value: number): void;
|
||||
|
||||
getMaxCombo(): number;
|
||||
setMaxCombo(value: number): void;
|
||||
|
||||
getBellCount(): number;
|
||||
setBellCount(value: number): void;
|
||||
|
||||
getTotalBellCount(): number;
|
||||
setTotalBellCount(value: number): void;
|
||||
|
||||
getDamageCount(): number;
|
||||
setDamageCount(value: number): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogJudge.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogJudge): PlaylogJudge.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogJudge, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogJudge;
|
||||
static deserializeBinaryFromReader(message: PlaylogJudge, reader: jspb.BinaryReader): PlaylogJudge;
|
||||
}
|
||||
|
||||
export namespace PlaylogJudge {
|
||||
export type AsObject = {
|
||||
judgeCriticalBreak: number,
|
||||
judgeBreak: number,
|
||||
judgeHit: number,
|
||||
judgeMiss: number,
|
||||
maxCombo: number,
|
||||
bellCount: number,
|
||||
totalBellCount: number,
|
||||
damageCount: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogJudgeRate extends jspb.Message {
|
||||
getRateTap(): number;
|
||||
setRateTap(value: number): void;
|
||||
|
||||
getRateHold(): number;
|
||||
setRateHold(value: number): void;
|
||||
|
||||
getRateFlick(): number;
|
||||
setRateFlick(value: number): void;
|
||||
|
||||
getRateSideTap(): number;
|
||||
setRateSideTap(value: number): void;
|
||||
|
||||
getRateSideHold(): number;
|
||||
setRateSideHold(value: number): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogJudgeRate.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogJudgeRate): PlaylogJudgeRate.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogJudgeRate, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogJudgeRate;
|
||||
static deserializeBinaryFromReader(message: PlaylogJudgeRate, reader: jspb.BinaryReader): PlaylogJudgeRate;
|
||||
}
|
||||
|
||||
export namespace PlaylogJudgeRate {
|
||||
export type AsObject = {
|
||||
rateTap: number,
|
||||
rateHold: number,
|
||||
rateFlick: number,
|
||||
rateSideTap: number,
|
||||
rateSideHold: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogMatchingUser extends jspb.Message {
|
||||
getUserName(): string;
|
||||
setUserName(value: string): void;
|
||||
|
||||
getMusicLevel(): ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap];
|
||||
setMusicLevel(value: ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap]): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogMatchingUser.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogMatchingUser): PlaylogMatchingUser.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogMatchingUser, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogMatchingUser;
|
||||
static deserializeBinaryFromReader(message: PlaylogMatchingUser, reader: jspb.BinaryReader): PlaylogMatchingUser;
|
||||
}
|
||||
|
||||
export namespace PlaylogMatchingUser {
|
||||
export type AsObject = {
|
||||
userName: string,
|
||||
musicLevel: ongeki_common_pb.OngekiLevelMap[keyof ongeki_common_pb.OngekiLevelMap],
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogCard extends jspb.Message {
|
||||
getCardId(): number;
|
||||
setCardId(value: number): void;
|
||||
|
||||
getCardLevel(): number;
|
||||
setCardLevel(value: number): void;
|
||||
|
||||
getCardAttack(): number;
|
||||
setCardAttack(value: number): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogCard.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogCard): PlaylogCard.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogCard, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogCard;
|
||||
static deserializeBinaryFromReader(message: PlaylogCard, reader: jspb.BinaryReader): PlaylogCard;
|
||||
}
|
||||
|
||||
export namespace PlaylogCard {
|
||||
export type AsObject = {
|
||||
cardId: number,
|
||||
cardLevel: number,
|
||||
cardAttack: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogBoss extends jspb.Message {
|
||||
getBossId(): number;
|
||||
setBossId(value: number): void;
|
||||
|
||||
getBossLevel(): number;
|
||||
setBossLevel(value: number): void;
|
||||
|
||||
getBossAttribute(): ongeki_common_pb.OngekiBossAttributeMap[keyof ongeki_common_pb.OngekiBossAttributeMap];
|
||||
setBossAttribute(value: ongeki_common_pb.OngekiBossAttributeMap[keyof ongeki_common_pb.OngekiBossAttributeMap]): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogBoss.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogBoss): PlaylogBoss.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogBoss, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogBoss;
|
||||
static deserializeBinaryFromReader(message: PlaylogBoss, reader: jspb.BinaryReader): PlaylogBoss;
|
||||
}
|
||||
|
||||
export namespace PlaylogBoss {
|
||||
export type AsObject = {
|
||||
bossId: number,
|
||||
bossLevel: number,
|
||||
bossAttribute: ongeki_common_pb.OngekiBossAttributeMap[keyof ongeki_common_pb.OngekiBossAttributeMap],
|
||||
}
|
||||
}
|
||||
|
||||
export class PlaylogEvent extends jspb.Message {
|
||||
getEventId(): number;
|
||||
setEventId(value: number): void;
|
||||
|
||||
getEventName(): string;
|
||||
setEventName(value: string): void;
|
||||
|
||||
getEventPoint(): number;
|
||||
setEventPoint(value: number): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): PlaylogEvent.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: PlaylogEvent): PlaylogEvent.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: PlaylogEvent, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): PlaylogEvent;
|
||||
static deserializeBinaryFromReader(message: PlaylogEvent, reader: jspb.BinaryReader): PlaylogEvent;
|
||||
}
|
||||
|
||||
export namespace PlaylogEvent {
|
||||
export type AsObject = {
|
||||
eventId: number,
|
||||
eventName: string,
|
||||
eventPoint: number,
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,23 @@
|
||||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
// package: mythos.ongeki.v0
|
||||
// file: ongeki/user.proto
|
||||
|
||||
import * as ongeki_user_pb from "../ongeki/user_pb";
|
||||
import * as grpc from "@grpc/grpc-js";
|
||||
|
||||
interface IOngekiUserService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
|
||||
getPlaylog: grpc.MethodDefinition<ongeki_user_pb.GetPlaylogRequest, ongeki_user_pb.GetPlaylogStreamItem>;
|
||||
}
|
||||
|
||||
export const OngekiUserService: IOngekiUserService;
|
||||
|
||||
export interface IOngekiUserServer extends grpc.UntypedServiceImplementation {
|
||||
getPlaylog: grpc.handleServerStreamingCall<ongeki_user_pb.GetPlaylogRequest, ongeki_user_pb.GetPlaylogStreamItem>;
|
||||
}
|
||||
|
||||
export class OngekiUserClient extends grpc.Client {
|
||||
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
|
||||
getPlaylog(argument: ongeki_user_pb.GetPlaylogRequest, metadataOrOptions?: grpc.Metadata | grpc.CallOptions | null): grpc.ClientReadableStream<ongeki_user_pb.GetPlaylogStreamItem>;
|
||||
getPlaylog(argument: ongeki_user_pb.GetPlaylogRequest, metadata?: grpc.Metadata | null, options?: grpc.CallOptions | null): grpc.ClientReadableStream<ongeki_user_pb.GetPlaylogStreamItem>;
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
'use strict';
|
||||
var grpc = require('@grpc/grpc-js');
|
||||
var ongeki_user_pb = require('../ongeki/user_pb.js');
|
||||
var ongeki_playlog_pb = require('../ongeki/playlog_pb.js');
|
||||
|
||||
function serialize_mythos_ongeki_v0_GetPlaylogRequest(arg) {
|
||||
if (!(arg instanceof ongeki_user_pb.GetPlaylogRequest)) {
|
||||
throw new Error('Expected argument of type mythos.ongeki.v0.GetPlaylogRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_mythos_ongeki_v0_GetPlaylogRequest(buffer_arg) {
|
||||
return ongeki_user_pb.GetPlaylogRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_mythos_ongeki_v0_GetPlaylogStreamItem(arg) {
|
||||
if (!(arg instanceof ongeki_user_pb.GetPlaylogStreamItem)) {
|
||||
throw new Error('Expected argument of type mythos.ongeki.v0.GetPlaylogStreamItem');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_mythos_ongeki_v0_GetPlaylogStreamItem(buffer_arg) {
|
||||
return ongeki_user_pb.GetPlaylogStreamItem.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
|
||||
var OngekiUserService = exports.OngekiUserService = {
|
||||
getPlaylog: {
|
||||
path: '/mythos.ongeki.v0.OngekiUser/GetPlaylog',
|
||||
requestStream: false,
|
||||
responseStream: true,
|
||||
requestType: ongeki_user_pb.GetPlaylogRequest,
|
||||
responseType: ongeki_user_pb.GetPlaylogStreamItem,
|
||||
requestSerialize: serialize_mythos_ongeki_v0_GetPlaylogRequest,
|
||||
requestDeserialize: deserialize_mythos_ongeki_v0_GetPlaylogRequest,
|
||||
responseSerialize: serialize_mythos_ongeki_v0_GetPlaylogStreamItem,
|
||||
responseDeserialize: deserialize_mythos_ongeki_v0_GetPlaylogStreamItem,
|
||||
},
|
||||
};
|
||||
|
||||
exports.OngekiUserClient = grpc.makeGenericClientConstructor(OngekiUserService);
|
||||
+70
@@ -0,0 +1,70 @@
|
||||
// package: mythos.ongeki.v0
|
||||
// file: ongeki/user.proto
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
import * as ongeki_playlog_pb from "../ongeki/playlog_pb";
|
||||
|
||||
export class GetPlaylogRequest extends jspb.Message {
|
||||
getProfileApiId(): string;
|
||||
setProfileApiId(value: string): void;
|
||||
|
||||
hasLastUserPlayDate(): boolean;
|
||||
clearLastUserPlayDate(): void;
|
||||
getLastUserPlayDate(): string;
|
||||
setLastUserPlayDate(value: string): void;
|
||||
|
||||
hasLimit(): boolean;
|
||||
clearLimit(): void;
|
||||
getLimit(): number;
|
||||
setLimit(value: number): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): GetPlaylogRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: GetPlaylogRequest): GetPlaylogRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: GetPlaylogRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): GetPlaylogRequest;
|
||||
static deserializeBinaryFromReader(message: GetPlaylogRequest, reader: jspb.BinaryReader): GetPlaylogRequest;
|
||||
}
|
||||
|
||||
export namespace GetPlaylogRequest {
|
||||
export type AsObject = {
|
||||
profileApiId: string,
|
||||
lastUserPlayDate: string,
|
||||
limit: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class GetPlaylogStreamItem extends jspb.Message {
|
||||
getPlaylogApiId(): string;
|
||||
setPlaylogApiId(value: string): void;
|
||||
|
||||
hasInfo(): boolean;
|
||||
clearInfo(): void;
|
||||
getInfo(): ongeki_playlog_pb.PlaylogInfo | undefined;
|
||||
setInfo(value?: ongeki_playlog_pb.PlaylogInfo): void;
|
||||
|
||||
hasJudge(): boolean;
|
||||
clearJudge(): void;
|
||||
getJudge(): ongeki_playlog_pb.PlaylogJudge | undefined;
|
||||
setJudge(value?: ongeki_playlog_pb.PlaylogJudge): void;
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): GetPlaylogStreamItem.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: GetPlaylogStreamItem): GetPlaylogStreamItem.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: GetPlaylogStreamItem, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): GetPlaylogStreamItem;
|
||||
static deserializeBinaryFromReader(message: GetPlaylogStreamItem, reader: jspb.BinaryReader): GetPlaylogStreamItem;
|
||||
}
|
||||
|
||||
export namespace GetPlaylogStreamItem {
|
||||
export type AsObject = {
|
||||
playlogApiId: string,
|
||||
info?: ongeki_playlog_pb.PlaylogInfo.AsObject,
|
||||
judge?: ongeki_playlog_pb.PlaylogJudge.AsObject,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,528 @@
|
||||
// source: ongeki/user.proto
|
||||
/**
|
||||
* @fileoverview
|
||||
* @enhanceable
|
||||
* @suppress {missingRequire} reports error on implicit type usages.
|
||||
* @suppress {messageConventions} JS Compiler reports an error if a variable or
|
||||
* field starts with 'MSG_' and isn't a translatable message.
|
||||
* @public
|
||||
*/
|
||||
// GENERATED CODE -- DO NOT EDIT!
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
var jspb = require('google-protobuf');
|
||||
var goog = jspb;
|
||||
var global = (function() {
|
||||
if (this) { return this; }
|
||||
if (typeof window !== 'undefined') { return window; }
|
||||
if (typeof global !== 'undefined') { return global; }
|
||||
if (typeof self !== 'undefined') { return self; }
|
||||
return Function('return this')();
|
||||
}.call(null));
|
||||
|
||||
var ongeki_playlog_pb = require('../ongeki/playlog_pb.js');
|
||||
goog.object.extend(proto, ongeki_playlog_pb);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.GetPlaylogRequest', null, global);
|
||||
goog.exportSymbol('proto.mythos.ongeki.v0.GetPlaylogStreamItem', null, global);
|
||||
/**
|
||||
* Generated by JsPbCodeGenerator.
|
||||
* @param {Array=} opt_data Optional initial data array, typically from a
|
||||
* server response, or constructed directly in Javascript. The array is used
|
||||
* in place and becomes part of the constructed object. It is not cloned.
|
||||
* If no data is provided, the constructed object will be empty, but still
|
||||
* valid.
|
||||
* @extends {jspb.Message}
|
||||
* @constructor
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.mythos.ongeki.v0.GetPlaylogRequest, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.displayName = 'proto.mythos.ongeki.v0.GetPlaylogRequest';
|
||||
}
|
||||
/**
|
||||
* Generated by JsPbCodeGenerator.
|
||||
* @param {Array=} opt_data Optional initial data array, typically from a
|
||||
* server response, or constructed directly in Javascript. The array is used
|
||||
* in place and becomes part of the constructed object. It is not cloned.
|
||||
* If no data is provided, the constructed object will be empty, but still
|
||||
* valid.
|
||||
* @extends {jspb.Message}
|
||||
* @constructor
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.mythos.ongeki.v0.GetPlaylogStreamItem, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.displayName = 'proto.mythos.ongeki.v0.GetPlaylogStreamItem';
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.mythos.ongeki.v0.GetPlaylogRequest.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogRequest} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
profileApiId: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
||||
lastUserPlayDate: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
||||
limit: jspb.Message.getFieldWithDefault(msg, 3, 0)
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.mythos.ongeki.v0.GetPlaylogRequest;
|
||||
return proto.mythos.ongeki.v0.GetPlaylogRequest.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogRequest} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = /** @type {string} */ (reader.readString());
|
||||
msg.setProfileApiId(value);
|
||||
break;
|
||||
case 2:
|
||||
var value = /** @type {string} */ (reader.readString());
|
||||
msg.setLastUserPlayDate(value);
|
||||
break;
|
||||
case 3:
|
||||
var value = /** @type {number} */ (reader.readUint64());
|
||||
msg.setLimit(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogRequest} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getProfileApiId();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = /** @type {string} */ (jspb.Message.getField(message, 2));
|
||||
if (f != null) {
|
||||
writer.writeString(
|
||||
2,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = /** @type {number} */ (jspb.Message.getField(message, 3));
|
||||
if (f != null) {
|
||||
writer.writeUint64(
|
||||
3,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string profile_api_id = 1;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.getProfileApiId = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.setProfileApiId = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string last_user_play_date = 2;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.getLastUserPlayDate = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.setLastUserPlayDate = function(value) {
|
||||
return jspb.Message.setField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the field making it undefined.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.clearLastUserPlayDate = function() {
|
||||
return jspb.Message.setField(this, 2, undefined);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns whether this field is set.
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.hasLastUserPlayDate = function() {
|
||||
return jspb.Message.getField(this, 2) != null;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional uint64 limit = 3;
|
||||
* @return {number}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.getLimit = function() {
|
||||
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {number} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.setLimit = function(value) {
|
||||
return jspb.Message.setField(this, 3, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the field making it undefined.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogRequest} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.clearLimit = function() {
|
||||
return jspb.Message.setField(this, 3, undefined);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns whether this field is set.
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogRequest.prototype.hasLimit = function() {
|
||||
return jspb.Message.getField(this, 3) != null;
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.mythos.ongeki.v0.GetPlaylogStreamItem.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
playlogApiId: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
||||
info: (f = msg.getInfo()) && ongeki_playlog_pb.PlaylogInfo.toObject(includeInstance, f),
|
||||
judge: (f = msg.getJudge()) && ongeki_playlog_pb.PlaylogJudge.toObject(includeInstance, f)
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.mythos.ongeki.v0.GetPlaylogStreamItem;
|
||||
return proto.mythos.ongeki.v0.GetPlaylogStreamItem.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = /** @type {string} */ (reader.readString());
|
||||
msg.setPlaylogApiId(value);
|
||||
break;
|
||||
case 2:
|
||||
var value = new ongeki_playlog_pb.PlaylogInfo;
|
||||
reader.readMessage(value,ongeki_playlog_pb.PlaylogInfo.deserializeBinaryFromReader);
|
||||
msg.setInfo(value);
|
||||
break;
|
||||
case 3:
|
||||
var value = new ongeki_playlog_pb.PlaylogJudge;
|
||||
reader.readMessage(value,ongeki_playlog_pb.PlaylogJudge.deserializeBinaryFromReader);
|
||||
msg.setJudge(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getPlaylogApiId();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getInfo();
|
||||
if (f != null) {
|
||||
writer.writeMessage(
|
||||
2,
|
||||
f,
|
||||
ongeki_playlog_pb.PlaylogInfo.serializeBinaryToWriter
|
||||
);
|
||||
}
|
||||
f = message.getJudge();
|
||||
if (f != null) {
|
||||
writer.writeMessage(
|
||||
3,
|
||||
f,
|
||||
ongeki_playlog_pb.PlaylogJudge.serializeBinaryToWriter
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string playlog_api_id = 1;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.getPlaylogApiId = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.setPlaylogApiId = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional PlaylogInfo info = 2;
|
||||
* @return {?proto.mythos.ongeki.v0.PlaylogInfo}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.getInfo = function() {
|
||||
return /** @type{?proto.mythos.ongeki.v0.PlaylogInfo} */ (
|
||||
jspb.Message.getWrapperField(this, ongeki_playlog_pb.PlaylogInfo, 2));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {?proto.mythos.ongeki.v0.PlaylogInfo|undefined} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.setInfo = function(value) {
|
||||
return jspb.Message.setWrapperField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the message field making it undefined.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.clearInfo = function() {
|
||||
return this.setInfo(undefined);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns whether this field is set.
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.hasInfo = function() {
|
||||
return jspb.Message.getField(this, 2) != null;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional PlaylogJudge judge = 3;
|
||||
* @return {?proto.mythos.ongeki.v0.PlaylogJudge}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.getJudge = function() {
|
||||
return /** @type{?proto.mythos.ongeki.v0.PlaylogJudge} */ (
|
||||
jspb.Message.getWrapperField(this, ongeki_playlog_pb.PlaylogJudge, 3));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {?proto.mythos.ongeki.v0.PlaylogJudge|undefined} value
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.setJudge = function(value) {
|
||||
return jspb.Message.setWrapperField(this, 3, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the message field making it undefined.
|
||||
* @return {!proto.mythos.ongeki.v0.GetPlaylogStreamItem} returns this
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.clearJudge = function() {
|
||||
return this.setJudge(undefined);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Returns whether this field is set.
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.mythos.ongeki.v0.GetPlaylogStreamItem.prototype.hasJudge = function() {
|
||||
return jspb.Message.getField(this, 3) != null;
|
||||
};
|
||||
|
||||
|
||||
goog.object.extend(exports, proto.mythos.ongeki.v0);
|
||||
@@ -0,0 +1,70 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package mythos.ongeki.v0;
|
||||
|
||||
enum OngekiLevel {
|
||||
ONGEKI_LEVEL_UNSPECIFIED = 0;
|
||||
ONGEKI_LEVEL_BASIC = 1;
|
||||
ONGEKI_LEVEL_ADVANCED = 2;
|
||||
ONGEKI_LEVEL_EXPERT = 3;
|
||||
ONGEKI_LEVEL_MASTER = 4;
|
||||
ONGEKI_LEVEL_LUNATIC = 5;
|
||||
}
|
||||
|
||||
enum OngekiRankingType {
|
||||
ONGEKI_RANKING_TYPE_UNSPECIFIED = 0;
|
||||
ONGEKI_RANKING_TYPE_TECH_SCORE = 1;
|
||||
ONGEKI_RANKING_TYPE_BATTLE_SCORE = 2;
|
||||
ONGEKI_RANKING_TYPE_OVER_DAMAGE = 3;
|
||||
ONGEKI_RANKING_TYPE_PLATINUM_SCORE = 4;
|
||||
}
|
||||
|
||||
enum OngekiTechScoreRank {
|
||||
ONGEKI_TECH_SCORE_RANK_UNSPECIFIED = 0;
|
||||
ONGEKI_TECH_SCORE_RANK_D = 1;
|
||||
ONGEKI_TECH_SCORE_RANK_C = 2;
|
||||
ONGEKI_TECH_SCORE_RANK_B = 3;
|
||||
ONGEKI_TECH_SCORE_RANK_BB = 4;
|
||||
ONGEKI_TECH_SCORE_RANK_BBB = 5;
|
||||
ONGEKI_TECH_SCORE_RANK_A = 6;
|
||||
ONGEKI_TECH_SCORE_RANK_AA = 7;
|
||||
ONGEKI_TECH_SCORE_RANK_AAA = 8;
|
||||
ONGEKI_TECH_SCORE_RANK_S = 9;
|
||||
ONGEKI_TECH_SCORE_RANK_S_PLUS = 10;
|
||||
ONGEKI_TECH_SCORE_RANK_SS = 11;
|
||||
ONGEKI_TECH_SCORE_RANK_SS_PLUS = 12;
|
||||
ONGEKI_TECH_SCORE_RANK_SSS = 13;
|
||||
ONGEKI_TECH_SCORE_RANK_SSS_PLUS = 14;
|
||||
}
|
||||
|
||||
enum OngekiBattleScoreRank {
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNSPECIFIED = 0;
|
||||
ONGEKI_BATTLE_SCORE_RANK_NO_GOOD = 1;
|
||||
ONGEKI_BATTLE_SCORE_RANK_USUALLY = 2;
|
||||
ONGEKI_BATTLE_SCORE_RANK_GOOD = 3;
|
||||
ONGEKI_BATTLE_SCORE_RANK_GREAT = 4;
|
||||
ONGEKI_BATTLE_SCORE_RANK_EXCELLENT = 5;
|
||||
ONGEKI_BATTLE_SCORE_RANK_UNBELIEVABLE = 6;
|
||||
}
|
||||
|
||||
enum OngekiClearStatus {
|
||||
ONGEKI_CLEAR_STATUS_UNSPECIFIED = 0;
|
||||
ONGEKI_CLEAR_STATUS_FAILED = 1;
|
||||
ONGEKI_CLEAR_STATUS_CLEARED = 2;
|
||||
ONGEKI_CLEAR_STATUS_OVER_DAMAGE = 3;
|
||||
}
|
||||
|
||||
enum OngekiComboStatus {
|
||||
ONGEKI_COMBO_STATUS_UNSPECIFIED = 0;
|
||||
ONGEKI_COMBO_STATUS_NONE = 1;
|
||||
ONGEKI_COMBO_STATUS_FULL_COMBO = 2;
|
||||
ONGEKI_COMBO_STATUS_ALL_BREAK = 3;
|
||||
}
|
||||
|
||||
// This starts at 1 for some reason
|
||||
enum OngekiBossAttribute {
|
||||
ONGEKI_BOSS_ATTRIBUTE_UNSPECIFIED = 0;
|
||||
ONGEKI_BOSS_ATTRIBUTE_FIRE = 1;
|
||||
ONGEKI_BOSS_ATTRIBUTE_AQUA = 2;
|
||||
ONGEKI_BOSS_ATTRIBUTE_LEAF = 3;
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package mythos.ongeki.v0;
|
||||
|
||||
import "ongeki/common.proto";
|
||||
|
||||
message PlaylogInfo {
|
||||
int32 music_id = 1;
|
||||
OngekiLevel level = 2;
|
||||
int32 tech_score = 3;
|
||||
int32 battle_score = 4;
|
||||
int32 over_damage = 5;
|
||||
int32 platinum_score = 6;
|
||||
OngekiTechScoreRank tech_score_rank = 7;
|
||||
OngekiBattleScoreRank battle_score_rank = 8;
|
||||
OngekiComboStatus combo_status = 9;
|
||||
OngekiClearStatus clear_status = 10;
|
||||
bool is_full_bell = 11;
|
||||
bool is_tech_new_record = 12;
|
||||
bool is_battle_new_record = 13;
|
||||
bool is_over_damage_new_record = 14;
|
||||
string user_play_date = 15;
|
||||
}
|
||||
|
||||
message PlaylogJudge {
|
||||
int32 judge_critical_break = 17;
|
||||
int32 judge_break = 18;
|
||||
int32 judge_hit = 19;
|
||||
int32 judge_miss = 20;
|
||||
int32 max_combo = 21;
|
||||
int32 bell_count = 22;
|
||||
int32 total_bell_count = 23;
|
||||
int32 damage_count = 24;
|
||||
}
|
||||
|
||||
message PlaylogJudgeRate {
|
||||
int32 rate_tap = 1;
|
||||
int32 rate_hold = 2;
|
||||
int32 rate_flick = 3;
|
||||
int32 rate_side_tap = 4;
|
||||
int32 rate_side_hold = 5;
|
||||
}
|
||||
|
||||
message PlaylogMatchingUser {
|
||||
string user_name = 1;
|
||||
OngekiLevel music_level = 2;
|
||||
}
|
||||
|
||||
message PlaylogCard {
|
||||
int32 card_id = 1;
|
||||
int32 card_level = 2;
|
||||
int32 card_attack = 3;
|
||||
}
|
||||
|
||||
message PlaylogBoss {
|
||||
int32 boss_id = 1;
|
||||
int32 boss_level = 2;
|
||||
OngekiBossAttribute boss_attribute = 3;
|
||||
}
|
||||
|
||||
message PlaylogEvent {
|
||||
int32 event_id = 1;
|
||||
string event_name = 2;
|
||||
int32 event_point = 3;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package mythos.ongeki.v0;
|
||||
|
||||
import "ongeki/playlog.proto";
|
||||
|
||||
service OngekiUser {
|
||||
rpc GetPlaylog(GetPlaylogRequest) returns (stream GetPlaylogStreamItem);
|
||||
}
|
||||
|
||||
// PLAYLOG
|
||||
|
||||
message GetPlaylogRequest {
|
||||
string profile_api_id = 1;
|
||||
optional string last_user_play_date = 2;
|
||||
optional uint64 limit = 3;
|
||||
}
|
||||
|
||||
message GetPlaylogStreamItem {
|
||||
string playlog_api_id = 1;
|
||||
PlaylogInfo info = 2;
|
||||
PlaylogJudge judge = 3;
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
[
|
||||
{
|
||||
"chartID": "e5e4ee3d4feb233c399751b3ba3daf8ba149c9e6",
|
||||
"data": {
|
||||
"displayVersion": "bright",
|
||||
"inGameID": 678,
|
||||
"maxPlatScore": 2768
|
||||
},
|
||||
"difficulty": "MASTER",
|
||||
"isPrimary": true,
|
||||
"level": "13+",
|
||||
"levelNum": 13.7,
|
||||
"playtype": "Single",
|
||||
"songID": 683,
|
||||
"versions": ["brightMemory3Omni", "brightMemory3"]
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,12 @@
|
||||
[
|
||||
{
|
||||
"altTitles": ["SENOTETOHETSUTEITSUTENNO"],
|
||||
"artist": "本城香澄(CV:岩橋由佳)「Re:ステージ!プリズムステップ」",
|
||||
"data": {
|
||||
"genre": "POPS&ANIME"
|
||||
},
|
||||
"id": 683,
|
||||
"searchTerms": [],
|
||||
"title": "せーので跳べって言ってんの!"
|
||||
}
|
||||
]
|
||||
@@ -1280,3 +1280,30 @@ export const TestingOngekiChart: ChartDocument<"ongeki:Single"> = {
|
||||
songID: 19,
|
||||
versions: ["brightMemory3", "brightMemory3Omni"],
|
||||
};
|
||||
|
||||
export const TestingOngekiChartConverter: ChartDocument<"ongeki:Single"> = {
|
||||
chartID: "e5e4ee3d4feb233c399751b3ba3daf8ba149c9e6",
|
||||
data: {
|
||||
displayVersion: "bright",
|
||||
inGameID: 678,
|
||||
maxPlatScore: 2768,
|
||||
},
|
||||
difficulty: "MASTER",
|
||||
isPrimary: true,
|
||||
level: "13+",
|
||||
levelNum: 13.7,
|
||||
playtype: "Single",
|
||||
songID: 683,
|
||||
versions: ["brightMemory3Omni", "brightMemory3"],
|
||||
};
|
||||
|
||||
export const TestingOngekiSongConverter: SongDocument<"ongeki"> = {
|
||||
altTitles: ["SENOTETOHETSUTEITSUTENNO"],
|
||||
artist: "本城香澄(CV:岩橋由佳)「Re:ステージ!プリズムステップ」",
|
||||
data: {
|
||||
genre: "POPS&ANIME",
|
||||
},
|
||||
id: 683,
|
||||
searchTerms: [],
|
||||
title: "せーので跳べって言ってんの!",
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user