Skip to content
This repository was archived by the owner on Dec 5, 2018. It is now read-only.

Commit ec0821a

Browse files
committed
Upgrade to use Unity SDK 1.0.1
1 parent ca5cf98 commit ec0821a

11 files changed

+42
-15
lines changed

workers/unity/Assets/Plugins/Improbable/Sdk/Dll/Improbable.WorkerSdkCsharp.Framework.dll.meta

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Dll/Improbable.WorkerSdkCsharp.Framework.xml

-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Dll/Improbable.WorkerSdkCsharp.Framework.xml.meta

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Dll/Improbable.WorkerSdkCsharp.dll.meta

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Dll/Improbable.WorkerSdkCsharp.xml.meta

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Src/Editor/EditorAddons.meta

+9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

workers/unity/Assets/Plugins/Improbable/Sdk/Src/Unity/Core/ConnectionLifecycle.cs

+3-2
Original file line numberDiff line numberDiff line change
@@ -149,8 +149,8 @@ private IEnumerator Connect()
149149
var connect = WorkerConnection.ConnectAsync(parameters, Deployment, AttachConnection);
150150
yield return connect;
151151

152-
SpatialOS.ConnectionWasSuccesful = Connection.IsConnected;
153-
if (SpatialOS.ConnectionWasSuccesful)
152+
SpatialOS.ConnectionWasSuccessful = Connection.IsConnected;
153+
if (SpatialOS.ConnectionWasSuccessful)
154154
{
155155
logger = new LogSender(() => SpatialOS.IsConnected, Connection.SendLogMessage, SpatialOS.Configuration, SpatialOS.LogFilter);
156156
SetupComponents();
@@ -200,6 +200,7 @@ private void Update()
200200
// before calling the first OnDestroy).
201201
private void OnApplicationQuit()
202202
{
203+
SpatialOS.SignalApplicationQuit();
203204
Dispose();
204205
}
205206

workers/unity/Assets/Plugins/Improbable/Sdk/Src/Unity/Core/SpatialOS.cs

+13-2
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ static SpatialOS()
5050
};
5151
}
5252

53-
internal static bool ConnectionWasSuccesful { get; set; }
53+
internal static bool ConnectionWasSuccessful { get; set; }
5454

5555
/// <summary>
5656
/// A callback that will be invoked when the deployment list has been retrieved from the Locator.
@@ -691,10 +691,21 @@ internal static void Disconnected(DisconnectOp disconnectOp)
691691
receivedDisconnectOp = disconnectOp;
692692
Disconnecting = true;
693693
}
694+
695+
internal static void SignalApplicationQuit()
696+
{
697+
if (!ConnectionWasSuccessful)
698+
{
699+
receivedDisconnectOp = new DisconnectOp
700+
{
701+
Reason = "An application quit signal was received."
702+
};
703+
}
704+
}
694705

695706
internal static void SignalDisconnection()
696707
{
697-
if (!ConnectionWasSuccesful)
708+
if (!ConnectionWasSuccessful)
698709
{
699710
OnConnectionFailedInternal();
700711
OnConnectionFailedWithReasonInternal();

workers/unity/Assets/Plugins/Improbable/Sdk/Src/Unity/Unity.meta

+9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.

0 commit comments

Comments
 (0)