app.hypergames.hypersdk 1.11.0-beta.5 → 1.11.0-beta.6
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/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [1.11.0-beta.6](https://github.com/mvmhyper/hyper-sdk/compare/v1.11.0-beta.5...v1.11.0-beta.6) (2026-08-29)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **timer:** restore gameplay timers after pause ([ca82d57](https://github.com/mvmhyper/hyper-sdk/commit/ca82d57df87618807cbae611c0a9d6acc14f8470))
|
|
7
|
+
|
|
1
8
|
# [1.11.0-beta.5](https://github.com/mvmhyper/hyper-sdk/compare/v1.11.0-beta.4...v1.11.0-beta.5) (2026-08-28)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -32,6 +32,9 @@ namespace Hyper.Internal.Managers
|
|
|
32
32
|
private float _battleTimer;
|
|
33
33
|
private bool _isPracticeRunning;
|
|
34
34
|
private bool _isBattleRunning;
|
|
35
|
+
private bool _resumePracticeAfterPause;
|
|
36
|
+
private bool _resumeBattleAfterPause;
|
|
37
|
+
private bool _hasPausedGameplayTimerState;
|
|
35
38
|
|
|
36
39
|
private float _fiveSecondTimer = 5f;
|
|
37
40
|
private bool _isFiveSecondTimerRunning;
|
|
@@ -111,6 +114,7 @@ namespace Hyper.Internal.Managers
|
|
|
111
114
|
public void Reset()
|
|
112
115
|
{
|
|
113
116
|
_practiceTimer = 0;
|
|
117
|
+
ClearPausedGameplayTimerState();
|
|
114
118
|
_lastUnscaledTime = Time.unscaledTime;
|
|
115
119
|
}
|
|
116
120
|
|
|
@@ -120,6 +124,7 @@ namespace Hyper.Internal.Managers
|
|
|
120
124
|
_battleTimer = _gameManager != null ? _gameManager.Config.TimeLimit : 0f;
|
|
121
125
|
_isPracticeRunning = false;
|
|
122
126
|
_isBattleRunning = false;
|
|
127
|
+
ClearPausedGameplayTimerState();
|
|
123
128
|
_timeUpTriggered = false;
|
|
124
129
|
_timeUpPending = false;
|
|
125
130
|
_hasGameEnded = false;
|
|
@@ -129,18 +134,17 @@ namespace Hyper.Internal.Managers
|
|
|
129
134
|
|
|
130
135
|
public void ResumeGameTimersAfterPause()
|
|
131
136
|
{
|
|
132
|
-
if (
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
{
|
|
138
|
-
StartPractice();
|
|
139
|
-
}
|
|
137
|
+
if (!_hasPausedGameplayTimerState) return;
|
|
138
|
+
|
|
139
|
+
_isPracticeRunning = _resumePracticeAfterPause;
|
|
140
|
+
_isBattleRunning = _resumeBattleAfterPause;
|
|
141
|
+
ClearPausedGameplayTimerState();
|
|
140
142
|
}
|
|
141
143
|
|
|
142
144
|
public void StartActiveGameTimer()
|
|
143
145
|
{
|
|
146
|
+
ClearPausedGameplayTimerState();
|
|
147
|
+
|
|
144
148
|
if (_gameManager.IsBattleMode)
|
|
145
149
|
{
|
|
146
150
|
StartSessionTimer();
|
|
@@ -158,6 +162,7 @@ namespace Hyper.Internal.Managers
|
|
|
158
162
|
{
|
|
159
163
|
_hasGameEnded = true;
|
|
160
164
|
_timeUpPending = false;
|
|
165
|
+
ClearPausedGameplayTimerState();
|
|
161
166
|
StopBattle();
|
|
162
167
|
StopPractice();
|
|
163
168
|
}
|
|
@@ -168,6 +173,11 @@ namespace Hyper.Internal.Managers
|
|
|
168
173
|
/// </summary>
|
|
169
174
|
public void PauseGameplayTimers()
|
|
170
175
|
{
|
|
176
|
+
if (_hasPausedGameplayTimerState) return;
|
|
177
|
+
|
|
178
|
+
_resumePracticeAfterPause = _isPracticeRunning;
|
|
179
|
+
_resumeBattleAfterPause = _isBattleRunning;
|
|
180
|
+
_hasPausedGameplayTimerState = true;
|
|
171
181
|
StopBattle();
|
|
172
182
|
StopPractice();
|
|
173
183
|
}
|
|
@@ -208,6 +218,13 @@ namespace Hyper.Internal.Managers
|
|
|
208
218
|
internal void StartBattle() => _isBattleRunning = true;
|
|
209
219
|
internal void StopBattle() => _isBattleRunning = false;
|
|
210
220
|
|
|
221
|
+
private void ClearPausedGameplayTimerState()
|
|
222
|
+
{
|
|
223
|
+
_resumePracticeAfterPause = false;
|
|
224
|
+
_resumeBattleAfterPause = false;
|
|
225
|
+
_hasPausedGameplayTimerState = false;
|
|
226
|
+
}
|
|
227
|
+
|
|
211
228
|
internal bool TrySetSessionDurationFromBackendRemainingTime(float remainingTimeSeconds)
|
|
212
229
|
{
|
|
213
230
|
if (_hasBackendSessionDuration)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "app.hypergames.hypersdk",
|
|
3
|
-
"version": "1.11.0-beta.
|
|
3
|
+
"version": "1.11.0-beta.6",
|
|
4
4
|
"displayName": "HyperSDK",
|
|
5
5
|
"description": "Official Unity SDK for Hyper: multiplayer battles, leaderboards, deterministic RNG, session management, tutorials, and WebGL optimizations for production-ready games.",
|
|
6
6
|
"unity": "6000.0",
|