pixi-rainman-game-engine 0.1.24 → 0.1.25
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/dist/SettingsUI/components/AutoplaySettings/autoplaySettings.css +40 -50
- package/dist/SettingsUI/components/AutoplaySettings/index.jsx +13 -16
- package/dist/SettingsUI/index.css +6 -0
- package/dist/application/ButtonsEventManager/ButtonsEventManager.js +6 -12
- package/dist/components/common/AnimatedBackground.js +0 -1
- package/dist/utils/common/functions.js +1 -1
- package/package.json +1 -1
|
@@ -59,18 +59,17 @@
|
|
|
59
59
|
|
|
60
60
|
.autoplay-settings__stop-limits {
|
|
61
61
|
display: flex;
|
|
62
|
-
|
|
62
|
+
justify-content: center;
|
|
63
63
|
width: 100%;
|
|
64
64
|
height: 50px;
|
|
65
|
-
justify-content: center;
|
|
66
65
|
}
|
|
67
66
|
|
|
68
67
|
.autoplay-settings__limit {
|
|
69
|
-
width: 40px;
|
|
70
|
-
border: solid 2px white;
|
|
71
68
|
display: flex;
|
|
72
69
|
align-items: center;
|
|
73
70
|
justify-content: center;
|
|
71
|
+
width: 40px;
|
|
72
|
+
border: solid 2px white;
|
|
74
73
|
font-size: 20px;
|
|
75
74
|
font-weight: bolder;
|
|
76
75
|
margin: 0px 5px;
|
|
@@ -95,10 +94,14 @@
|
|
|
95
94
|
}
|
|
96
95
|
|
|
97
96
|
.left {
|
|
97
|
+
background-color: #00000000;
|
|
98
|
+
text-align: center;
|
|
98
99
|
border-radius: 34px 0px 0px 34px;
|
|
99
100
|
}
|
|
100
101
|
|
|
101
102
|
.right {
|
|
103
|
+
background-color: #00000000;
|
|
104
|
+
text-align: center;
|
|
102
105
|
border-radius: 0px 34px 34px 0px;
|
|
103
106
|
}
|
|
104
107
|
|
|
@@ -109,6 +112,7 @@
|
|
|
109
112
|
}
|
|
110
113
|
|
|
111
114
|
.circle {
|
|
115
|
+
background-color: #00000000;
|
|
112
116
|
border-radius: 34px;
|
|
113
117
|
font-size: 40px;
|
|
114
118
|
}
|
|
@@ -164,10 +168,6 @@
|
|
|
164
168
|
width: 90%;
|
|
165
169
|
}
|
|
166
170
|
|
|
167
|
-
.autoplay-settings__column {
|
|
168
|
-
flex-direction: column-reverse;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
171
|
.autoplay-settings__switches {
|
|
172
172
|
width: 100%;
|
|
173
173
|
flex-direction: column;
|
|
@@ -179,46 +179,66 @@
|
|
|
179
179
|
margin: 5px 0px;
|
|
180
180
|
}
|
|
181
181
|
|
|
182
|
-
.
|
|
183
|
-
|
|
184
|
-
|
|
182
|
+
.autoplay-settings__limit {
|
|
183
|
+
align-items: center;
|
|
184
|
+
justify-content: center;
|
|
185
|
+
text-align: center;
|
|
186
|
+
margin: 0px;
|
|
187
|
+
padding: 0px;
|
|
185
188
|
}
|
|
186
189
|
|
|
187
190
|
.right {
|
|
188
|
-
width:
|
|
191
|
+
width: 34px;
|
|
192
|
+
height: 34px;
|
|
193
|
+
font-size: 12px;
|
|
194
|
+
background-color: #00000000;
|
|
189
195
|
border-radius: 0px 34px 34px 0px;
|
|
190
196
|
}
|
|
191
197
|
|
|
192
198
|
.middle {
|
|
193
|
-
width:
|
|
199
|
+
width: 34px;
|
|
200
|
+
height: 34px;
|
|
194
201
|
font-size: 12px;
|
|
202
|
+
background-color: #00000000;
|
|
195
203
|
border-radius: 0px 0px 0px 0px;
|
|
196
204
|
}
|
|
197
205
|
|
|
206
|
+
.left {
|
|
207
|
+
width: 34px;
|
|
208
|
+
height: 34px;
|
|
209
|
+
background-color: #00000000;
|
|
210
|
+
font-size: 12px;
|
|
211
|
+
border-radius: 34px 0px 0px 34px;
|
|
212
|
+
}
|
|
213
|
+
|
|
198
214
|
.circle {
|
|
199
215
|
border-radius: 34px;
|
|
200
|
-
|
|
201
|
-
|
|
216
|
+
width: 34px;
|
|
217
|
+
height: 34px;
|
|
218
|
+
font-size: 20px;
|
|
219
|
+
background-color: #00000000;
|
|
202
220
|
}
|
|
203
221
|
|
|
204
222
|
.autoplay-settings__stop-limits {
|
|
205
|
-
|
|
223
|
+
width: 100%;
|
|
224
|
+
flex-wrap: wrap;
|
|
225
|
+
height: fit-content;
|
|
226
|
+
overflow: hidden;
|
|
206
227
|
}
|
|
207
228
|
|
|
208
229
|
.autoplay-settings__limit.circle p {
|
|
209
230
|
position: relative;
|
|
210
|
-
top: -4px;
|
|
211
|
-
font-size: 20px;
|
|
212
231
|
}
|
|
213
232
|
|
|
214
233
|
.autoplay-settings__limit.left p {
|
|
215
234
|
position: relative;
|
|
216
|
-
|
|
235
|
+
text-align: center;
|
|
217
236
|
}
|
|
218
237
|
|
|
219
238
|
.autoplay-settings__limit.right p {
|
|
220
239
|
position: relative;
|
|
221
|
-
|
|
240
|
+
text-align: center;
|
|
241
|
+
margin: 0px;
|
|
222
242
|
}
|
|
223
243
|
|
|
224
244
|
.autoplay-settings__confirmation {
|
|
@@ -230,36 +250,6 @@
|
|
|
230
250
|
margin-top: 0px;
|
|
231
251
|
}
|
|
232
252
|
|
|
233
|
-
.left {
|
|
234
|
-
border-radius: 34px 0px 0px 34px;
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
.right {
|
|
238
|
-
border-radius: 0px 34px 34px 0px;
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
.middle {
|
|
242
|
-
width: 60px;
|
|
243
|
-
border-radius: 0px 0px 0px 0px;
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
.circle {
|
|
247
|
-
border-radius: 34px;
|
|
248
|
-
font-size: 40px;
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
.autoplay-settings__limit.circle p {
|
|
252
|
-
top: -2px;
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
.autoplay-settings__limit.left p {
|
|
256
|
-
top: -2px;
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
.autoplay-settings__limit.right p {
|
|
260
|
-
top: -2px;
|
|
261
|
-
}
|
|
262
|
-
|
|
263
253
|
.autoplay-settings__exit {
|
|
264
254
|
right: -10px;
|
|
265
255
|
top: 10px;
|
|
@@ -56,7 +56,7 @@ export const AutoplaySettings = observer(() => {
|
|
|
56
56
|
<h2>{i18next.t("autoPlay")}</h2>
|
|
57
57
|
</div>
|
|
58
58
|
<div className="autoplay-settings__stop-limits">
|
|
59
|
-
<
|
|
59
|
+
<button className={`autoplay-settings__limit left ${infinitySpinsEnabled ? "autoplay-settings__limit--infinity" : ""}`} onClick={() => {
|
|
60
60
|
let indexOfSelectedSpinsLimit = availableAutoSpinLimits.findIndex((limitCount) => limitCount === howManyAutoSpinsLeft);
|
|
61
61
|
indexOfSelectedSpinsLimit -= 1;
|
|
62
62
|
if (indexOfSelectedSpinsLimit === -1) {
|
|
@@ -65,13 +65,11 @@ export const AutoplaySettings = observer(() => {
|
|
|
65
65
|
updateLimitsBounds(availableAutoSpinLimits[indexOfSelectedSpinsLimit]);
|
|
66
66
|
}}>
|
|
67
67
|
<p>-</p>
|
|
68
|
-
</
|
|
69
|
-
{limit_numbers.map((limiter, index) => {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
})}
|
|
74
|
-
<div className={`autoplay-settings__limit right ${infinitySpinsEnabled ? "autoplay-settings__limit--infinity" : ""}`} onClick={() => {
|
|
68
|
+
</button>
|
|
69
|
+
{limit_numbers.map((limiter, index) => (<button key={`${limiter}${index}`} value={limiter} className={`autoplay-settings__limit ${limiter === howManyAutoSpinsLeft ? "autoplay-settings__limit--active" : ""} middle ${infinitySpinsEnabled ? "autoplay-settings__limit--infinity" : ""}`} disabled={settingStore.infinitySpinsEnabled} onClick={(event) => updateLimitsBounds(Number(event.currentTarget.value))}>
|
|
70
|
+
<p>{limiter}</p>
|
|
71
|
+
</button>))}
|
|
72
|
+
<button className={`autoplay-settings__limit right ${infinitySpinsEnabled ? "autoplay-settings__limit--infinity" : ""}`} onClick={() => {
|
|
75
73
|
let indexOfSelectedSpinsLimit = availableAutoSpinLimits.findIndex((limitCount) => limitCount === howManyAutoSpinsLeft);
|
|
76
74
|
indexOfSelectedSpinsLimit += 1;
|
|
77
75
|
if (indexOfSelectedSpinsLimit === availableAutoSpinLimits.length) {
|
|
@@ -81,12 +79,11 @@ export const AutoplaySettings = observer(() => {
|
|
|
81
79
|
updateLimitsBounds(newAutoSpinsLimitNumber);
|
|
82
80
|
}}>
|
|
83
81
|
<p>+</p>
|
|
84
|
-
</
|
|
85
|
-
<
|
|
82
|
+
</button>
|
|
83
|
+
<button className={`autoplay-settings__limit circle ${infinitySpinsEnabled ? "autoplay-settings__limit--active" : ""}`} onClick={() => flipInfinitySpinsFlag()}>
|
|
86
84
|
<p>∞</p>
|
|
87
|
-
</
|
|
85
|
+
</button>
|
|
88
86
|
</div>
|
|
89
|
-
|
|
90
87
|
<div className="autoplay-settings__title">
|
|
91
88
|
<h2>{i18next.t("stopAutoPlay")}</h2>
|
|
92
89
|
</div>
|
|
@@ -106,16 +103,16 @@ export const AutoplaySettings = observer(() => {
|
|
|
106
103
|
</div>
|
|
107
104
|
|
|
108
105
|
<div className="autoplay-settings__confirmation">
|
|
109
|
-
<
|
|
106
|
+
<button className="autoplay-settings__confirmation-button" onClick={() => {
|
|
110
107
|
resetAutoplaySettings();
|
|
111
108
|
updateLimitsBounds(initialAutoSpinCount);
|
|
112
109
|
settingStore.handleModalInvocation?.(UI_ITEMS.autoplay);
|
|
113
110
|
}}>
|
|
114
111
|
<p>{i18next.t("cancel")}</p>
|
|
115
|
-
</
|
|
116
|
-
<
|
|
112
|
+
</button>
|
|
113
|
+
<button id={COMPONENTS.autoSpinConfirm} className="autoplay-settings__confirmation-button">
|
|
117
114
|
<p>{i18next.t("confirm")}</p>
|
|
118
|
-
</
|
|
115
|
+
</button>
|
|
119
116
|
</div>
|
|
120
117
|
</div>);
|
|
121
118
|
});
|
|
@@ -246,6 +246,7 @@ export class ButtonsEventManager {
|
|
|
246
246
|
const confirmAutoplayButton = window.document.getElementById(COMPONENTS.autoSpinConfirm);
|
|
247
247
|
if (confirmAutoplayButton !== null) {
|
|
248
248
|
confirmAutoplayButton.addEventListener("click", () => {
|
|
249
|
+
RainMan.settingsStore.handleModalInvocation?.(UI_ITEMS.autoplay);
|
|
249
250
|
confirmAutoplayButtonCallback();
|
|
250
251
|
});
|
|
251
252
|
}
|
|
@@ -285,23 +286,16 @@ export class ButtonsEventManager {
|
|
|
285
286
|
* @param {string} layerName
|
|
286
287
|
*/
|
|
287
288
|
handleModalInvocation(layerName) {
|
|
288
|
-
const alreadyInvokedLayer = this.getInvokedSettingItem();
|
|
289
|
-
if (alreadyInvokedLayer !== null) {
|
|
290
|
-
if (alreadyInvokedLayer.style.display === "flex") {
|
|
291
|
-
alreadyInvokedLayer.style.display = "none";
|
|
292
|
-
this.enableButtons();
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
|
-
else {
|
|
296
|
-
this.lastLayerInvoked = "";
|
|
297
|
-
}
|
|
298
289
|
const layer = window.document.getElementById(layerName);
|
|
299
290
|
if (layer !== null) {
|
|
300
|
-
if (layer.style.display !== "flex"
|
|
301
|
-
this.lastLayerInvoked = layerName;
|
|
291
|
+
if (layer.style.display !== "flex") {
|
|
302
292
|
layer.style.display = "flex";
|
|
303
293
|
this.disableButtons();
|
|
304
294
|
}
|
|
295
|
+
else {
|
|
296
|
+
layer.style.display = "none";
|
|
297
|
+
this.enableButtons();
|
|
298
|
+
}
|
|
305
299
|
}
|
|
306
300
|
}
|
|
307
301
|
}
|
|
@@ -25,7 +25,6 @@ export class AnimatedBackground extends ResumableContainer {
|
|
|
25
25
|
this.mobileSpineName = mobileSpineName;
|
|
26
26
|
this.name = AnimatedBackground.registryName;
|
|
27
27
|
this.parentLayer = BackgroundLayer;
|
|
28
|
-
RainMan.settingsStore.containersWithSpines.push(this);
|
|
29
28
|
}
|
|
30
29
|
resize() {
|
|
31
30
|
this.changeSpineForOrientation();
|
|
@@ -64,7 +64,7 @@ export const setTimeScale = (spine, flag) => {
|
|
|
64
64
|
spine.state.timeScale = spine.state.originalTimeScale;
|
|
65
65
|
}
|
|
66
66
|
else {
|
|
67
|
-
spine.state.
|
|
67
|
+
spine.state.timeScale = 0;
|
|
68
68
|
}
|
|
69
69
|
};
|
|
70
70
|
export const changeResolution = (high) => {
|
package/package.json
CHANGED