danoniplus 29.1.0 → 29.2.0

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.
Files changed (2) hide show
  1. package/js/danoni_main.js +11 -26
  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/11/05
7
+ * Revised : 2022/11/09
8
8
  *
9
9
  * https://github.com/cwtickle/danoniplus
10
10
  */
11
- const g_version = `Ver 29.1.0`;
12
- const g_revisedDate = `2022/11/05`;
11
+ const g_version = `Ver 29.2.0`;
12
+ const g_revisedDate = `2022/11/09`;
13
13
  const g_alphaVersion = ``;
14
14
 
15
15
  // カスタム用バージョン (danoni_custom.js 等で指定可)
@@ -2543,12 +2543,13 @@ const headerConvert = _dosObj => {
2543
2543
  obj.frzAttempt = setIntVal(_dosObj.frzAttempt, C_FRM_FRZATTEMPT);
2544
2544
 
2545
2545
  // 製作者表示
2546
- if (hasVal(_dosObj.tuning)) {
2547
- const tunings = _dosObj.tuning.split(`,`);
2546
+ const dosTuning = _dosObj[`tuning${g_localeObj.val}`] ?? _dosObj.tuning;
2547
+ if (hasVal(dosTuning)) {
2548
+ const tunings = dosTuning.split(`,`);
2548
2549
  obj.tuning = escapeHtmlForEnabledTag(tunings[0]);
2549
2550
  obj.creatorUrl = (tunings.length > 1 ? tunings[1] : (g_presetObj.tuningUrl ?? ``));
2550
2551
  } else {
2551
- obj.tuning = escapeHtmlForEnabledTag(g_presetObj.tuning ?? `name`);
2552
+ obj.tuning = escapeHtmlForEnabledTag(g_presetObj[`tuning${g_localeObj.val}`] ?? g_presetObj.tuning ?? `name`);
2552
2553
  obj.creatorUrl = g_presetObj.tuningUrl ?? ``;
2553
2554
  }
2554
2555
  obj.tuningInit = obj.tuning;
@@ -9532,7 +9533,7 @@ const judgeArrow = _j => {
9532
9533
  if (_difCnt <= g_judgObj.arrowJ[g_judgPosObj.uwan]) {
9533
9534
  const [resultFunc, resultJdg] = checkJudgment(_difCnt);
9534
9535
  resultFunc(_difFrame);
9535
- countFastSlow(_difFrame);
9536
+ displayDiff(_difFrame);
9536
9537
 
9537
9538
  const stepDivHit = document.querySelector(`#stepHit${_j}`);
9538
9539
  stepDivHit.style.top = `${g_attrObj[arrowName].prevY - parseFloat($id(`stepRoot${_j}`).top) - 15}px`;
@@ -9556,10 +9557,10 @@ const judgeArrow = _j => {
9556
9557
  if (g_headerObj.frzStartjdgUse) {
9557
9558
  const [resultFunc] = checkJudgment(_difCnt);
9558
9559
  resultFunc(_difFrame);
9560
+ displayDiff(_difFrame);
9559
9561
  } else {
9560
9562
  displayDiff(_difFrame, `F`);
9561
9563
  }
9562
- countFastSlow(_difFrame);
9563
9564
 
9564
9565
  if (_difCnt <= g_judgObj.frzJ[g_judgPosObj.sfsf]) {
9565
9566
  changeHitFrz(_j, fcurrentNo, `frz`);
@@ -9597,23 +9598,12 @@ const displayDiff = (_difFrame, _fjdg = ``, _justFrames = g_headerObj.justFrames
9597
9598
  const difCnt = Math.abs(_difFrame);
9598
9599
  if (_difFrame > _justFrames) {
9599
9600
  diffJDisp = `<span class="common_matari">Fast ${difCnt} Frames</span>`;
9600
- } else if (_difFrame < _justFrames * (-1)) {
9601
- diffJDisp = `<span class="common_shobon">Slow ${difCnt} Frames</span>`;
9602
- }
9603
- document.getElementById(`diff${_fjdg}J`).innerHTML = diffJDisp;
9604
- };
9605
-
9606
- /**
9607
- * Fast/Slowカウンタ
9608
- * @param {number} _difFrame
9609
- * @param {number} _justFrames
9610
- */
9611
- const countFastSlow = (_difFrame, _justFrames = g_headerObj.justFrames) => {
9612
- if (_difFrame > _justFrames) {
9613
9601
  g_resultObj.fast++;
9614
9602
  } else if (_difFrame < _justFrames * (-1)) {
9603
+ diffJDisp = `<span class="common_shobon">Slow ${difCnt} Frames</span>`;
9615
9604
  g_resultObj.slow++;
9616
9605
  }
9606
+ document.getElementById(`diff${_fjdg}J`).innerHTML = diffJDisp;
9617
9607
  };
9618
9608
 
9619
9609
  /**
@@ -9691,10 +9681,7 @@ const updateCombo = _ => {
9691
9681
  */
9692
9682
  const judgeRecovery = (_name, _difFrame) => {
9693
9683
  changeJudgeCharacter(_name, g_lblNameObj[`j_${_name}`]);
9694
-
9695
9684
  updateCombo();
9696
- displayDiff(_difFrame);
9697
-
9698
9685
  lifeRecovery();
9699
9686
  finishViewing();
9700
9687
 
@@ -9734,8 +9721,6 @@ const judgeShakin = _difFrame => judgeRecovery(`shakin`, _difFrame);
9734
9721
  const judgeMatari = _difFrame => {
9735
9722
  changeJudgeCharacter(`matari`, g_lblNameObj.j_matari);
9736
9723
  comboJ.textContent = ``;
9737
-
9738
- displayDiff(_difFrame);
9739
9724
  finishViewing();
9740
9725
 
9741
9726
  g_customJsObj.judg_matari.forEach(func => func(_difFrame));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "danoniplus",
3
- "version": "29.1.0",
3
+ "version": "29.2.0",
4
4
  "description": "Dancing☆Onigiri (CW Edition) - Web-based Rhythm Game",
5
5
  "main": "index.js",
6
6
  "scripts": {