danoniplus 28.1.2 → 28.2.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.
@@ -4,29 +4,32 @@
4
4
  本体cssファイル
5
5
 
6
6
  Created : 2018/10/08
7
- Revised : 2022/03/27 (v27.2.0)
7
+ Revised : 2022/10/05 (v28.2.1)
8
8
 
9
9
  https://github.com/cwtickle/danoniplus
10
10
  ------------------------------------------ */
11
11
 
12
12
  #canvas-frame {
13
- height:500px;
13
+ height: 500px;
14
14
  position: relative;
15
15
  overflow: hidden;
16
+ white-space: nowrap;
16
17
  }
18
+
17
19
  #canvas-frame canvas {
18
20
  position: absolute;
19
- left:0;
21
+ left: 0;
20
22
  overflow: hidden;
21
23
  }
22
24
 
23
- input[type=range] {
25
+ input[type="range"] {
24
26
  -webkit-appearance: none;
25
27
  background: transparent;
26
28
  height: 20px;
27
29
  width: 205px;
28
30
  }
29
- input[type=range]::-webkit-slider-thumb {
31
+
32
+ input[type="range"]::-webkit-slider-thumb {
30
33
  -webkit-appearance: none;
31
34
  background: #606060;
32
35
  height: 20px;
@@ -34,10 +37,12 @@ input[type=range]::-webkit-slider-thumb {
34
37
  opacity: 0.5;
35
38
  border-radius: 50%;
36
39
  }
37
- input[type=range]::-moz-range-track{
40
+
41
+ input[type="range"]::-moz-range-track {
38
42
  height: 0;
39
43
  }
40
- input[type=range]::-moz-range-thumb{
44
+
45
+ input[type="range"]::-moz-range-thumb {
41
46
  background: #606060;
42
47
  height: 20px;
43
48
  width: 20px;
@@ -45,24 +50,27 @@ input[type=range]::-moz-range-thumb{
45
50
  border: none;
46
51
  border-radius: 50%;
47
52
  }
48
- input[type=range]:focus {
53
+
54
+ input[type="range"]:focus {
49
55
  outline: 0;
50
56
  }
51
57
 
52
- input[type=color] {
53
- width:25px;
54
- height:25px;
55
- border:none;
58
+ input[type="color"] {
59
+ width: 25px;
60
+ height: 25px;
61
+ border: none;
62
+ padding: 1px;
56
63
  }
57
64
 
58
65
  /* 左から右へ */
59
66
  @keyframes leftToRight {
60
67
  0% {
61
- opacity: 0;/* 透明 */
68
+ opacity: 0;
62
69
  transform: translateX(-50px);
63
70
  }
71
+
64
72
  100% {
65
- opacity: 1;/* 不透明 */
73
+ opacity: 1;
66
74
  transform: translateX(0);
67
75
  }
68
76
  }
@@ -70,11 +78,12 @@ input[type=color] {
70
78
  /* 上から下へ */
71
79
  @keyframes upToDown {
72
80
  0% {
73
- opacity: 0;/* 透明 */
81
+ opacity: 0;
74
82
  transform: translateY(-50px);
75
83
  }
84
+
76
85
  100% {
77
- opacity: 1;/* 不透明 */
86
+ opacity: 1;
78
87
  transform: translateY(0);
79
88
  }
80
89
  }
@@ -82,19 +91,22 @@ input[type=color] {
82
91
  /* 左から右へ移動し、フェードアウト(結果画面で使用) */
83
92
  @keyframes leftToRightFade {
84
93
  0% {
85
- opacity: 0;/* 透明 */
94
+ opacity: 0;
86
95
  transform: translateX(-30px);
87
96
  }
97
+
88
98
  30% {
89
- opacity: 1;/* 不透明 */
99
+ opacity: 1;
90
100
  transform: translateX(0);
91
101
  }
102
+
92
103
  60% {
93
- opacity: 1;/* 不透明 */
104
+ opacity: 1;
94
105
  transform: translateX(0);
95
106
  }
107
+
96
108
  100% {
97
- opacity: 0;/* 透明 */
109
+ opacity: 0;
98
110
  transform: translateX(30px);
99
111
  }
100
112
  }
@@ -102,19 +114,22 @@ input[type=color] {
102
114
  /* 上から下へ移動し、フェードアウト(結果画面で使用) */
103
115
  @keyframes upToDownFade {
104
116
  0% {
105
- opacity: 0;/* 透明 */
117
+ opacity: 0;
106
118
  transform: translateY(-30px);
107
119
  }
120
+
108
121
  30% {
109
- opacity: 1;/* 不透明 */
122
+ opacity: 1;
110
123
  transform: translateY(0);
111
124
  }
125
+
112
126
  80% {
113
- opacity: 1;/* 不透明 */
127
+ opacity: 1;
114
128
  transform: translateY(0);
115
129
  }
130
+
116
131
  100% {
117
- opacity: 0;/* 透明 */
132
+ opacity: 0;
118
133
  transform: translateY(10px);
119
134
  }
120
135
  }
@@ -122,25 +137,27 @@ input[type=color] {
122
137
  /* 徐々に表示(結果画面で使用) */
123
138
  @keyframes slowlyAppearing {
124
139
  0% {
125
- opacity: 0.5;/* 透明 */
140
+ opacity: 0.5;
126
141
  }
142
+
127
143
  80% {
128
- opacity: 0.5;/* 透明 */
144
+ opacity: 0.5;
129
145
  }
146
+
130
147
  100% {
131
- opacity: 1;/* 不透明 */
148
+ opacity: 1;
132
149
  }
133
150
  }
134
151
 
135
152
  /* 文字拡大から元のサイズへ戻る */
136
153
  @keyframes fromBig {
137
154
  0% {
138
- opacity: 0;/* 透明 */
155
+ opacity: 0;
139
156
  transform: scale(1.5, 1.5);
140
-
141
157
  }
158
+
142
159
  100% {
143
- opacity: 1;/* 不透明 */
160
+ opacity: 1;
144
161
  transform: scale(1, 1);
145
162
  }
146
163
  }
@@ -148,11 +165,12 @@ input[type=color] {
148
165
  /* 徐々に表示(Y方向) */
149
166
  @keyframes smallToNormalY {
150
167
  0% {
151
- opacity: 0;/* 透明 */
168
+ opacity: 0;
152
169
  transform: scale(1, 0);
153
170
  }
171
+
154
172
  100% {
155
- opacity: 1;/* 不透明 */
173
+ opacity: 1;
156
174
  transform: scale(1, 1);
157
175
  }
158
176
  }
@@ -162,6 +180,7 @@ input[type=color] {
162
180
  0% {
163
181
  transform: rotateX(0deg);
164
182
  }
183
+
165
184
  100% {
166
185
  transform: rotateX(360deg);
167
186
  }
@@ -172,6 +191,7 @@ input[type=color] {
172
191
  0% {
173
192
  transform: rotateY(0deg);
174
193
  }
194
+
175
195
  100% {
176
196
  transform: rotateY(360deg);
177
197
  }
@@ -182,6 +202,7 @@ input[type=color] {
182
202
  0% {
183
203
  transform: rotateZ(0deg);
184
204
  }
205
+
185
206
  100% {
186
207
  transform: rotateZ(360deg);
187
208
  }
@@ -192,6 +213,7 @@ input[type=color] {
192
213
  0% {
193
214
  filter: blur(8px);
194
215
  }
216
+
195
217
  100% {
196
218
  filter: blur(0);
197
219
  }
@@ -202,12 +224,15 @@ input[type=color] {
202
224
  0% {
203
225
  filter: brightness(0.0);
204
226
  }
227
+
205
228
  30% {
206
229
  filter: brightness(2.0);
207
230
  }
231
+
208
232
  70% {
209
233
  filter: brightness(0.0);
210
234
  }
235
+
211
236
  100% {
212
237
  filter: brightness(1.0);
213
238
  }
@@ -218,6 +243,7 @@ input[type=color] {
218
243
  0% {
219
244
  opacity: 0;
220
245
  }
246
+
221
247
  100% {
222
248
  opacity: 1;
223
249
  }
@@ -227,6 +253,7 @@ input[type=color] {
227
253
  0% {
228
254
  opacity: 0;
229
255
  }
256
+
230
257
  100% {
231
258
  opacity: 1;
232
259
  }
@@ -237,6 +264,7 @@ input[type=color] {
237
264
  0% {
238
265
  opacity: 1;
239
266
  }
267
+
240
268
  100% {
241
269
  opacity: 0;
242
270
  }
@@ -246,6 +274,7 @@ input[type=color] {
246
274
  0% {
247
275
  opacity: 1;
248
276
  }
277
+
249
278
  100% {
250
279
  opacity: 0;
251
280
  }
@@ -254,29 +283,35 @@ input[type=color] {
254
283
  .toRight {
255
284
  animation-name: leftToRight;
256
285
  }
286
+
257
287
  .toSpin {
258
288
  animation-name: spinY;
259
289
  }
260
290
 
261
291
  /* 設定画面:ゲージ設定詳細 */
262
292
  .settings_gaugeVal {
263
- font-size:12px;
293
+ font-size: 12px;
264
294
  }
295
+
265
296
  .settings_gaugeDivCover {
266
297
  border: 1px #666666 solid;
267
298
  width: 280px;
268
299
  }
300
+
269
301
  .settings_gaugeDivTable {
270
302
  display: table;
271
303
  width: 279px;
272
304
  }
305
+
273
306
  .settings_gaugeDivTableCol {
274
307
  display: table-cell;
275
308
  border-collapse: collapse;
276
309
  }
310
+
277
311
  .settings_gaugeStart {
278
312
  width: 85px;
279
313
  }
314
+
280
315
  .settings_gaugeEtc {
281
316
  width: 65px;
282
317
  }
@@ -296,6 +331,7 @@ input[type=color] {
296
331
  justify-content: center;
297
332
  cursor: default;
298
333
  }
334
+
299
335
  .button_common:hover {
300
336
  cursor: pointer;
301
337
  }
@@ -306,6 +342,6 @@ input[type=color] {
306
342
  }
307
343
 
308
344
  /* 警告ウィンドウ */
309
- #lblWarning > p {
345
+ #lblWarning>p {
310
346
  margin: 15px 5px;
311
347
  }
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/10/02
7
+ * Revised : 2022/10/05
8
8
  *
9
9
  * https://github.com/cwtickle/danoniplus
10
10
  */
11
- const g_version = `Ver 28.1.2`;
12
- const g_revisedDate = `2022/10/02`;
11
+ const g_version = `Ver 28.2.1`;
12
+ const g_revisedDate = `2022/10/05`;
13
13
  const g_alphaVersion = ``;
14
14
 
15
15
  // カスタム用バージョン (danoni_custom.js 等で指定可)
@@ -1811,6 +1811,12 @@ const initialControl = async () => {
1811
1811
  makeDedupliArray(g_rootObj.keyExtraList.split(`,`), g_headerObj.undefinedKeyLists) : g_headerObj.undefinedKeyLists),
1812
1812
  });
1813
1813
 
1814
+ // デフォルトのカラー・シャッフルグループ設定を退避
1815
+ [`color`, `shuffle`].forEach(type => {
1816
+ const tmpName = Object.keys(g_keyObj).filter(val => val.startsWith(type));
1817
+ tmpName.forEach(property => g_keyObj[`${property}d`] = structuredClone(g_keyObj[property]));
1818
+ });
1819
+
1814
1820
  // 自動横幅拡張設定
1815
1821
  if (g_headerObj.autoSpread) {
1816
1822
  const widthList = [g_sWidth, g_presetObj.autoMinWidth ?? g_keyObj.minWidth];
@@ -1818,6 +1824,7 @@ const initialControl = async () => {
1818
1824
 
1819
1825
  g_sWidth = Math.max(...widthList);
1820
1826
  $id(`canvas-frame`).width = `${g_sWidth}px`;
1827
+ $id(`divRoot`).width = `${g_sWidth}px`;
1821
1828
  }
1822
1829
  if (g_headerObj.playingWidth === `default`) {
1823
1830
  g_headerObj.playingWidth = g_sWidth;
@@ -1950,6 +1957,13 @@ const loadLocalStorage = _ => {
1950
1957
  g_localStorage.highscores = {};
1951
1958
  }
1952
1959
 
1960
+ // 廃棄済みリストからデータを消去
1961
+ g_storeSettingsEx.forEach(val => {
1962
+ if (g_localStorage[val] !== undefined) {
1963
+ delete g_localStorage[val];
1964
+ }
1965
+ });
1966
+
1953
1967
  } else {
1954
1968
  g_localStorage = {
1955
1969
  adjustment: 0,
@@ -2402,11 +2416,6 @@ const preheaderConvert = _dosObj => {
2402
2416
  // 背景・マスクモーションのパス指定方法を他の設定に合わせる設定
2403
2417
  obj.syncBackPath = setBoolVal(_dosObj.syncBackPath ?? g_presetObj.syncBackPath);
2404
2418
 
2405
- [`color`, `shuffle`].forEach(type => {
2406
- const tmpName = Object.keys(g_keyObj).filter(val => val.startsWith(type) && val.endsWith(`_0`));
2407
- tmpName.forEach(property => g_dfKeyObj[property] = structuredClone(g_keyObj[property]));
2408
- });
2409
-
2410
2419
  return obj;
2411
2420
  };
2412
2421
 
@@ -2906,7 +2915,7 @@ const headerConvert = _dosObj => {
2906
2915
  });
2907
2916
  }
2908
2917
 
2909
- // ローカルストレージに保存済みのDisplay設定・ColorType設定を戻す
2918
+ // ローカルストレージに保存済みのAppearance, Opacity設定・ColorType設定を戻す
2910
2919
  g_storeSettings.filter(tmpSetting => hasVal(g_localStorage[tmpSetting])).forEach(setting =>
2911
2920
  g_stateObj[setting] = g_localStorage[setting]);
2912
2921
  if (g_localStorage.colorType !== undefined) {
@@ -3378,6 +3387,7 @@ const keysConvert = (_dosObj, { keyExtraList = _dosObj.keyExtraList.split(`,`) }
3378
3387
  let tmpMinPatterns = 1;
3379
3388
  const keyheader = _name + _key;
3380
3389
  const dfPtn = setIntVal(g_keyObj.dfPtnNum);
3390
+
3381
3391
  if (hasVal(_dosObj[keyheader])) {
3382
3392
  const tmpArray = splitLF2(_dosObj[keyheader]);
3383
3393
  tmpMinPatterns = tmpArray.length;
@@ -3392,6 +3402,49 @@ const keysConvert = (_dosObj, { keyExtraList = _dosObj.keyExtraList.split(`,`) }
3392
3402
  }
3393
3403
  loopFunc(k, keyheader);
3394
3404
  }
3405
+
3406
+ } else if (errCd !== `` && g_keyObj[`${keyheader}_0`] === undefined) {
3407
+ makeWarningWindow(g_msgInfoObj[errCd].split(`{0}`).join(_key));
3408
+ }
3409
+ return tmpMinPatterns;
3410
+ };
3411
+
3412
+ /**
3413
+ * 新キー用複合パラメータ(特殊)
3414
+ * @param {string} _key キー数
3415
+ * @param {string} _name 名前
3416
+ * @param {object} _obj errCd エラーコード
3417
+ * @returns 最小パターン数
3418
+ */
3419
+ const newKeyTripleParam = (_key, _name, { errCd = `` } = {}) => {
3420
+ let tmpMinPatterns = 1;
3421
+ const keyheader = _name + _key;
3422
+ const dfPtn = setIntVal(g_keyObj.dfPtnNum);
3423
+
3424
+ if (hasVal(_dosObj[keyheader])) {
3425
+ const tmpArray = splitLF2(_dosObj[keyheader]);
3426
+ tmpMinPatterns = tmpArray.length;
3427
+ for (let k = 0; k < tmpMinPatterns; k++) {
3428
+ if (existParam(tmpArray[k], `${keyheader}_${k + dfPtn}`)) {
3429
+ continue;
3430
+ }
3431
+ if (g_keyObj[`${_name}${tmpArray[k]}_0`] !== undefined) {
3432
+
3433
+ // 他のキーパターン (例: |shuffle8i=8_0| ) を指定した場合、該当があれば既存パターンからコピー
3434
+ let m = 0;
3435
+ while (g_keyObj[`${_name}${tmpArray[k]}_${m}`] !== undefined) {
3436
+ g_keyObj[`${keyheader}_${k + dfPtn}_${m}`] = structuredClone(g_keyObj[`${_name}${tmpArray[k]}_${m}`]);
3437
+ m++;
3438
+ }
3439
+ } else {
3440
+
3441
+ // 通常の指定方法 (例: |shuffle8i=1,1,1,2,0,0,0,0/1,1,1,1,0,0,0,0| )の場合の取り込み
3442
+ tmpArray[k].split(`/`).forEach((list, m) =>
3443
+ g_keyObj[`${keyheader}_${k + dfPtn}_${m}`] = list.split(`,`).map(n => parseInt(n, 10)));
3444
+ }
3445
+ g_keyObj[`${keyheader}_${k + dfPtn}`] = structuredClone(g_keyObj[`${keyheader}_${k + dfPtn}_0`]);
3446
+ }
3447
+
3395
3448
  } else if (errCd !== `` && g_keyObj[`${keyheader}_0`] === undefined) {
3396
3449
  makeWarningWindow(g_msgInfoObj[errCd].split(`{0}`).join(_key));
3397
3450
  }
@@ -3450,15 +3503,6 @@ const keysConvert = (_dosObj, { keyExtraList = _dosObj.keyExtraList.split(`,`) }
3450
3503
  }
3451
3504
  };
3452
3505
 
3453
- /**
3454
- * 子構成配列へのコピー
3455
- * @param {number} _k
3456
- * @param {string} _header
3457
- * @returns
3458
- */
3459
- const copyChildArray = (_k, _header) =>
3460
- g_keyObj[`${_header}_${_k + g_keyObj.dfPtnNum}_0`] = copyArray2d(g_keyObj[`${_header}_${_k + g_keyObj.dfPtnNum}`]);
3461
-
3462
3506
  // 対象キー毎に処理
3463
3507
  keyExtraList.forEach(newKey => {
3464
3508
  let tmpDivPtn = [];
@@ -3483,10 +3527,7 @@ const keysConvert = (_dosObj, { keyExtraList = _dosObj.keyExtraList.split(`,`) }
3483
3527
  g_keyObj[`minWidth${newKey}`] = _dosObj[`minWidth${newKey}`] ?? g_keyObj[`minWidth${newKey}`] ?? g_keyObj.minWidthDefault;
3484
3528
 
3485
3529
  // 矢印色パターン (colorX_Y)
3486
- tmpMinPatterns = newKeyMultiParam(newKey, `color`, toNumber, {
3487
- errCd: `E_0101`,
3488
- loopFunc: (k, keyheader) => copyChildArray(k, keyheader),
3489
- });
3530
+ tmpMinPatterns = newKeyTripleParam(newKey, `color`, { errCd: `E_0101` });
3490
3531
 
3491
3532
  // 読込変数の接頭辞 (charaX_Y)
3492
3533
  tmpMinPatterns = newKeyMultiParam(newKey, `chara`, toString, { errCd: `E_0102` });
@@ -3560,9 +3601,7 @@ const keysConvert = (_dosObj, { keyExtraList = _dosObj.keyExtraList.split(`,`) }
3560
3601
  newKeySingleParam(newKey, `transKey`, C_TYP_STRING);
3561
3602
 
3562
3603
  // シャッフルグループ (shuffleX_Y)
3563
- newKeyMultiParam(newKey, `shuffle`, toNumber, {
3564
- loopFunc: (k, keyheader) => copyChildArray(k, keyheader),
3565
- });
3604
+ newKeyTripleParam(newKey, `shuffle`);
3566
3605
 
3567
3606
  // スクロールパターン (scrollX_Y)
3568
3607
  // |scroll(newKey)=Cross::1,1,-1,-1,-1,1,1/Split::1,1,1,-1,-1,-1,-1$...|
@@ -4983,8 +5022,9 @@ const createOptionWindow = _sprite => {
4983
5022
  [`color`, `shuffle`].forEach(type => {
4984
5023
  resetGroupList(type, keyCtrlPtn);
4985
5024
  if (g_keyObj.currentPtn === -1) {
4986
- if (storageObj[`${type}${g_keyObj.currentKey}_-1_-1`] !== undefined) {
4987
- g_keyObj[`${type}${g_keyObj.currentKey}_-1`] = structuredClone(storageObj[`${type}${g_keyObj.currentKey}_-1_-1`]);
5025
+ const storageKeyName = storageObj[`${type}${addKey}`] || storageObj[`${type}${g_keyObj.currentKey}_-1_-1`];
5026
+ if (storageKeyName !== undefined) {
5027
+ g_keyObj[`${type}${g_keyObj.currentKey}_-1`] = structuredClone(storageKeyName);
4988
5028
  }
4989
5029
  g_keyObj[`${type}${g_keyObj.currentKey}_-1_-1`] = structuredClone(g_keyObj[`${type}${g_keyObj.currentKey}_-1`]);
4990
5030
  } else {
@@ -5277,14 +5317,12 @@ const getKeyCtrl = (_localStorage, _extraKeyName = ``) => {
5277
5317
  });
5278
5318
 
5279
5319
  [`color`, `shuffle`].forEach(type => {
5280
- if (isUpdate) {
5281
- let maxPtn = 0;
5282
- while (g_keyObj[`${type}${basePtn}_${maxPtn}`] !== undefined) {
5283
- maxPtn++;
5284
- }
5285
- for (let j = 0; j < maxPtn; j++) {
5286
- g_keyObj[`${type}${copyPtn}_${j}`] = copyArray2d(g_keyObj[`${type}${basePtn}_${j}`]);
5287
- }
5320
+ let maxPtn = 0;
5321
+ while (g_keyObj[`${type}${basePtn}_${maxPtn}`] !== undefined) {
5322
+ maxPtn++;
5323
+ }
5324
+ for (let j = 0; j < maxPtn; j++) {
5325
+ g_keyObj[`${type}${copyPtn}_${j}`] = copyArray2d(g_keyObj[`${type}${basePtn}_${j}`]);
5288
5326
  }
5289
5327
  });
5290
5328
  }
@@ -5352,11 +5390,9 @@ const resetGroupList = (_type, _keyCtrlPtn) => {
5352
5390
  g_keycons[`${_type}Groups`] = [0];
5353
5391
 
5354
5392
  if (g_keyObj.currentPtn === -1) {
5355
- g_keycons[`${_type}GroupNum`] = -1;
5356
5393
  g_keycons[`${_type}Groups`] = addValtoArray(g_keycons[`${_type}Groups`], -1);
5357
- } else {
5358
- g_keycons[`${_type}GroupNum`] = 0;
5359
5394
  }
5395
+ g_keycons[`${_type}GroupNum`] = (g_keyObj.currentPtn === -1 ? -1 : 0);
5360
5396
  while (g_keyObj[`${_type}${_keyCtrlPtn}_${k}`] !== undefined) {
5361
5397
  g_keycons[`${_type}Groups`].push(k);
5362
5398
  k++;
@@ -5606,9 +5642,6 @@ const keyConfigInit = (_kcType = g_kcType) => {
5606
5642
  const maxLeftPos = Math.max(divideCnt, posMax - divideCnt - 2) / 2;
5607
5643
  const maxLeftX = Math.min(0, (kWidth - C_ARW_WIDTH) / 2 - maxLeftPos * g_keyObj.blank);
5608
5644
 
5609
- // カラーグループ、シャッフルグループの再設定
5610
- [`color`, `shuffle`].forEach(type => resetGroupList(type, keyCtrlPtn));
5611
-
5612
5645
  /**
5613
5646
  * keyconSpriteのスクロール位置調整
5614
5647
  * @param {number} _targetX
@@ -5859,10 +5892,9 @@ const keyConfigInit = (_kcType = g_kcType) => {
5859
5892
  const makeGroupButton = (_type, { baseX = g_sWidth * 5 / 6 - 20, cssName } = {}) => {
5860
5893
  if (g_headerObj[`${_type}Use`] && g_keycons[`${_type}Groups`].length > 1) {
5861
5894
  const typeName = toCapitalize(_type);
5862
- const num = g_keycons[`${_type}GroupNum`] === -1 ? g_keycons.groupSelf : g_keycons[`${_type}GroupNum`] + 1;
5863
5895
  multiAppend(divRoot,
5864
5896
  makeKCButtonHeader(`lbl${_type}Group`, `${typeName}Group`, { x: baseX - 10, y: 37 }, cssName),
5865
- makeKCButton(`lnk${typeName}Group`, `${num}`, _ => setGroup(_type), {
5897
+ makeKCButton(`lnk${typeName}Group`, ``, _ => setGroup(_type), {
5866
5898
  x: baseX, y: 50, w: g_sWidth / 18, title: g_msgObj[`${_type}Group`], cxtFunc: _ => setGroup(_type, -1),
5867
5899
  }),
5868
5900
  makeMiniKCButton(`lnk${typeName}Group`, `L`, _ => setGroup(_type, -1), { x: baseX - 10, y: 50 }),
@@ -6093,16 +6125,53 @@ const keyConfigInit = (_kcType = g_kcType) => {
6093
6125
  const lblTransKey = hasVal(g_keyObj[`transKey${keyCtrlPtn}`]) ?
6094
6126
  `(${g_keyObj[`transKey${keyCtrlPtn}`] ?? ''})` : ``;
6095
6127
 
6096
- // パターン検索
6097
- const searchPattern = (_tempPtn, _sign, _transKeyUse = false, _keyCheck = `keyCtrl`) => {
6098
- while (hasVal(g_keyObj[`${_keyCheck}${g_keyObj.currentKey}_${_tempPtn}`]) &&
6099
- _transKeyUse === false) {
6100
- _tempPtn += _sign;
6101
- if (g_keyObj[`keyCtrl${g_keyObj.currentKey}_${_tempPtn}`] === undefined) {
6102
- break;
6128
+ /**
6129
+ * キーパターン検索
6130
+ * @param {number} _tempPtn
6131
+ * @param {number} _sign
6132
+ * @param {boolean} _transKeyUse
6133
+ * @returns
6134
+ */
6135
+ const searchPattern = (_tempPtn, _sign, _transKeyUse = false) => {
6136
+ let nextPtn = _tempPtn + _sign;
6137
+
6138
+ const searchStart = _ => {
6139
+ nextPtn = 0;
6140
+ while (hasVal(g_keyObj[`keyCtrl${g_keyObj.currentKey}_${nextPtn}`])) {
6141
+ nextPtn -= _sign;
6142
+ }
6143
+ nextPtn += _sign;
6144
+ };
6145
+
6146
+ if (hasVal(g_keyObj[`keyCtrl${g_keyObj.currentKey}_${nextPtn}`])) {
6147
+ } else {
6148
+ searchStart();
6149
+ }
6150
+ if (!_transKeyUse) {
6151
+ while (hasVal(g_keyObj[`transKey${g_keyObj.currentKey}_${nextPtn}`])) {
6152
+ nextPtn += _sign;
6153
+ }
6154
+ if (!hasVal(g_keyObj[`keyCtrl${g_keyObj.currentKey}_${nextPtn}`])) {
6155
+ searchStart();
6103
6156
  }
6104
6157
  }
6105
- return _tempPtn;
6158
+ return nextPtn;
6159
+ };
6160
+
6161
+ /**
6162
+ * キーパターン変更時処理
6163
+ * @param {number} _sign
6164
+ */
6165
+ const changePattern = (_sign = 1) => {
6166
+
6167
+ // キーパターンの変更
6168
+ g_keyObj.currentPtn = searchPattern(g_keyObj.currentPtn, _sign, g_headerObj.transKeyUse);
6169
+
6170
+ // カラーグループ、シャッフルグループの再設定
6171
+ [`color`, `shuffle`].forEach(type => resetGroupList(type, `${g_keyObj.currentKey}_${g_keyObj.currentPtn}`));
6172
+
6173
+ // キーコンフィグ画面を再呼び出し
6174
+ keyConfigInit();
6106
6175
  };
6107
6176
 
6108
6177
  // ユーザカスタムイベント(初期)
@@ -6125,24 +6194,12 @@ const keyConfigInit = (_kcType = g_kcType) => {
6125
6194
 
6126
6195
  // パターン変更ボタン描画(右回り)
6127
6196
  createCss2Button(`btnPtnChangeR`, `>>`, _ => true, Object.assign(g_lblPosObj.btnPtnChangeR, {
6128
- resetFunc: _ => {
6129
- const tempPtn = searchPattern(g_keyObj.currentPtn + 1, 1, g_headerObj.transKeyUse, `transKey`);
6130
- g_keyObj.currentPtn = (g_keyObj[`keyCtrl${g_keyObj.currentKey}_${tempPtn}`] !== undefined ?
6131
- tempPtn : (g_keyObj[`keyCtrl${g_keyObj.currentKey}_-1`] !== undefined ? -1 : 0));
6132
-
6133
- keyConfigInit();
6134
- },
6197
+ resetFunc: _ => changePattern(),
6135
6198
  }), g_cssObj.button_Setting),
6136
6199
 
6137
6200
  // パターン変更ボタン描画(左回り)
6138
6201
  createCss2Button(`btnPtnChangeL`, `<<`, _ => true, Object.assign(g_lblPosObj.btnPtnChangeL, {
6139
- resetFunc: _ => {
6140
- const tempPtn = searchPattern(g_keyObj.currentPtn - 1, -1, g_headerObj.transKeyUse, `transKey`);
6141
- g_keyObj.currentPtn = (g_keyObj[`keyCtrl${g_keyObj.currentKey}_${tempPtn}`] !== undefined ?
6142
- tempPtn : searchPattern(searchPattern(0, 1) - 1, -1, g_headerObj.transKeyUse, `transKey`));
6143
-
6144
- keyConfigInit();
6145
- },
6202
+ resetFunc: _ => changePattern(-1),
6146
6203
  }), g_cssObj.button_Setting),
6147
6204
 
6148
6205
  // キーコンフィグリセットボタン描画
@@ -7941,14 +7998,20 @@ const getArrowSettings = _ => {
7941
7998
 
7942
7999
  [`color`, `shuffle`].forEach(type => {
7943
8000
  const groupNum = g_keycons[`${type}GroupNum`];
7944
- storageObj[`${type}${g_keyObj.currentKey}_-1_-1`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}`]);
7945
- g_keyObj[`${type}${g_keyObj.currentKey}_-1_${groupNum}`] = structuredClone(g_dfKeyObj[`${type}${keyCtrlPtn}_${groupNum}`]);
7946
- g_keyObj[`${type}${keyCtrlPtn}_${groupNum}`] = structuredClone(g_dfKeyObj[`${type}${keyCtrlPtn}_${groupNum}`]);
8001
+ storageObj[`${type}${addKey}`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}`]);
8002
+ g_keyObj[`${type}${g_keyObj.currentKey}_-1_${groupNum}`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}d`]);
8003
+ g_keyObj[`${type}${keyCtrlPtn}_${groupNum}`] = structuredClone(g_keyObj[`${type}${keyCtrlPtn}_${groupNum}d`]);
8004
+
8005
+ // 古いキーデータの削除 (互換用)
8006
+ if (storageObj[`${type}${g_keyObj.currentKey}_-1_-1`] !== undefined) {
8007
+ delete storageObj[`${type}${g_keyObj.currentKey}_-1_-1`];
8008
+ }
7947
8009
  });
7948
8010
 
7949
8011
  if (!g_stateObj.extraKeyFlg) {
7950
8012
  localStorage.setItem(`danonicw-${g_keyObj.currentKey}k`, JSON.stringify(g_localKeyStorage));
7951
8013
  }
8014
+
7952
8015
  localStorage.setItem(g_localStorageUrl, JSON.stringify(g_localStorage));
7953
8016
  g_canLoadDifInfoFlg = true;
7954
8017
 
@@ -5,7 +5,7 @@
5
5
  *
6
6
  * Source by tickle
7
7
  * Created : 2019/11/19
8
- * Revised : 2022/10/02 (v28.1.0)
8
+ * Revised : 2022/10/05 (v28.2.1)
9
9
  *
10
10
  * https://github.com/cwtickle/danoniplus
11
11
  */
@@ -837,7 +837,11 @@ const g_keycons = {
837
837
  let g_displays = [`stepZone`, `judgment`, `fastSlow`, `lifeGauge`, `score`, `musicInfo`, `filterLine`,
838
838
  `speed`, `color`, `lyrics`, `background`, `arrowEffect`, `special`];
839
839
 
840
- let g_storeSettings = [`appearance`, `opacity`, `d_stepzone`, `d_judgment`, `d_fastslow`, `d_lifegauge`,
840
+ // ローカルストレージ保存対象
841
+ let g_storeSettings = [`appearance`, `opacity`];
842
+
843
+ // 廃棄対象のリスト(過去の登録対象をリスト化。ここに乗せるとローカルストレージから自動消去される)
844
+ let g_storeSettingsEx = [`d_stepzone`, `d_judgment`, `d_fastslow`, `d_lifegauge`,
841
845
  `d_score`, `d_musicinfo`, `d_filterline`];
842
846
 
843
847
  let g_canDisabledSettings = [`motion`, `scroll`, `shuffle`, `autoPlay`, `gauge`, `appearance`];
@@ -1418,8 +1422,6 @@ const g_cssObj = {
1418
1422
  flex_centering: `flex_centering`,
1419
1423
  };
1420
1424
 
1421
- const g_dfKeyObj = {};
1422
-
1423
1425
  // キー別の設定(一旦ここで定義)
1424
1426
  // ステップゾーンの位置関係は自動化を想定
1425
1427
  const g_keyObj = {
@@ -2924,7 +2926,7 @@ const g_lblNameObj = {
2924
2926
  filterLock: `Lock`,
2925
2927
 
2926
2928
  sc_speed: `←→`,
2927
- sc_scroll: `R/↑↓`,
2929
+ sc_scroll: `R/<br>↑↓`,
2928
2930
  sc_adjustment: `- +`,
2929
2931
  sc_keyConfigPlay: g_isMac ? `Del+Enter` : `BS+Enter`,
2930
2932
 
@@ -3067,7 +3069,7 @@ const g_lblNameObj = {
3067
3069
  const g_lang_lblNameObj = {
3068
3070
  Ja: {
3069
3071
  kcDesc: `[{0}:スキップ / {1}:(代替キーのみ)キー無効化]`,
3070
- kcShuffleDesc: `番号をクリックでシャッフルグループ、矢印をクリックでカラーグループを一時的に変更`,
3072
+ kcShuffleDesc: `番号をクリックでシャッフルグループ、矢印をクリックでカラーグループを変更`,
3071
3073
  sdDesc: `[クリックでON/OFFを切替、灰色でOFF]`,
3072
3074
  kcShortcutDesc: `プレイ中ショートカット:「{0}」タイトルバック / 「{1}」リトライ`,
3073
3075
  transKeyDesc: `別キーモードではハイスコア、キーコンフィグ等は保存されません`,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "danoniplus",
3
- "version": "28.1.2",
3
+ "version": "28.2.1",
4
4
  "description": "Dancing☆Onigiri (CW Edition) - Web-based Rhythm Game",
5
5
  "main": "index.js",
6
6
  "scripts": {