Skip to content

Commit

Permalink
fix(SDKManager): SDK Setup unloading
Browse files Browse the repository at this point in the history
Whenever the SDK Manager was disabled it unloaded the currently
used SDK Setup. This is problematic when the current scene is
changed. This fix makes sure to only unload the SDK Setup in
case the SDK Manager is not set to persist on load.
  • Loading branch information
trumpetx committed Jun 10, 2017
1 parent c2fa639 commit 841432c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Assets/VRTK/Scripts/Utilities/SDK/VRTK_SDKManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -572,7 +572,10 @@ private void OnEnable()

private void OnDisable()
{
UnloadSDKSetup();
if (_instance == this && !persistOnLoad)
{
UnloadSDKSetup();
}
}

private void CreateInstance()
Expand Down

0 comments on commit 841432c

Please sign in to comment.