Skip to content

Commit 923e30f

Browse files
Merge branch 'master' into dev
2 parents e5b60c5 + 9c67994 commit 923e30f

13 files changed

Lines changed: 369 additions & 8 deletions

File tree

Assets/SequenceSDK/WaaS/Tests/WaaSFederatedAuthTests.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
using PlayFab.ClientModels;
66
using Sequence.EmbeddedWallet;
77
using UnityEngine;
8+
using Random = UnityEngine.Random;
89

910
namespace Sequence.EmbeddedWallet.Tests
1011
{
@@ -86,7 +87,7 @@ private void RetryIfAlreadyLinked(string error)
8687
{
8788
if (error.Contains("AccountAlreadyLinked"))
8889
{
89-
_email = "a" + _email;
90+
_email = Random.Range(0, 9999999).ToString() + _email;
9091
var request = new LoginWithEmailAddressRequest
9192
{
9293
Email = _email,

Packages/Sequence-Unity/Sequence/SequenceFrontend/ScriptableObjects/NetworkIcons.asset

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ MonoBehaviour:
5757
Value: {fileID: 21300000, guid: bd5c36b9fb9f344faac5498fb1ef8adf, type: 3}
5858
- Key: 40
5959
Value: {fileID: 21300000, guid: fca1fb969526641ab92a7dadb3373992, type: 3}
60+
- Key: 1284
61+
Value: {fileID: 21300000, guid: 487a52377dc99420699217f27a3f7940, type: 3}
6062
- Key: 11155111
6163
Value: {fileID: 21300000, guid: 3e21b6696eaaa46b1b176b8b5e6254a3, type: 3}
6264
- Key: 80002
@@ -101,3 +103,5 @@ MonoBehaviour:
101103
Value: {fileID: 21300000, guid: 636803a1680c145c99675de2aaf50a81, type: 3}
102104
- Key: 41
103105
Value: {fileID: 21300000, guid: fca1fb969526641ab92a7dadb3373992, type: 3}
106+
- Key: 1287
107+
Value: {fileID: 21300000, guid: 67e27505fbd0e4afe8ed08544b5e232d, type: 3}

Packages/Sequence-Unity/Sequence/SequenceFrontend/Scripts/UI/LoginPage.cs

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
using Sequence.EmbeddedWallet;
44
using TMPro;
55
using UnityEngine;
6+
using System.Collections;
67

78
namespace Sequence.Demo
89
{
@@ -160,5 +161,24 @@ private void EnableLoadingScreen(bool enable)
160161
{
161162
_loadingScreen.SetActive(enable);
162163
}
164+
165+
private void OnApplicationFocus(bool hasFocus)
166+
{
167+
#if !UNITY_IOS
168+
if (hasFocus)
169+
{
170+
StartCoroutine(DisableLoadingScreenIfNotLoggingIn());
171+
}
172+
#endif
173+
}
174+
175+
private IEnumerator DisableLoadingScreenIfNotLoggingIn()
176+
{
177+
yield return new WaitForSecondsRealtime(0.1f);
178+
if (!LoginHandler.IsLoggingIn())
179+
{
180+
EnableLoadingScreen(false);
181+
}
182+
}
163183
}
164184
}
12 KB
Loading

Packages/Sequence-Unity/Sequence/SequenceFrontend/Sprites/Networks/Icons/1284.png.meta

Lines changed: 158 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
12.6 KB
Loading

Packages/Sequence-Unity/Sequence/SequenceFrontend/Sprites/Networks/Icons/1287.png.meta

Lines changed: 158 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Packages/Sequence-Unity/Sequence/SequenceSDK/EmbeddedWallet/SequenceLogin.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,9 @@ private void CreateWallet(IValidator validator = null, IAuthenticator authentica
108108

109109
public void ResetSessionId()
110110
{
111+
if (_connectedWalletAddress != null) {
112+
return;
113+
}
111114
_sessionWallet = new EOAWallet();
112115
_sessionId = IntentDataOpenSession.CreateSessionId(_sessionWallet.GetAddress());
113116
_intentSender = new IntentSender(new HttpClient(WaaSWithAuthUrl), _sessionWallet, _sessionId, _waasProjectId, _waasVersion);

0 commit comments

Comments
 (0)