Exceed Gear y-1
|
|
@ -1,9 +1,32 @@
|
|||
# SOUND VOLTEX
|
||||
|
||||
Plugin Version: **v1.1**
|
||||
Plugin Version: **v6.0.0**
|
||||
|
||||
Supported Versions:
|
||||
|
||||
- BOOTH
|
||||
- HEAVENLY HAVEN
|
||||
- VIVID WAVE
|
||||
- VIVIDWAVE
|
||||
- EXCEED GEAR
|
||||
|
||||
Versions Not Supported:
|
||||
|
||||
- INFINITE INFECTION
|
||||
- GRAVITY WARS
|
||||
|
||||
The plugin now mainly maintained versions:
|
||||
|
||||
- VIVIDWAVE
|
||||
- EXCEED GEAR
|
||||
|
||||
Change Log
|
||||
===========
|
||||
|
||||
## 6.0.0
|
||||
|
||||
1. Plugin version now follows the pattern (MAX SDVX VER,Plugin VER of supporting the MAX version of SDVX,hotfix).
|
||||
2. Initial support for EXCEED GEAR.
|
||||
|
||||
## 1.1
|
||||
|
||||
1. Support VIVIDWAVE
|
||||
1255
sdvx@asphyxia/data/exg.ts
Normal file
32
sdvx@asphyxia/data/inf.ts
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
export const COURSE2 = [
|
||||
{
|
||||
id: 0,
|
||||
level: 0,
|
||||
season_id: 0,
|
||||
season_name: '',
|
||||
new_flg: 0,
|
||||
name: '',
|
||||
type: 0,
|
||||
name_id: 0,
|
||||
matching_assist: 0,
|
||||
guage_type: 0,
|
||||
paseli_type: 0,
|
||||
tracks: [
|
||||
{
|
||||
no: 0,
|
||||
id: 2,
|
||||
type: 0
|
||||
},
|
||||
{
|
||||
no: 1,
|
||||
id: 2,
|
||||
type: 0
|
||||
},
|
||||
{
|
||||
no: 2,
|
||||
id: 2,
|
||||
type: 0
|
||||
},
|
||||
]
|
||||
},
|
||||
];
|
||||
|
|
@ -13,7 +13,7 @@ export const EVENT5 = [
|
|||
'FACTORY\t10',
|
||||
'CONTINUATION',
|
||||
'APPEAL_CARD_GEN_NEW_PRICE',
|
||||
'APPEAL_CARD_UNLOCK\t0,30170914,0,30171014,0,30171116,0,30180201,0,30180607,0,30181206,0,30200326,0,30200611',
|
||||
'APPEAL_CARD_UNLOCK\t0,30170914,0,30171014,0,30171116,0,30180201,0,30180607,0,30181206,0,30200326,0,30200611,4,10140732,6,10150431',
|
||||
'FAVORITE_APPEALCARD_MAX\t100',
|
||||
'FAVORITE_MUSIC_MAX\t500',
|
||||
'EVENTDATE_APRILFOOL',
|
||||
|
|
@ -2474,7 +2474,7 @@ export const COURSES5 = [
|
|||
id: 13,
|
||||
name: 'SKILL ANALYZER 第5回',
|
||||
isNew: 1,
|
||||
courses:[
|
||||
courses: [
|
||||
{
|
||||
id: 1,
|
||||
type: 0,
|
||||
|
|
@ -2781,7 +2781,7 @@ export const COURSES5 = [
|
|||
id: 14,
|
||||
name: 'SKILL ANALYZER 第6回',
|
||||
isNew: 1,
|
||||
courses:[
|
||||
courses: [
|
||||
{
|
||||
id: 1,
|
||||
type: 0,
|
||||
|
|
|
|||
|
|
@ -1,38 +1,61 @@
|
|||
import { EVENT4, COURSES4, EXTENDS4 } from '../data/hvn';
|
||||
import { EVENT5, COURSES5, EXTENDS5 } from '../data/vvw';
|
||||
|
||||
import { EVENT6, COURSES6, EXTENDS6 } from '../data/exg';
|
||||
import { COURSE2 } from '../data/inf';
|
||||
import {getVersion, getRandomIntInclusive} from '../utils';
|
||||
export const common: EPR = async (info, data, send) => {
|
||||
let events = [];
|
||||
let courses = [];
|
||||
let extend = [];
|
||||
|
||||
console.log("Calling common function");
|
||||
|
||||
const version = parseInt(info.model.split(":")[4]);
|
||||
|
||||
if (version <= 2013052900) {
|
||||
return send.pugFile('templates/booth/common.pug');
|
||||
}
|
||||
|
||||
if (version <= 2014112000) {
|
||||
courses = COURSE2;
|
||||
return send.pugFile('templates/infiniteinfection/common.pug',{
|
||||
courses,
|
||||
});
|
||||
}
|
||||
|
||||
switch (info.method) {
|
||||
case 'sv4_common': {
|
||||
events = EVENT4;
|
||||
courses = COURSES4;
|
||||
extend = EXTENDS4;
|
||||
//extend = EXTENDS4;
|
||||
EXTENDS4.forEach(val => extend.push(Object.assign({}, val)));
|
||||
break;
|
||||
}
|
||||
case 'sv5_common': {
|
||||
events = EVENT5;
|
||||
courses = COURSES5;
|
||||
extend = EXTENDS5;
|
||||
//extend = EXTENDS5;
|
||||
EXTENDS5.forEach(val => extend.push(Object.assign({}, val)));
|
||||
break;
|
||||
}
|
||||
case 'sv6_common': {
|
||||
//events = EVENT6;
|
||||
EVENT6.forEach(val => events.push(Object.assign({}, val));
|
||||
courses = COURSES6;
|
||||
EXTENDS6.forEach(val => extend.push(Object.assign({}, val)));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
let songs = [];
|
||||
|
||||
if (U.GetConfig('unlock_all_songs')) {
|
||||
for (let i = 1; i < 1700; ++i) {
|
||||
console.log("Unlocking songs");
|
||||
const gameVersion = getVersion(info);
|
||||
let songNum = 2000;
|
||||
if(gameVersion === 2) songNum = 554;
|
||||
if(gameVersion === 3) songNum = 954;
|
||||
if(gameVersion === 4) songNum = 1368;
|
||||
for (let i = 1; i < songNum; ++i) {
|
||||
for (let j = 0; j < 5; ++j) {
|
||||
|
||||
songs.push({
|
||||
music_id: K.ITEM('s32', i),
|
||||
music_type: K.ITEM('u8', j),
|
||||
|
|
@ -42,7 +65,142 @@ export const common: EPR = async (info, data, send) => {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(U.GetConfig('use_information')){
|
||||
console.log("Sending server information");
|
||||
let time = new Date();
|
||||
let tempDate = time.getDate();
|
||||
const currentTime = parseInt((time.getTime()/100000) as unknown as string)*100;
|
||||
extend.push({
|
||||
id: 1,
|
||||
type: 1,
|
||||
params: [
|
||||
1,
|
||||
currentTime,
|
||||
1,
|
||||
1,
|
||||
31,
|
||||
'[f:0]SERVER INFORMATION',
|
||||
'[sz:120] [olc:555555][ol:4][c:ff3333,3333ff,77ff77]Asphyxia\n'+
|
||||
'[sz:75] CORE\n[sz:30]'+
|
||||
'[sz:30][c:ffffff,888888] \n \n'+
|
||||
' [c:00d5ff,888888]ASPHYXIA CORE'+CORE_VERSION+'\n'+
|
||||
' [c:e5f3ff,a3d5ff]SDVX Plugin ver 6.0.0\n \n \n'+
|
||||
'\n\n [f:0][c:ff3333,ffffff]FREE SOFTWARE. BEWARE OF SCAMMERS.\n'+
|
||||
'[c:ffffff,888888] If you bought this software, request refund immediately.\n \n \n[/ol]'+
|
||||
'[br:10][c:00FFFF][sz:50]メリー。。。クリスマス、です。。。'+
|
||||
'\n \n \n \n[sz:32][c:560000,FC0000]DO NOT STREAM OR DISTRIBUTE THIS GAME IN PUBLIC',
|
||||
//'[img:test]',
|
||||
'',
|
||||
'',
|
||||
'',
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
if(U.GetConfig('new_year_special')){
|
||||
events.push('NEW_YEAR_2022');
|
||||
}
|
||||
|
||||
if(U.GetConfig('use_asphyxia_gameover')){
|
||||
let time = new Date();
|
||||
let tempDate = time.getDate();
|
||||
const currentTime = parseInt((time.getTime()/100000) as unknown as string)*100;
|
||||
let rightCharater = [
|
||||
"go_bansui","go_bof","go_cannon","go_chinema","go_chocopla",
|
||||
"go_dd","go_ekusa","go_esp","go_flowry","go_fukuryu",
|
||||
"go_gorilla","go_grace","go_grace_rori","go_grace_ver06","go_haelequin",
|
||||
"go_haruka","go_joyeuse","go_kino","go_kisa","go_mai",
|
||||
"go_makina","go_makishima","go_left","go_makishima_ver06","go_mitsuru","go_miyako",
|
||||
"go_nana","go_natsuhi","go_noisia","go_left_ver06","go_ondine","go_pannakotta",
|
||||
"go_psychoholic","go_rain","go_rain02","go_ribbon","go_right",
|
||||
"go_riot","go_rishna","go_rouge","go_sakurako","go_satan",
|
||||
"go_tama","go_torako","go_vela","go_vertex","go_wabutan",
|
||||
"go_wanlove","go_yusya",
|
||||
];
|
||||
let leftCharater = [
|
||||
"go_akane","go_apex4sis","go_candy","go_capsaicin","go_chikage",
|
||||
"go_evileye","go_fluorine","go_gangara","go_gin","go_hero",
|
||||
"go_hiryubiren","go_hiyuki","go_hotaru","go_inoten","go_kamito",
|
||||
"go_kanade","go_kemuri","go_kokona","go_konoha","go_kouki",
|
||||
"go_kureha","go_left_bag","go_madholic",
|
||||
"go_mimiko","go_mion","go_mitsuruco","go_nathanael","go_nishinippori",
|
||||
"go_ortlinde","go_pico","go_pilica","go_profession","go_rasis",
|
||||
"go_rasis_ver06","go_right_ver06","go_rimuru","go_rowa","go_saigawara",
|
||||
"go_setu","go_shelly","go_soul","go_tamaneko","go_toraipuru",
|
||||
"go_tsubaki","go_tsumabuki","go_tsumabuki_ver06","go_yuki","go_yukito",
|
||||
];
|
||||
let middleCharater = ["go_cat","go_cawoashi","go_iruyoru","go_neno",];
|
||||
// Pattern 1 Left Right Left
|
||||
// Pattern 2 Right Left Right
|
||||
// Pattern 3 Right Middle Left
|
||||
// Pattern 4 Left Middle Right
|
||||
// switch(getVersion(info)){
|
||||
// case 5:{
|
||||
// break;
|
||||
// }
|
||||
// case 6:{
|
||||
// rightCharater.push();
|
||||
// leftCharater.push();
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
var charaString = "characters: ";
|
||||
let pattern = getRandomIntInclusive(1,4);
|
||||
switch(pattern){
|
||||
case 1:{
|
||||
var chara1 = leftCharater[getRandomIntInclusive(0,leftCharater.length-1)];
|
||||
var chara2 = rightCharater[getRandomIntInclusive(0,rightCharater.length-1)];
|
||||
var chara3 = leftCharater[getRandomIntInclusive(0,leftCharater.length-1)];
|
||||
charaString += "chara01/"+chara1+" chara02/"+chara2+" chara01/"+chara3;
|
||||
break;
|
||||
}
|
||||
case 2:{
|
||||
var chara1 = rightCharater[getRandomIntInclusive(0,rightCharater.length-1)];
|
||||
var chara2 = leftCharater[getRandomIntInclusive(0,leftCharater.length-1)];
|
||||
var chara3 = rightCharater[getRandomIntInclusive(0,rightCharater.length-1)];
|
||||
charaString += "chara02/"+chara1+" chara01/"+chara2+" chara02/"+chara3;
|
||||
break;
|
||||
}
|
||||
case 3:{
|
||||
var chara1 = rightCharater[getRandomIntInclusive(0,rightCharater.length-1)];
|
||||
var chara2 = middleCharater[getRandomIntInclusive(0,middleCharater.length-1)]
|
||||
var chara3 = leftCharater[getRandomIntInclusive(0,leftCharater.length-1)];
|
||||
charaString += "chara02/"+chara1+" chara03/"+chara2+" chara01/"+chara3;
|
||||
break;
|
||||
}
|
||||
case 4:{
|
||||
var chara1 = leftCharater[getRandomIntInclusive(0,leftCharater.length-1)];
|
||||
var chara2 = middleCharater[getRandomIntInclusive(0,middleCharater.length-1)];
|
||||
var chara3 = rightCharater[getRandomIntInclusive(0,rightCharater.length-1)];
|
||||
charaString += "chara01/"+chara1+" chara03/"+chara2+" chara02/"+chara3;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(Math.abs(getVersion(info)) == 6){//Due to older version misses newer characters, not supported on older versions
|
||||
extend.push({
|
||||
id: 3,
|
||||
type: 1,
|
||||
params: [
|
||||
3,
|
||||
currentTime,
|
||||
0,
|
||||
60,
|
||||
0,
|
||||
'[GAMEOVER]',
|
||||
'[ol:6][olc:FFFFFF][ds:4][dsc:000000][sz:32][c:99FF00A8]Thank You For Using Asphyxia CORE!!!',
|
||||
'[ol:6][olc:FFFFFF][ds:4][dsc:000000][sz:32][c:990D46F2]For more information please visit our Discord!',
|
||||
'[ol:6][olc:FFFFFF][ds:4][dsc:000000][sz:32][c:99ED4F39]Nice Play!!!',
|
||||
//'characters: chara01/go_rasis_ver06 chara02/go_left_ver06 chara01/go_right_ver06',
|
||||
charaString,
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
console.log("Sending common objects");
|
||||
send.object(
|
||||
{
|
||||
event: {
|
||||
|
|
@ -97,3 +255,9 @@ export const common: EPR = async (info, data, send) => {
|
|||
{ encoding: 'utf8' }
|
||||
);
|
||||
};
|
||||
|
||||
|
||||
export const log: EPR = async (info, data, send) => {
|
||||
send.success();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import {Profile} from '../models/profile';
|
||||
import {MusicRecord} from '../models/music_record';
|
||||
import {getVersion, IDToCode, GetCounter} from '../utils';
|
||||
import {Mix} from '../models/mix';
|
||||
import { Profile } from '../models/profile';
|
||||
import { MusicRecord } from '../models/music_record';
|
||||
import { getVersion, IDToCode, GetCounter } from '../utils';
|
||||
import { Mix } from '../models/mix';
|
||||
|
||||
export const hiscore: EPR = async (info, data, send) => {
|
||||
const records = await DB.Find<MusicRecord>(null, { collection: 'music' });
|
||||
|
|
@ -152,3 +152,29 @@ export const loadMix: EPR = async (info, data, send) => {
|
|||
},
|
||||
});
|
||||
};
|
||||
|
||||
export const globalMatch: EPR = async (info, data, send) => {
|
||||
// console.log("Current MID: "+$(data).number('mid'));
|
||||
// console.log("Port: "+$(data).number('port'));
|
||||
// console.log("Global IP: "+$(data).numbers('gip'));
|
||||
// console.log("Private IP: "+$(data).numbers('lip'));
|
||||
|
||||
// var mid = $(data).number('mid');
|
||||
// var port = $(data).number('port');
|
||||
// var gip = $(data).str('gip');
|
||||
// var lip = $(data).str('lip');
|
||||
// var testArray = [{
|
||||
// port: port,
|
||||
// gip:gip,
|
||||
// lip:lip,
|
||||
// }];
|
||||
// return send.object({
|
||||
// entry_id: K.ITEM('str', '123456789'),
|
||||
// entry: testArray.map(a=>{
|
||||
// port: K.ITEM('u16',a.port);
|
||||
// gip: K.ITEM('ip4',a.gip);
|
||||
// lip: K.ITEM('ip4',a.lip);
|
||||
// })
|
||||
// });
|
||||
send.success();
|
||||
}
|
||||
|
|
@ -1,12 +1,12 @@
|
|||
import {Skill} from '../models/skill';
|
||||
import {SDVX_AUTOMATION_SONGS} from '../data/vvw';
|
||||
import {Item} from '../models/item';
|
||||
import {Param} from '../models/param';
|
||||
import {MusicRecord} from '../models/music_record';
|
||||
import {CourseRecord} from '../models/course_record';
|
||||
import {Profile} from '../models/profile';
|
||||
import {getVersion, IDToCode} from '../utils';
|
||||
import {Mix} from '../models/mix';
|
||||
import { Skill } from '../models/skill';
|
||||
import { SDVX_AUTOMATION_SONGS } from '../data/vvw';
|
||||
import { Item } from '../models/item';
|
||||
import { Param } from '../models/param';
|
||||
import { MusicRecord } from '../models/music_record';
|
||||
import { CourseRecord } from '../models/course_record';
|
||||
import { Profile } from '../models/profile';
|
||||
import { getVersion, IDToCode } from '../utils';
|
||||
import { Mix } from '../models/mix';
|
||||
|
||||
async function getAutomationMixes(params: Param[]) {
|
||||
const mixids = params
|
||||
|
|
@ -17,20 +17,33 @@ async function getAutomationMixes(params: Param[]) {
|
|||
|
||||
function unlockNavigators(items: Partial<Item>[]) {
|
||||
for (let i = 0; i < 300; ++i) items.push({ type: 11, id: i, param: 15 });
|
||||
|
||||
console.log("Unlocking Navigators");
|
||||
// 10 genesis card for MITSURU's voice
|
||||
items.push({ type: 4, id: 599, param: 10 });
|
||||
return items;
|
||||
}
|
||||
|
||||
export const loadScore: EPR = async (info, data, send) => {
|
||||
const refid = $(data).str('refid', $(data).attr().dataid);
|
||||
if (!refid) return send.deny();
|
||||
function unlockAppealCards(items: Partial<Item>[]) {
|
||||
for (let i = 0; i < 6000; ++i) items.push({ type: 1, id: i, param: 1 });
|
||||
console.log("Unlocking Appeal Cards");
|
||||
|
||||
return items;
|
||||
}
|
||||
|
||||
export const loadScore: EPR = async (info, data, send) => {
|
||||
console.log("Now loading score");
|
||||
const version = Math.abs(getVersion(info));
|
||||
console.log("Got version:" + version);
|
||||
let refid = $(data).str('refid', $(data).attr().dataid);
|
||||
if (version === 2) refid = $(data).str('dataid', '0');
|
||||
//console.log('loading score');
|
||||
console.log("DataID:" + refid);
|
||||
if (!refid) return send.deny();
|
||||
console.log('Finding record');
|
||||
const records = await DB.Find<MusicRecord>(refid, { collection: 'music' });
|
||||
|
||||
const version = getVersion(info);
|
||||
|
||||
//console.log(version);
|
||||
if (version === 1) {
|
||||
return send.object({
|
||||
music: records.map(r => (K.ATTR({ music_id: String(r.mid) }, {
|
||||
|
|
@ -54,6 +67,93 @@ export const loadScore: EPR = async (info, data, send) => {
|
|||
});
|
||||
}
|
||||
|
||||
if (version === 2) {
|
||||
let temp = Array.from(records.values()).filter(r => (r.mid <= 554));
|
||||
//console.log([...temp]);
|
||||
//return send.pugFile('templates/infiniteinfection/score.pug', {
|
||||
// temp});
|
||||
return send.object(
|
||||
{
|
||||
"new": {
|
||||
music: temp.map(r => ({
|
||||
music_id: K.ITEM('u32', r.mid),
|
||||
music_type: K.ITEM('u32', r.type),
|
||||
score: K.ITEM('u32', r.score),
|
||||
cnt: K.ITEM('u32', 1),
|
||||
clear_type: K.ITEM('u32', r.clear),
|
||||
score_grade: K.ITEM('u32', r.grade),
|
||||
btn_rate: K.ITEM('u32', r.buttonRate),
|
||||
long_rate: K.ITEM('u32', r.longRate),
|
||||
vol_rate: K.ITEM('u32', r.volRate),
|
||||
}))
|
||||
}, old: {}
|
||||
}, { rootName: "game" });
|
||||
}
|
||||
|
||||
if (version === 6) {
|
||||
return send.object({
|
||||
music: {
|
||||
info: records.map(r => ({
|
||||
param: K.ARRAY('u32', [
|
||||
r.mid,
|
||||
r.type,
|
||||
r.score,
|
||||
r.exscore,
|
||||
r.clear,
|
||||
r.grade,
|
||||
0,
|
||||
0,
|
||||
r.buttonRate,
|
||||
r.longRate,
|
||||
r.volRate,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
]),
|
||||
})),
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
if (version === 4 || version === 3) {
|
||||
let temp = Array.from(records.values()).filter(r => (r.mid <= 1368));
|
||||
|
||||
|
||||
return send.object({
|
||||
music: {
|
||||
info: temp.map(r => ({
|
||||
param: K.ARRAY('u32', [
|
||||
r.mid,
|
||||
r.type,
|
||||
r.score,
|
||||
r.clear,
|
||||
r.grade,
|
||||
0,
|
||||
0,
|
||||
r.buttonRate,
|
||||
r.longRate,
|
||||
r.volRate,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
]),
|
||||
})
|
||||
),
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
return send.object({
|
||||
music: {
|
||||
info: records.map(r => ({
|
||||
|
|
@ -132,9 +232,62 @@ export const saveScore: EPR = async (info, data, send) => {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
if (version === -6) { // Using alternate scoring system after 20210831
|
||||
const tracks = $(data).elements('track');
|
||||
for (const i of tracks) {
|
||||
const mid = i.number('music_id');
|
||||
const type = i.number('music_type');
|
||||
if (_.isNil(mid) || _.isNil(type)) return send.deny();
|
||||
|
||||
const record = (await DB.FindOne<MusicRecord>(refid, {
|
||||
collection: 'music',
|
||||
mid,
|
||||
type,
|
||||
})) || {
|
||||
collection: 'music',
|
||||
mid,
|
||||
type,
|
||||
score: 0,
|
||||
exscore: 0,
|
||||
clear: 0,
|
||||
grade: 0,
|
||||
buttonRate: 0,
|
||||
longRate: 0,
|
||||
volRate: 0,
|
||||
};
|
||||
|
||||
const score = i.number('score', 0);
|
||||
const exscore = i.number('exscore', 0);
|
||||
if (score > record.score) {
|
||||
record.score = score;
|
||||
record.buttonRate = i.number('btn_rate', 0);
|
||||
record.longRate = i.number('long_rate', 0);
|
||||
record.volRate = i.number('vol_rate', 0);
|
||||
}
|
||||
if (exscore > record.exscore) {
|
||||
record.exscore = exscore;
|
||||
}
|
||||
|
||||
record.clear = Math.max(i.number('clear_type', 0), record.clear);
|
||||
record.grade = Math.max(i.number('score_grade', 0), record.grade);
|
||||
|
||||
|
||||
|
||||
await DB.Upsert<MusicRecord>(
|
||||
refid,
|
||||
{ collection: 'music', mid, type },
|
||||
record
|
||||
);
|
||||
}
|
||||
return send.success();
|
||||
}
|
||||
|
||||
|
||||
|
||||
const mid = $(data).number('music_id');
|
||||
const type = $(data).number('music_type');
|
||||
|
||||
console.log("Saving score for version later than HH(include), ID:" + mid + " type:" + type);
|
||||
if (_.isNil(mid) || _.isNil(type)) return send.deny();
|
||||
|
||||
const record = (await DB.FindOne<MusicRecord>(refid, {
|
||||
|
|
@ -146,6 +299,7 @@ export const saveScore: EPR = async (info, data, send) => {
|
|||
mid,
|
||||
type,
|
||||
score: 0,
|
||||
exscore: 0,
|
||||
clear: 0,
|
||||
grade: 0,
|
||||
buttonRate: 0,
|
||||
|
|
@ -154,16 +308,22 @@ export const saveScore: EPR = async (info, data, send) => {
|
|||
};
|
||||
|
||||
const score = $(data).number('score', 0);
|
||||
const exscore = $(data).number('exscore', 0);
|
||||
if (score > record.score) {
|
||||
record.score = score;
|
||||
record.buttonRate = $(data).number('btn_rate', 0);
|
||||
record.longRate = $(data).number('long_rate', 0);
|
||||
record.volRate = $(data).number('vol_rate', 0);
|
||||
}
|
||||
if (exscore > record.exscore) {
|
||||
record.exscore = exscore;
|
||||
}
|
||||
|
||||
record.clear = Math.max($(data).number('clear_type', 0), record.clear);
|
||||
record.grade = Math.max($(data).number('score_grade', 0), record.grade);
|
||||
|
||||
|
||||
|
||||
await DB.Upsert<MusicRecord>(
|
||||
refid,
|
||||
{ collection: 'music', mid, type },
|
||||
|
|
@ -177,7 +337,7 @@ export const saveCourse: EPR = async (info, data, send) => {
|
|||
const refid = $(data).str('refid');
|
||||
if (!refid) return send.deny();
|
||||
|
||||
const version = getVersion(info);
|
||||
const version = Math.abs(getVersion(info));
|
||||
if (version == 0) return send.deny();
|
||||
|
||||
const sid = $(data).number('ssnid');
|
||||
|
|
@ -208,7 +368,7 @@ export const save: EPR = async (info, data, send) => {
|
|||
const refid = $(data).str('refid', $(data).attr().refid);
|
||||
if (!refid) return send.deny();
|
||||
|
||||
const version = getVersion(info);
|
||||
const version = Math.abs(getVersion(info));
|
||||
if (version == 0) return send.deny();
|
||||
|
||||
if (version === 1) {
|
||||
|
|
@ -243,38 +403,99 @@ export const save: EPR = async (info, data, send) => {
|
|||
}
|
||||
|
||||
// Save Profile
|
||||
await DB.Update<Profile>(
|
||||
refid,
|
||||
{ collection: 'profile' },
|
||||
{
|
||||
$set: {
|
||||
appeal: $(data).number('appeal_id'),
|
||||
if (version === 6) {
|
||||
await DB.Update<Profile>(
|
||||
refid,
|
||||
{ collection: 'profile' },
|
||||
{
|
||||
$set: {
|
||||
appeal: $(data).number('appeal_id'),
|
||||
|
||||
musicID: $(data).number('music_id'),
|
||||
musicType: $(data).number('music_type'),
|
||||
sortType: $(data).number('sort_type'),
|
||||
headphone: $(data).number('headphone'),
|
||||
blasterCount: $(data).number('blaster_count'),
|
||||
musicID: $(data).number('music_id'),
|
||||
musicType: $(data).number('music_type'),
|
||||
sortType: $(data).number('sort_type'),
|
||||
headphone: $(data).number('headphone'),
|
||||
blasterCount: $(data).number('blaster_count'),
|
||||
|
||||
hiSpeed: $(data).number('hispeed'),
|
||||
laneSpeed: $(data).number('lanespeed'),
|
||||
gaugeOption: $(data).number('gauge_option'),
|
||||
arsOption: $(data).number('ars_option'),
|
||||
notesOption: $(data).number('notes_option'),
|
||||
earlyLateDisp: $(data).number('early_late_disp'),
|
||||
drawAdjust: $(data).number('draw_adjust'),
|
||||
effCLeft: $(data).number('eff_c_left'),
|
||||
effCRight: $(data).number('eff_c_right'),
|
||||
narrowDown: $(data).number('narrow_down'),
|
||||
},
|
||||
$inc: {
|
||||
packets: $(data).number('earned_gamecoin_packet'),
|
||||
blocks: $(data).number('earned_gamecoin_block'),
|
||||
blasterEnergy: $(data).number('earned_blaster_energy'),
|
||||
},
|
||||
}
|
||||
);
|
||||
hiSpeed: $(data).number('hispeed'),
|
||||
laneSpeed: $(data).number('lanespeed'),
|
||||
gaugeOption: $(data).number('gauge_option'),
|
||||
arsOption: $(data).number('ars_option'),
|
||||
notesOption: $(data).number('notes_option'),
|
||||
earlyLateDisp: $(data).number('early_late_disp'),
|
||||
drawAdjust: $(data).number('draw_adjust'),
|
||||
effCLeft: $(data).number('eff_c_left'),
|
||||
effCRight: $(data).number('eff_c_right'),
|
||||
narrowDown: $(data).number('narrow_down'),
|
||||
},
|
||||
$inc: {
|
||||
packets: $(data).number('earned_gamecoin_packet'),
|
||||
blocks: $(data).number('earned_gamecoin_block'),
|
||||
blasterEnergy: $(data).number('earned_blaster_energy'),
|
||||
extrackEnergy: $(data).number('earned_extrack_energy'),
|
||||
},
|
||||
}
|
||||
);
|
||||
}
|
||||
if (version === 5 || version === 4) {
|
||||
await DB.Update<Profile>(
|
||||
refid,
|
||||
{ collection: 'profile' },
|
||||
{
|
||||
$set: {
|
||||
appeal: $(data).number('appeal_id'),
|
||||
|
||||
musicID: $(data).number('music_id'),
|
||||
musicType: $(data).number('music_type'),
|
||||
sortType: $(data).number('sort_type'),
|
||||
headphone: $(data).number('headphone'),
|
||||
blasterCount: $(data).number('blaster_count'),
|
||||
|
||||
hiSpeed: $(data).number('hispeed'),
|
||||
laneSpeed: $(data).number('lanespeed'),
|
||||
gaugeOption: $(data).number('gauge_option'),
|
||||
arsOption: $(data).number('ars_option'),
|
||||
notesOption: $(data).number('notes_option'),
|
||||
earlyLateDisp: $(data).number('early_late_disp'),
|
||||
drawAdjust: $(data).number('draw_adjust'),
|
||||
effCLeft: $(data).number('eff_c_left'),
|
||||
effCRight: $(data).number('eff_c_right'),
|
||||
narrowDown: $(data).number('narrow_down'),
|
||||
},
|
||||
$inc: {
|
||||
packets: $(data).number('earned_gamecoin_packet'),
|
||||
blocks: $(data).number('earned_gamecoin_block'),
|
||||
blasterEnergy: $(data).number('earned_blaster_energy'),
|
||||
},
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
// New course saving function found in sdvx 20220214
|
||||
const course = $(data).element('course');
|
||||
if(!_.isNil(course)){
|
||||
const sid = course.number('ssnid');
|
||||
const cid = course.number('crsid');
|
||||
|
||||
if (!(_.isNil(sid) || _.isNil(cid))){
|
||||
await DB.Upsert<CourseRecord>(
|
||||
refid,
|
||||
{ collection: 'course', sid, cid, version },
|
||||
{
|
||||
$max: {
|
||||
score: course.number('sc', 0),
|
||||
clear: course.number('ct', 0),
|
||||
grade: course.number('gr', 0),
|
||||
rate: course.number('ar', 0),
|
||||
},
|
||||
$inc: {
|
||||
count: 1,
|
||||
},
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// Save Items
|
||||
const items = $(data).elements('item.info');
|
||||
|
||||
|
|
@ -328,10 +549,13 @@ export const save: EPR = async (info, data, send) => {
|
|||
};
|
||||
|
||||
export const load: EPR = async (info, data, send) => {
|
||||
console.log("Loading savedata");
|
||||
const refid = $(data).str('refid', $(data).attr().dataid);
|
||||
if (!refid) return send.deny();
|
||||
|
||||
const version = getVersion(info);
|
||||
const version = Math.abs(getVersion(info));
|
||||
console.log("Got version" + version);
|
||||
console.log("DataID" + refid);
|
||||
if (version == 0) return send.deny();
|
||||
|
||||
const profile = await DB.FindOne<Profile>(refid, {
|
||||
|
|
@ -348,7 +572,7 @@ export const load: EPR = async (info, data, send) => {
|
|||
version,
|
||||
})) || { base: 0, name: 0, level: 0 };
|
||||
|
||||
const courses = await DB.Find<CourseRecord>(refid, { collection: 'course' });
|
||||
const courses = await DB.Find<CourseRecord>(refid, { collection: 'course', version });
|
||||
const items = await DB.Find<Item>(refid, { collection: 'item' });
|
||||
const params = await DB.Find<Param>(refid, { collection: 'param' });
|
||||
let time = new Date();
|
||||
|
|
@ -360,20 +584,70 @@ export const load: EPR = async (info, data, send) => {
|
|||
time.setHours(tempHour);
|
||||
const currentTime = time.getTime();
|
||||
const mixes = version == 5 ? await getAutomationMixes(params) : [];
|
||||
if (!profile.extrackEnergy) {
|
||||
profile.extrackEnergy = 0;
|
||||
}
|
||||
|
||||
if (version === 1) {
|
||||
return send.pugFile('templates/booth/load.pug', { code: IDToCode(profile.id), ...profile });
|
||||
}
|
||||
|
||||
if (version === 2) {
|
||||
let tempItem = U.GetConfig('unlock_all_appeal_cards') ? unlockAppealCards(items) : items
|
||||
tempItem = Array.from(tempItem.values()).filter(r => (r.id <= 220));
|
||||
return send.pugFile('templates/infiniteinfection/load.pug', {
|
||||
courses,
|
||||
tempItem,
|
||||
params,
|
||||
skill,
|
||||
...profile
|
||||
});
|
||||
}
|
||||
const bgm = profile.bgm ? profile.bgm : 0;
|
||||
const subbg = profile.subbg ? profile.subbg : 0;
|
||||
const nemsys = profile.nemsys ? profile.nemsys : 0;
|
||||
const stampA = profile.stampA ? profile.stampA : 0;
|
||||
const stampB = profile.stampB ? profile.stampB : 0;
|
||||
const stampC = profile.stampC ? profile.stampC : 0;
|
||||
const stampD = profile.stampD ? profile.stampD : 0;
|
||||
|
||||
|
||||
const customize = [];
|
||||
customize.push(bgm, subbg, nemsys, stampA, stampB, stampC, stampD);
|
||||
|
||||
|
||||
var tempCustom = params.findIndex((e) => (e.type == 2 && e.id == 2))
|
||||
|
||||
if (tempCustom == -1) {
|
||||
const tempParam: Param = { collection: 'param', type: 2, id: 2, param: [] };
|
||||
params.push(tempParam);
|
||||
tempCustom = params.findIndex((e) => (e.type == 2 && e.id == 2))
|
||||
}
|
||||
|
||||
if (params[tempCustom]) {
|
||||
params[tempCustom].param = customize;
|
||||
}
|
||||
|
||||
|
||||
let blasterpass = U.GetConfig('use_blasterpass') ? 1 : 0;
|
||||
|
||||
var tempItem = U.GetConfig('unlock_all_navigators') ? unlockNavigators(items) : items;
|
||||
tempItem = U.GetConfig('unlock_all_appeal_cards') ? unlockAppealCards(items) : items;
|
||||
|
||||
// Make generator power always 100%,
|
||||
for (let i = 0; i < 50; i++) {
|
||||
const tempGene: Item = { collection: 'item', type: 7, id: i, param: 10 };
|
||||
tempItem.push(tempGene);
|
||||
}
|
||||
return send.pugFile('templates/load.pug', {
|
||||
courses,
|
||||
items: U.GetConfig('unlock_all_navigators')
|
||||
? unlockNavigators(items)
|
||||
: items,
|
||||
items: tempItem,
|
||||
params,
|
||||
skill,
|
||||
currentTime,
|
||||
mixes,
|
||||
version,
|
||||
blasterpass,
|
||||
automation: version == 5 ? SDVX_AUTOMATION_SONGS : [],
|
||||
code: IDToCode(profile.id),
|
||||
...profile,
|
||||
|
|
@ -381,9 +655,10 @@ export const load: EPR = async (info, data, send) => {
|
|||
};
|
||||
|
||||
export const create: EPR = async (info, data, send) => {
|
||||
console.log("Creating profile");
|
||||
const refid = $(data).str('refid', $(data).attr().refid);
|
||||
if (!refid) return send.deny();
|
||||
|
||||
console.log("DataID" + refid);
|
||||
const name = $(data).str('name', $(data).attr().name ? $(data).attr().name : 'GUEST');
|
||||
let id = _.random(0, 99999999);
|
||||
while (await DB.FindOne<Profile>(null, { collecttion: 'profile', id })) {
|
||||
|
|
@ -412,6 +687,15 @@ export const create: EPR = async (info, data, send) => {
|
|||
notesOption: 0,
|
||||
blasterCount: 0,
|
||||
blasterEnergy: 0,
|
||||
extrackEnergy: 0,
|
||||
bgm: 0,
|
||||
subbg: 0,
|
||||
nemsys: 0,
|
||||
stampA: 0,
|
||||
stampB: 0,
|
||||
stampC: 0,
|
||||
stampD: 0,
|
||||
|
||||
headphone: 0,
|
||||
musicID: 0,
|
||||
musicType: 0,
|
||||
|
|
@ -469,3 +753,27 @@ export const buy: EPR = async (info, data, send) => {
|
|||
return send.success();
|
||||
}
|
||||
};
|
||||
|
||||
export const print: EPR = async (info, data, send) => {
|
||||
const genesisCards = $(data).elements('genesis_card');
|
||||
var genesisCardsArray = [];
|
||||
var generatorArray = [];
|
||||
for (const g of genesisCards) {
|
||||
let tempGeneratorID = g.number('generator_id');
|
||||
let exist = generatorArray.findIndex((e) => (e == tempGeneratorID));
|
||||
if (exist == -1) {
|
||||
generatorArray.push(tempGeneratorID);
|
||||
}
|
||||
}
|
||||
send.object({
|
||||
result: K.ITEM('s8', 0),
|
||||
genesis_cards: genesisCards.map(r => ({
|
||||
index: K.ITEM('s32', r.number('index')),
|
||||
print_id: K.ITEM('s32', r.number('print_id'))
|
||||
})),
|
||||
after_power: generatorArray.map(r => ({
|
||||
generator_id: K.ITEM('s32', r),
|
||||
param: K.ITEM('s32', 10),
|
||||
}))
|
||||
}), { status: "0" };
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,12 +1,20 @@
|
|||
import { Profile } from '../models/profile';
|
||||
import { MusicRecord } from '../models/music_record';
|
||||
import { getVersion, IDToCode, GetCounter } from '../utils';
|
||||
import { Mix } from '../models/mix';
|
||||
import { GetCounter } from '../utils';
|
||||
|
||||
export const updateProfile = async (data: {
|
||||
refid: string;
|
||||
name?: string;
|
||||
appeal?: string;
|
||||
akaname?: string;
|
||||
nemsys?: string;
|
||||
bgm?: string;
|
||||
subbg?: string;
|
||||
stampA?: string;
|
||||
stampB?: string;
|
||||
stampC?: string;
|
||||
stampD?: string;
|
||||
}) => {
|
||||
if (data.refid == null) return;
|
||||
|
||||
|
|
@ -30,6 +38,41 @@ export const updateProfile = async (data: {
|
|||
if (!_.isNaN(validAka)) update.akaname = validAka;
|
||||
}
|
||||
|
||||
if (data.nemsys && data.nemsys.length > 0) {
|
||||
const validNemsys = parseInt(data.nemsys);
|
||||
if (!_.isNaN(validNemsys)) update.nemsys = validNemsys;
|
||||
}
|
||||
|
||||
if (data.subbg && data.subbg.length > 0) {
|
||||
const validSubbg = parseInt(data.subbg);
|
||||
if (!_.isNaN(validSubbg)) update.subbg = validSubbg;
|
||||
}
|
||||
|
||||
if (data.bgm && data.bgm.length > 0) {
|
||||
const validBGM = parseInt(data.bgm);
|
||||
if (!_.isNaN(validBGM)) update.bgm = validBGM;
|
||||
}
|
||||
|
||||
if (data.stampA && data.stampA.length > 0) {
|
||||
const validStampA = parseInt(data.stampA);
|
||||
if (!_.isNaN(validStampA)) update.stampA = validStampA;
|
||||
}
|
||||
|
||||
if (data.stampB && data.stampB.length > 0) {
|
||||
const validStampB = parseInt(data.stampB);
|
||||
if (!_.isNaN(validStampB)) update.stampB = validStampB;
|
||||
}
|
||||
|
||||
if (data.stampC && data.stampC.length > 0) {
|
||||
const validStampC = parseInt(data.stampC);
|
||||
if (!_.isNaN(validStampC)) update.stampC = validStampC;
|
||||
}
|
||||
|
||||
if (data.stampD && data.stampD.length > 0) {
|
||||
const validStampD = parseInt(data.stampD);
|
||||
if (!_.isNaN(validStampD)) update.stampD = validStampD;
|
||||
}
|
||||
|
||||
await DB.Update<Profile>(
|
||||
data.refid,
|
||||
{ collection: 'profile' },
|
||||
|
|
@ -98,15 +141,11 @@ export const importMix = async (data: { json: string }) => {
|
|||
id,
|
||||
name: mix[1],
|
||||
creator: mix[2],
|
||||
param: `{ "dbVer" : "${
|
||||
mix[3]
|
||||
}", "gene" : { "params" : "{ \\"minorVer\\" : \\"${
|
||||
mix[4]
|
||||
}\\", \\"seed\\" : ${mix[5]} }", "ver" : "${
|
||||
mix[6]
|
||||
}" }, "musics" : ${JSON.stringify(mdata)}, "voxdj" : { "params" : "${
|
||||
mix[7]
|
||||
}", "ver" : "${mix[8]}" } }`,
|
||||
param: `{ "dbVer" : "${mix[3]
|
||||
}", "gene" : { "params" : "{ \\"minorVer\\" : \\"${mix[4]
|
||||
}\\", \\"seed\\" : ${mix[5]} }", "ver" : "${mix[6]
|
||||
}" }, "musics" : ${JSON.stringify(mdata)}, "voxdj" : { "params" : "${mix[7]
|
||||
}", "ver" : "${mix[8]}" } }`,
|
||||
jacket: 0,
|
||||
tag: 1,
|
||||
});
|
||||
|
|
@ -115,3 +154,5 @@ export const importMix = async (data: { json: string }) => {
|
|||
export const deleteMix = async (data: { code: string }) => {
|
||||
await DB.Remove<Mix>({ collection: 'mix', code: data.code });
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import {common} from './handlers/common';
|
||||
import {hiscore, rival, saveMix, loadMix} from './handlers/features';
|
||||
import {common,log} from './handlers/common';
|
||||
import {hiscore, rival, saveMix, loadMix, globalMatch} from './handlers/features';
|
||||
import {
|
||||
updateProfile,
|
||||
updateMix,
|
||||
|
|
@ -14,13 +14,22 @@ import {
|
|||
saveScore,
|
||||
saveCourse,
|
||||
buy,
|
||||
print,
|
||||
} from './handlers/profiles';
|
||||
|
||||
export function register() {
|
||||
|
||||
R.Contributor("LatoWolf#1170");
|
||||
R.GameCode('KFC');
|
||||
|
||||
R.Config('unlock_all_songs', { type: 'boolean', default: false });
|
||||
R.Config('unlock_all_navigators', { type: 'boolean', default: false });
|
||||
R.Config('unlock_all_songs', { type: 'boolean', default: false, name:'Unlock All Songs'});
|
||||
R.Config('unlock_all_navigators', { type: 'boolean', default: false, name:'Unlock All Navigators'} );
|
||||
R.Config('unlock_all_appeal_cards', { type: 'boolean', default: false, name:'Unlock All Appeal Cards'});
|
||||
R.Config('use_information' ,{ type: 'boolean', default: true, name:'Use Information', desc:'Enable the information section after entry.'});
|
||||
R.Config('use_asphyxia_gameover',{ type: 'boolean', default: true, name:'Use Asphyxia Gameover', desc:'Enable the Asphyxia gameover message after ending the game.'})
|
||||
R.Config('use_blasterpass',{ type: 'boolean', default: true, name:'Use Blaster Pass', desc:'Enable Blaster Pass for VW and EG'});
|
||||
|
||||
R.Config('other_instance_ip',{type:'string', default:'', name:'Other Instance IP', desc:'The IP of another instance of the server. This is used to get Hiscore if you\'re running multiple instances.Seperate IPs with commas.'});
|
||||
|
||||
R.WebUIEvent('updateProfile', updateProfile);
|
||||
R.WebUIEvent('updateMix', updateMix);
|
||||
|
|
@ -30,8 +39,11 @@ export function register() {
|
|||
const MultiRoute = (method: string, handler: EPR | boolean) => {
|
||||
// Helper for register multiple versions.
|
||||
R.Route(`game.${method}`, handler);
|
||||
R.Route(`game_2.${method}`, handler);
|
||||
//R.Route(`game_3.${method}`, handler);
|
||||
R.Route(`game.sv4_${method}`, handler);
|
||||
R.Route(`game.sv5_${method}`, handler);
|
||||
R.Route(`game.sv6_${method}`, handler);
|
||||
};
|
||||
|
||||
// Common
|
||||
|
|
@ -46,6 +58,7 @@ export function register() {
|
|||
MultiRoute('save_c', saveCourse);
|
||||
MultiRoute('frozen', true);
|
||||
MultiRoute('buy', buy);
|
||||
MultiRoute('print',print);
|
||||
|
||||
// Features
|
||||
MultiRoute('hiscore', hiscore);
|
||||
|
|
@ -61,17 +74,32 @@ export function register() {
|
|||
nxt_time: K.ITEM('u32', 1000 * 5 * 60)
|
||||
}));
|
||||
MultiRoute('save_e', true);
|
||||
MultiRoute('save_mega',true);
|
||||
MultiRoute('play_e', true);
|
||||
MultiRoute('play_s', true);
|
||||
MultiRoute('entry_s', true);
|
||||
MultiRoute('entry_s', globalMatch);
|
||||
MultiRoute('entry_e', true);
|
||||
MultiRoute('exception', true);
|
||||
MultiRoute('log',log);
|
||||
|
||||
R.Route('eventlog.write', (_, __, send) => send.object({
|
||||
gamesession: K.ITEM('s64', BigInt(1)),
|
||||
logsendflg: K.ITEM('s32', 0),
|
||||
logerrlevel: K.ITEM('s32', 0),
|
||||
evtidnosendflg: K.ITEM('s32', 0)
|
||||
}));
|
||||
|
||||
R.Route('package.list',(_,__,send)=>send.object({
|
||||
package:K.ATTR({expire:"1200"},{status:"1"})
|
||||
}));
|
||||
|
||||
R.Route('ins.netlog', (_, __, send) => send.object({
|
||||
//gamesession: K.ITEM('s64', BigInt(1)),
|
||||
//logsendflg: K.ITEM('s32', 0),
|
||||
//logerrlevel: K.ITEM('s32', 0),
|
||||
//evtidnosendflg: K.ITEM('s32', 0)
|
||||
}));
|
||||
|
||||
|
||||
R.Unhandled();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ export interface MusicRecord {
|
|||
mid: number;
|
||||
type: number;
|
||||
score: number;
|
||||
exscore: number;
|
||||
clear: number;
|
||||
grade: number;
|
||||
buttonRate: number;
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ export interface Profile {
|
|||
headphone: number;
|
||||
blasterEnergy: number;
|
||||
blasterCount: number;
|
||||
extrackEnergy: number;
|
||||
|
||||
hiSpeed: number;
|
||||
laneSpeed: number;
|
||||
|
|
@ -31,6 +32,15 @@ export interface Profile {
|
|||
effCLeft: number;
|
||||
effCRight: number;
|
||||
narrowDown: number;
|
||||
|
||||
bgm: number;
|
||||
subbg: number;
|
||||
nemsys: number;
|
||||
|
||||
stampA: number;
|
||||
stampB: number;
|
||||
stampC: number;
|
||||
stampD: number;
|
||||
|
||||
boothFrame: number[];
|
||||
}
|
||||
|
|
|
|||
38
sdvx@asphyxia/templates/infiniteinfection/common.pug
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
- let music = 0;
|
||||
- let event = 0;
|
||||
- let catalog = 0;
|
||||
|
||||
|
||||
game
|
||||
music_limited
|
||||
while music < 23
|
||||
each type in [0,1,2,3]
|
||||
info
|
||||
music_id(__type="s32") #{music++}
|
||||
music_type(__type="u8") #{type}
|
||||
limited(__type="u8") 3
|
||||
|
||||
event
|
||||
while event < 41
|
||||
info
|
||||
event_id(__type="u32") #{event++}
|
||||
|
||||
skill_course
|
||||
each course in courses
|
||||
info
|
||||
course_id(__type="s16") #{course.id}
|
||||
level(__type="s16") #{course.level}
|
||||
season_id(__type="s16") #{course.season_id}
|
||||
season_name(__type="str") #{course.season_name}
|
||||
season_new_flg(__type="bool") #{course.new_flg}
|
||||
course_name(_type="str") #{course.name}
|
||||
course_type(__type="s16") #{course.type}
|
||||
skill_name_id(__type="s16") #{course.name_id}
|
||||
matching_assist(__type="bool") #{course.matching_assist}
|
||||
guage_type(__type="s16") #{course.guage_type}
|
||||
paseli_type(type="s16") #{course.paseli_type}
|
||||
each trackinfo in course.tracks
|
||||
track
|
||||
track_no(__type="s16") #{trackinfo.no}
|
||||
music_id(__type="s32") #{trackinfo.id}
|
||||
music_type(__type="s8") #{trackinfo.type}
|
||||
105
sdvx@asphyxia/templates/infiniteinfection/load.pug
Normal file
|
|
@ -0,0 +1,105 @@
|
|||
game
|
||||
result(__type="u8") 0
|
||||
name(__type="str") #{name}
|
||||
code(__type="str") #{code}
|
||||
sdvx_id(__type="str") #{code}
|
||||
gamecoin_packet(__type="u32") #{packets}
|
||||
gamecoin_block(__type="u32") #{blocks}
|
||||
|
||||
|
||||
last
|
||||
music_id(__type="s32") #{musicID}
|
||||
music_type(__type="u8") #{musicType}
|
||||
sort_type(__type="u8") #{sortType}
|
||||
comment_id(__type="u16") 0
|
||||
appeal_id(__type="u16") #{appeal}
|
||||
headphone(__type="u8") #{headphone}
|
||||
narrow_down(__type="u8") #{narrowDown}
|
||||
gauge_option(__type="u8") #{gaugeOption}
|
||||
blaster_energy(__type="u32") #{blasterEnergy}
|
||||
blaster_count(__type="u32") #{blasterCount}
|
||||
extrack_energy(__type="u16") #{extrackEnergy}
|
||||
|
||||
hispeed(__type="s32") #{hiSpeed}
|
||||
lanespeed(__type="u32") #{laneSpeed}
|
||||
|
||||
ars_option(__type="u8") #{arsOption}
|
||||
notes_option(__type="u8") #{notesOption}
|
||||
early_late_disp(__type="u8") #{earlyLateDisp}
|
||||
draw_adjust(__type="s32") #{drawAdjust}
|
||||
eff_c_left(__type="u8") #{effCLeft}
|
||||
eff_c_right(__type="u8") #{effCRight}
|
||||
|
||||
|
||||
kac_id(__type="str") #{name}
|
||||
|
||||
skill_level(__type="s16") #{skill.level}
|
||||
skill_base_id(__type="s16") #{skill.base}
|
||||
skill_name_id(__type="s16") #{skill.name}
|
||||
|
||||
ea_shop
|
||||
packet_booster(__type="s32") 1
|
||||
if version < 5
|
||||
block_booster(__type="s32") 1
|
||||
if version >= 5
|
||||
blaster_pass_enable(__type="bool") 1
|
||||
blaster_pass_limit_date(__type="u64") #{currentTime}
|
||||
|
||||
eaappli
|
||||
relation(__type="s8") 1
|
||||
cloud
|
||||
relation(__type="s8") 1
|
||||
block_no(__type="s32") 0
|
||||
|
||||
skill
|
||||
course
|
||||
each course in courses
|
||||
d
|
||||
ssnid(__type="s16") #{course.sid}
|
||||
crsid(__type="s16") #{course.cid}
|
||||
sc(__type="s32") #{course.score}
|
||||
ex(__type="s32") 0
|
||||
ct(__type="s16") #{course.clear}
|
||||
gr(__type="s16") #{course.grade}
|
||||
ar(__type="s16") #{course.rate}
|
||||
cnt(__type="s16") #{course.count}
|
||||
course_total
|
||||
each course in courses
|
||||
d
|
||||
ssnid(__type="s16") #{course.sid}
|
||||
crsid(__type="s16") #{course.cid}
|
||||
sc(__type="s32") #{course.score}
|
||||
ex(__type="s32") 0
|
||||
ct(__type="s16") #{course.clear}
|
||||
gr(__type="s16") #{course.grade}
|
||||
ar(__type="s16") #{course.rate}
|
||||
cnt(__type="s16") #{course.count}
|
||||
course_all
|
||||
each course in courses
|
||||
d
|
||||
ssnid(__type="s16") #{course.sid}
|
||||
crsid(__type="s16") #{course.cid}
|
||||
sc(__type="s32") #{course.score}
|
||||
ex(__type="s32") 0
|
||||
ct(__type="s16") #{course.clear}
|
||||
gr(__type="s16") #{course.grade}
|
||||
ar(__type="s16") #{course.rate}
|
||||
cnt(__type="s16") #{course.count}
|
||||
|
||||
item
|
||||
each item in tempItem
|
||||
info
|
||||
type(__type="u8") #{item.type}
|
||||
id(__type="u32") #{item.id}
|
||||
param(__type="u32") #{item.param}
|
||||
|
||||
|
||||
play_count(__type="u32") 1001
|
||||
day_count(__type="u32") 301
|
||||
today_count(__type="u32") 21
|
||||
play_chain(__type="u32") 31
|
||||
max_play_chain(__type="u32") 31
|
||||
week_count(__type="u32") 9
|
||||
week_play_count(__type="u32") 101
|
||||
week_chain(__type="u32") 31
|
||||
max_week_chain(__type="u32") 31
|
||||
14
sdvx@asphyxia/templates/infiniteinfection/score.pug
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
game
|
||||
new
|
||||
each music in temp
|
||||
music
|
||||
music_id (__type="u32")#{music.mid}
|
||||
music_type (__type="u32")#{music.type}
|
||||
score (__type="u32")#{music.score}
|
||||
cnt (__type="u32")1
|
||||
clear_type (__type="u32")#{music.clear}
|
||||
score_grade (__type="u32")#{music.grade}
|
||||
btn_rate (__type="u32")#{music.buttonRate}
|
||||
long_rate (__type="u32")#{music.longRate}
|
||||
vol_rate (__type="u32")#{music.volRate}
|
||||
old
|
||||
|
|
@ -12,7 +12,8 @@ game
|
|||
sort_type(__type="u8") #{sortType}
|
||||
headphone(__type="u8") #{headphone}
|
||||
blaster_energy(__type="u32") #{blasterEnergy}
|
||||
blaster_count(__type="u32") #{blasterCount}
|
||||
blaster_count(__type="u32") 0
|
||||
extrack_energy(__type="u16") #{extrackEnergy}
|
||||
|
||||
hispeed(__type="s32") #{hiSpeed}
|
||||
lanespeed(__type="u32") #{laneSpeed}
|
||||
|
|
@ -33,10 +34,11 @@ game
|
|||
|
||||
ea_shop
|
||||
packet_booster(__type="s32") 1
|
||||
if version != 5
|
||||
if version < 5
|
||||
block_booster(__type="s32") 1
|
||||
blaster_pass_enable(__type="bool") 1
|
||||
blaster_pass_limit_date(__type="u64") #{currentTime}
|
||||
if version >= 5
|
||||
blaster_pass_enable(__type="bool") #{blasterpass}
|
||||
blaster_pass_limit_date(__type="u64") #{currentTime}
|
||||
|
||||
eaappli
|
||||
relation(__type="s8") 1
|
||||
|
|
@ -50,6 +52,7 @@ game
|
|||
ssnid(__type="s16") #{course.sid}
|
||||
crsid(__type="s16") #{course.cid}
|
||||
sc(__type="s32") #{course.score}
|
||||
ex(__type="s32") 0
|
||||
ct(__type="s16") #{course.clear}
|
||||
gr(__type="s16") #{course.grade}
|
||||
ar(__type="s16") #{course.rate}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,17 @@ export async function GetCounter(key: string) {
|
|||
export function getVersion(info: EamuseInfo) {
|
||||
const dateCode = parseInt(info.model.split(":")[4]);
|
||||
if (dateCode <= 2013052900) return 1;
|
||||
if (dateCode <= 2014112000) return 2;
|
||||
if (dateCode <= 2016121200) return 3;
|
||||
if (info.method.startsWith('sv4')) return 4;
|
||||
if (info.method.startsWith('sv5')) return 5;
|
||||
if (dateCode >= 2021083100) return -6;
|
||||
if (info.method.startsWith('sv6')) return 6;
|
||||
return 0;
|
||||
}
|
||||
|
||||
export function getRandomIntInclusive(min, max) {
|
||||
min = Math.ceil(min);
|
||||
max = Math.floor(max);
|
||||
return Math.floor(Math.random() * (max - min + 1) + min); //The maximum is inclusive and the minimum is inclusive
|
||||
}
|
||||
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0001.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0002.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0003.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0004.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0005.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0006.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0007.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0008.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0009.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0010.jpg
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0011.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0012.jpg
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0013.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0014.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0015.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0016.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0017.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0018.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0019.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0020.jpg
Normal file
|
After Width: | Height: | Size: 9.4 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0021.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0022.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0023.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0024.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0025.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0026.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0027.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0028.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0029.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0030.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0031.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0032.jpg
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0033.jpg
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0034.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0035.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0036.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0037.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0038.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0039.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0040.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0041.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0042.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0043.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0044.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0045.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0046.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0047.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0048.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0049.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0050.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0051.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0052.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0053.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0054.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0055.jpg
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0056.jpg
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0057.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0058.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0059.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0060.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0061.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0062.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0063.jpg
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0064.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0065.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0066.jpg
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0067.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0068.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0069.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0070.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0071.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0072.jpg
Normal file
|
After Width: | Height: | Size: 9.4 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0073.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0074.jpg
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0075.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0076.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0077.jpg
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0078.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0079.jpg
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0080.jpg
Normal file
|
After Width: | Height: | Size: 8.1 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0081.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0082.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0083.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
sdvx@asphyxia/webui/asset/ap_card/ap_0084.jpg
Normal file
|
After Width: | Height: | Size: 15 KiB |