danoniplus 28.6.0 → 29.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/js/danoni_main.js +33 -31
- package/js/lib/danoni_constants.js +4 -2
- package/package.json +1 -1
package/js/danoni_main.js
CHANGED
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
*
|
|
5
5
|
* Source by tickle
|
|
6
6
|
* Created : 2018/10/08
|
|
7
|
-
* Revised : 2022/
|
|
7
|
+
* Revised : 2022/11/05
|
|
8
8
|
*
|
|
9
9
|
* https://github.com/cwtickle/danoniplus
|
|
10
10
|
*/
|
|
11
|
-
const g_version = `Ver
|
|
12
|
-
const g_revisedDate = `2022/
|
|
11
|
+
const g_version = `Ver 29.0.1`;
|
|
12
|
+
const g_revisedDate = `2022/11/05`;
|
|
13
13
|
const g_alphaVersion = ``;
|
|
14
14
|
|
|
15
15
|
// カスタム用バージョン (danoni_custom.js 等で指定可)
|
|
@@ -1809,7 +1809,7 @@ const initialControl = async () => {
|
|
|
1809
1809
|
});
|
|
1810
1810
|
|
|
1811
1811
|
// デフォルトのカラー・シャッフルグループ設定を退避
|
|
1812
|
-
|
|
1812
|
+
g_keycons.groups.forEach(type => {
|
|
1813
1813
|
const tmpName = Object.keys(g_keyObj).filter(val => val.startsWith(type));
|
|
1814
1814
|
tmpName.forEach(property => g_keyObj[`${property}d`] = structuredClone(g_keyObj[property]));
|
|
1815
1815
|
});
|
|
@@ -2766,7 +2766,7 @@ const headerConvert = _dosObj => {
|
|
|
2766
2766
|
}
|
|
2767
2767
|
|
|
2768
2768
|
// ハッシュタグ
|
|
2769
|
-
obj.hashTag =
|
|
2769
|
+
obj.hashTag = _dosObj.hashTag ?? ``;
|
|
2770
2770
|
|
|
2771
2771
|
// 自動プリロードの設定
|
|
2772
2772
|
obj.autoPreload = setBoolVal(_dosObj.autoPreload, true);
|
|
@@ -3317,15 +3317,8 @@ const getGaugeSetting = (_dosObj, _name, _difLength, { scoreId = 0 } = {}) => {
|
|
|
3317
3317
|
gaugeCreateFlg = setGaugeDetails(scoreId, _dosObj[`gauge${_name}`].split(`,`));
|
|
3318
3318
|
} else {
|
|
3319
3319
|
const gauges = splitLF2(_dosObj[`gauge${_name}`]);
|
|
3320
|
-
|
|
3321
|
-
|
|
3322
|
-
gaugeCreateFlg = setGaugeDetails(j, getGaugeDetailList(j, gauges[j].split(`,`)));
|
|
3323
|
-
}
|
|
3324
|
-
if (gHeaderLen < _difLength) {
|
|
3325
|
-
const defaultGaugeList = gauges[0].split(`,`);
|
|
3326
|
-
for (let j = gHeaderLen; j < _difLength; j++) {
|
|
3327
|
-
gaugeCreateFlg = setGaugeDetails(j, getGaugeDetailList(j, defaultGaugeList));
|
|
3328
|
-
}
|
|
3320
|
+
for (let j = 0; j < _difLength; j++) {
|
|
3321
|
+
gaugeCreateFlg = setGaugeDetails(j, getGaugeDetailList(j, (gauges[j] ?? gauges[0]).split(`,`)));
|
|
3329
3322
|
}
|
|
3330
3323
|
}
|
|
3331
3324
|
|
|
@@ -3774,7 +3767,7 @@ const titleInit = _ => {
|
|
|
3774
3767
|
*/
|
|
3775
3768
|
const createCreditBtn = (_id, _text, _url) =>
|
|
3776
3769
|
createCss2Button(_id, _text, _ => true,
|
|
3777
|
-
Object.assign(g_lblPosObj[_id], { siz: getLinkSiz(_text), resetFunc: _ => openLink(_url) }), g_cssObj.button_Default);
|
|
3770
|
+
Object.assign(g_lblPosObj[_id], { siz: getLinkSiz(_text), whiteSpace: `normal`, resetFunc: _ => openLink(_url) }), g_cssObj.button_Default);
|
|
3778
3771
|
|
|
3779
3772
|
// ボタン描画
|
|
3780
3773
|
multiAppend(divRoot,
|
|
@@ -5018,7 +5011,7 @@ const createOptionWindow = _sprite => {
|
|
|
5018
5011
|
const keyCtrlPtn = `${g_keyObj.currentKey}_${g_keyObj.currentPtn}`;
|
|
5019
5012
|
|
|
5020
5013
|
// カラーグループ、シャッフルグループの設定
|
|
5021
|
-
|
|
5014
|
+
g_keycons.groups.forEach(type => {
|
|
5022
5015
|
resetGroupList(type, keyCtrlPtn);
|
|
5023
5016
|
if (g_keyObj.currentPtn === -1) {
|
|
5024
5017
|
const storageKeyName = storageObj[`${type}${addKey}`] || storageObj[`${type}${g_keyObj.currentKey}_-1_-1`];
|
|
@@ -5315,7 +5308,7 @@ const getKeyCtrl = (_localStorage, _extraKeyName = ``) => {
|
|
|
5315
5308
|
g_keyObj[`${header}${copyPtn}`] = g_keyObj[`${header}${basePtn}`];
|
|
5316
5309
|
});
|
|
5317
5310
|
|
|
5318
|
-
|
|
5311
|
+
g_keycons.groups.forEach(type => {
|
|
5319
5312
|
let maxPtn = 0;
|
|
5320
5313
|
while (g_keyObj[`${type}${basePtn}_${maxPtn}`] !== undefined) {
|
|
5321
5314
|
maxPtn++;
|
|
@@ -6166,7 +6159,7 @@ const keyConfigInit = (_kcType = g_kcType) => {
|
|
|
6166
6159
|
g_keyObj.currentPtn = searchPattern(g_keyObj.currentPtn, _sign, g_headerObj.transKeyUse);
|
|
6167
6160
|
|
|
6168
6161
|
// カラーグループ、シャッフルグループの再設定
|
|
6169
|
-
|
|
6162
|
+
g_keycons.groups.forEach(type => resetGroupList(type, `${g_keyObj.currentKey}_${g_keyObj.currentPtn}`));
|
|
6170
6163
|
|
|
6171
6164
|
// キーコンフィグ画面を再呼び出し
|
|
6172
6165
|
keyConfigInit();
|
|
@@ -8044,7 +8037,7 @@ const getArrowSettings = _ => {
|
|
|
8044
8037
|
resetColorType({ _to: g_keycons.colorSelf });
|
|
8045
8038
|
}
|
|
8046
8039
|
|
|
8047
|
-
|
|
8040
|
+
g_keycons.groups.forEach(type => {
|
|
8048
8041
|
const groupNum = g_keycons[`${type}GroupNum`];
|
|
8049
8042
|
storageObj[`${type}${addKey}`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}`]);
|
|
8050
8043
|
g_keyObj[`${type}${g_keyObj.currentKey}_-1_${groupNum}`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}d`]);
|
|
@@ -9536,7 +9529,7 @@ const judgeArrow = _j => {
|
|
|
9536
9529
|
if (_difCnt <= g_judgObj.arrowJ[g_judgPosObj.uwan]) {
|
|
9537
9530
|
const [resultFunc, resultJdg] = checkJudgment(_difCnt);
|
|
9538
9531
|
resultFunc(_difFrame);
|
|
9539
|
-
countFastSlow(_difFrame
|
|
9532
|
+
countFastSlow(_difFrame);
|
|
9540
9533
|
|
|
9541
9534
|
const stepDivHit = document.querySelector(`#stepHit${_j}`);
|
|
9542
9535
|
stepDivHit.style.top = `${g_attrObj[arrowName].prevY - parseFloat($id(`stepRoot${_j}`).top) - 15}px`;
|
|
@@ -9554,15 +9547,23 @@ const judgeArrow = _j => {
|
|
|
9554
9547
|
|
|
9555
9548
|
const judgeTargetFrzArrow = _difFrame => {
|
|
9556
9549
|
const _difCnt = Math.abs(_difFrame);
|
|
9557
|
-
if (_difCnt <= g_judgObj.frzJ[g_judgPosObj.
|
|
9558
|
-
|
|
9559
|
-
|
|
9550
|
+
if (_difCnt <= g_judgObj.frzJ[g_judgPosObj.iknai] && !g_attrObj[frzName].judgEndFlg
|
|
9551
|
+
&& g_workObj.judgFrzHitCnt[_j] <= fcurrentNo) {
|
|
9552
|
+
|
|
9553
|
+
if (g_headerObj.frzStartjdgUse) {
|
|
9560
9554
|
const [resultFunc] = checkJudgment(_difCnt);
|
|
9561
9555
|
resultFunc(_difFrame);
|
|
9562
|
-
|
|
9563
|
-
|
|
9556
|
+
} else {
|
|
9557
|
+
displayDiff(_difFrame, `F`);
|
|
9558
|
+
}
|
|
9559
|
+
countFastSlow(_difFrame);
|
|
9560
|
+
|
|
9561
|
+
if (_difCnt <= g_judgObj.frzJ[g_judgPosObj.sfsf]) {
|
|
9562
|
+
changeHitFrz(_j, fcurrentNo, `frz`);
|
|
9563
|
+
} else {
|
|
9564
|
+
changeFailedFrz(_j, fcurrentNo);
|
|
9564
9565
|
}
|
|
9565
|
-
|
|
9566
|
+
g_workObj.judgFrzHitCnt[_j] = fcurrentNo + 1;
|
|
9566
9567
|
return true;
|
|
9567
9568
|
}
|
|
9568
9569
|
return false;
|
|
@@ -9584,9 +9585,10 @@ const judgeArrow = _j => {
|
|
|
9584
9585
|
/**
|
|
9585
9586
|
* タイミングズレを表示
|
|
9586
9587
|
* @param {number} _difFrame
|
|
9588
|
+
* @param {string} _fjdg
|
|
9587
9589
|
* @param {number} _justFrames
|
|
9588
9590
|
*/
|
|
9589
|
-
const displayDiff = (_difFrame, _justFrames =
|
|
9591
|
+
const displayDiff = (_difFrame, _fjdg = ``, _justFrames = g_headerObj.justFrames) => {
|
|
9590
9592
|
let diffJDisp = ``;
|
|
9591
9593
|
g_workObj.diffList.push(_difFrame);
|
|
9592
9594
|
const difCnt = Math.abs(_difFrame);
|
|
@@ -9595,7 +9597,7 @@ const displayDiff = (_difFrame, _justFrames = 0) => {
|
|
|
9595
9597
|
} else if (_difFrame < _justFrames * (-1)) {
|
|
9596
9598
|
diffJDisp = `<span class="common_shobon">Slow ${difCnt} Frames</span>`;
|
|
9597
9599
|
}
|
|
9598
|
-
|
|
9600
|
+
document.getElementById(`diff${_fjdg}J`).innerHTML = diffJDisp;
|
|
9599
9601
|
};
|
|
9600
9602
|
|
|
9601
9603
|
/**
|
|
@@ -9603,7 +9605,7 @@ const displayDiff = (_difFrame, _justFrames = 0) => {
|
|
|
9603
9605
|
* @param {number} _difFrame
|
|
9604
9606
|
* @param {number} _justFrames
|
|
9605
9607
|
*/
|
|
9606
|
-
const countFastSlow = (_difFrame, _justFrames =
|
|
9608
|
+
const countFastSlow = (_difFrame, _justFrames = g_headerObj.justFrames) => {
|
|
9607
9609
|
if (_difFrame > _justFrames) {
|
|
9608
9610
|
g_resultObj.fast++;
|
|
9609
9611
|
} else if (_difFrame < _justFrames * (-1)) {
|
|
@@ -9688,7 +9690,7 @@ const judgeRecovery = (_name, _difFrame) => {
|
|
|
9688
9690
|
changeJudgeCharacter(_name, g_lblNameObj[`j_${_name}`]);
|
|
9689
9691
|
|
|
9690
9692
|
updateCombo();
|
|
9691
|
-
displayDiff(_difFrame
|
|
9693
|
+
displayDiff(_difFrame);
|
|
9692
9694
|
|
|
9693
9695
|
lifeRecovery();
|
|
9694
9696
|
finishViewing();
|
|
@@ -9730,7 +9732,7 @@ const judgeMatari = _difFrame => {
|
|
|
9730
9732
|
changeJudgeCharacter(`matari`, g_lblNameObj.j_matari);
|
|
9731
9733
|
comboJ.textContent = ``;
|
|
9732
9734
|
|
|
9733
|
-
displayDiff(_difFrame
|
|
9735
|
+
displayDiff(_difFrame);
|
|
9734
9736
|
finishViewing();
|
|
9735
9737
|
|
|
9736
9738
|
g_customJsObj.judg_matari.forEach(func => func(_difFrame));
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*
|
|
6
6
|
* Source by tickle
|
|
7
7
|
* Created : 2019/11/19
|
|
8
|
-
* Revised : 2022/
|
|
8
|
+
* Revised : 2022/11/05 (v29.0.1)
|
|
9
9
|
*
|
|
10
10
|
* https://github.com/cwtickle/danoniplus
|
|
11
11
|
*/
|
|
@@ -845,6 +845,8 @@ const g_keycons = {
|
|
|
845
845
|
shuffleGroups: [0],
|
|
846
846
|
shuffleGroupNum: 0,
|
|
847
847
|
groupSelf: `S`,
|
|
848
|
+
|
|
849
|
+
groups: [`color`, `shuffle`],
|
|
848
850
|
};
|
|
849
851
|
|
|
850
852
|
let g_displays = [`stepZone`, `judgment`, `fastSlow`, `lifeGauge`, `score`, `musicInfo`, `filterLine`,
|
|
@@ -2566,7 +2568,7 @@ const g_keyObj = {
|
|
|
2566
2568
|
const keyCtrlName = Object.keys(g_keyObj).filter(val => val.startsWith(`keyCtrl`));
|
|
2567
2569
|
keyCtrlName.forEach(property => g_keyObj[`${property}d`] = copyArray2d(g_keyObj[property]));
|
|
2568
2570
|
|
|
2569
|
-
|
|
2571
|
+
g_keycons.groups.forEach(type => {
|
|
2570
2572
|
const tmpName = Object.keys(g_keyObj).filter(val => val.startsWith(type) && val.endsWith(`_0`));
|
|
2571
2573
|
tmpName.forEach(property => g_keyObj[`${property.slice(0, -2)}`] = g_keyObj[property].concat());
|
|
2572
2574
|
});
|