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

Commit

Permalink
Merge pull request #17 from spatialos/2.0.0
Browse files Browse the repository at this point in the history
Upgrade to use Unity SDK 2.0.0
  • Loading branch information
oblm authored Jun 12, 2018
2 parents 72206d6 + 29e5ad1 commit fe31599
Show file tree
Hide file tree
Showing 46 changed files with 24 additions and 100 deletions.
4 changes: 2 additions & 2 deletions spatialos.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "your_project_name_here",
"project_version": "1.0.0",
"sdk_version": "13.0.0",
"sdk_version": "13.0.1",
"dependencies": [
{"name": "standard_library", "version": "13.0.0"}
{"name": "standard_library", "version": "13.0.1"}
]
}
2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/Island_01.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/Island_02.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/Island_03.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/Island_04.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/LargeFish.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/PirateShip.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/PlayerCreator.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/PlayerShip.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/SmallFish.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions workers/unity/Assets/EntityPrefabs/Whale.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -409,11 +409,7 @@ private static void SwapInList<T>(IList<T> list, int indexA, int indexB)

private static IDisposable IndentLevelScope(int increment)
{
#if UNITY_2017_3_OR_NEWER
return new EditorGUI.IndentLevelScope(increment);
#else
return new FallbackIndentLevelScope(increment);
#endif
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,7 @@ namespace Improbable.Unity.MinimalBuildSystem.Configuration
{
public class WorkerBuildData
{
internal const BuildTarget OSXBuildTarget =
#if UNITY_2017_3_OR_NEWER
BuildTarget.StandaloneOSX;
#else
BuildTarget.StandaloneOSXIntel64;
#endif
internal const BuildTarget OSXBuildTarget = BuildTarget.StandaloneOSX;

private readonly WorkerPlatform workerPlatform;
private readonly BuildTarget buildTarget;
Expand Down
Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,7 @@ internal static PlayerBuildConfiguation Generate()
Targets = new List<string>
{
BuildTarget.StandaloneWindows.ToString(),
#if UNITY_2017_3_OR_NEWER
BuildTarget.StandaloneOSX.ToString()
#else
BuildTarget.StandaloneOSXIntel64.ToString()
#endif
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
using Improbable.Unity.EditorTools.Util;
using Improbable.Unity.Util;
using UnityEditor;
#if UNITY_2018_1_OR_NEWER
using UnityEditor.Build.Reporting;
#endif
using UnityEngine;

namespace Improbable.Unity.EditorTools.Build
Expand Down Expand Up @@ -51,15 +54,6 @@ private static BuildTarget ToRuntimePlatform(string platform)
if (platform.ToLower() != "current")
{
var value = (BuildTarget) Enum.Parse(typeof(BuildTarget), platform);
#if UNITY_2017_3_OR_NEWER
#pragma warning disable 618
if (value == BuildTarget.StandaloneOSXIntel64)
{
Debug.LogWarningFormat("{0} is deprecated and will be removed. Please update {1} to use {2} instead.", BuildTarget.StandaloneOSXIntel64, UnityPlayerBuilders.PlayerConfigurationFilePath, BuildTarget.StandaloneOSX);
value = BuildTarget.StandaloneOSX;
}
#pragma warning restore 618
#endif
return value;
}

Expand All @@ -73,11 +67,7 @@ internal static BuildTarget CurrentPlatform()
case RuntimePlatform.WindowsEditor:
return BuildTarget.StandaloneWindows;
case RuntimePlatform.OSXEditor:
#if UNITY_2017_3_OR_NEWER
return BuildTarget.StandaloneOSX;
#else
return BuildTarget.StandaloneOSXIntel64;
#endif
case RuntimePlatform.LinuxEditor:
return BuildTarget.StandaloneLinux64;
default:
Expand Down Expand Up @@ -120,11 +110,7 @@ internal string AssemblyDirectory
{
switch (BuildTarget)
{
#if UNITY_2017_3_OR_NEWER
case BuildTarget.StandaloneOSX:
#else
case BuildTarget.StandaloneOSXIntel64:
#endif
{
return PathUtil.Combine(PackagePath, string.Format("{0}.app", PackageName), "Contents", "Resources", "Data", "Managed");
}
Expand Down Expand Up @@ -202,11 +188,7 @@ private static PlatformData CreatePlatformData(BuildTarget buildTarget)
return new PlatformData("Managed", "Windows", "_Data", ".exe");
case BuildTarget.StandaloneWindows64:
return new PlatformData("Managed", "Windows", "_Data", ".exe");
#if UNITY_2017_3_OR_NEWER
case BuildTarget.StandaloneOSX:
#else
case BuildTarget.StandaloneOSXIntel64:
#endif
return new PlatformData("Contents/Data/Managed", "Mac", ".app", "");
case BuildTarget.StandaloneLinux64:
return new PlatformData("Managed", "Linux", "_Data", "");
Expand All @@ -228,12 +210,19 @@ internal void BuildPlayer()

var playerOptions = new BuildPlayerOptions { target = BuildTarget, locationPathName = tempExecutablePath, options = options, scenes = scenes };
var buildErrorMessage = BuildPipeline.BuildPlayer(playerOptions);
#if UNITY_2018_1_OR_NEWER
if (buildErrorMessage.summary.result != BuildResult.Succeeded)
{
throw new ApplicationException(string.Format("Failed to build player {0} due to {1} errors", BuildConfigComment,
buildErrorMessage.summary.totalErrors));
}
#else
if (!string.IsNullOrEmpty(buildErrorMessage))
{
throw new ApplicationException(string.Format("Failed to build player {0} due to {1}", BuildConfigComment,
buildErrorMessage));
}

#endif
Debug.LogFormat("Built player {0} into {1}", BuildConfigComment, PackagePath);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ namespace Improbable.Unity.EditorTools
[InitializeOnLoad]
public class SpatialOsWindow : EditorWindow
{
private const string MinVersion = "5.6.0";
private const string MaxVersion = "2017.3.0";
private const string MinVersion = "2017.3.0";
private const string MaxVersion = "2018.1.3";

private static SharedGuiContent sharedContent;
private static string versionMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,7 @@ public class EntityPrefabExporter
{
{ BuildTarget.StandaloneWindows, Platform.BuildPlatform.Windows },
{ BuildTarget.StandaloneWindows64, Platform.BuildPlatform.Windows },
#if UNITY_2017_3_OR_NEWER
{ BuildTarget.StandaloneOSX, Platform.BuildPlatform.OSX },
#else
{ BuildTarget.StandaloneOSXIntel, Platform.BuildPlatform.OSX },
{ BuildTarget.StandaloneOSXIntel64, Platform.BuildPlatform.OSX },
{ BuildTarget.StandaloneOSXUniversal, Platform.BuildPlatform.OSX },
#endif
{ BuildTarget.StandaloneLinux, Platform.BuildPlatform.Linux },
{ BuildTarget.StandaloneLinux64, Platform.BuildPlatform.Linux },
{ BuildTarget.iOS, Platform.BuildPlatform.iOS }
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file modified workers/unity/Improbable/bin/CodeGenerator.dll
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/Improbable.TextTemplating.dll
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/Mono.TextTemplating.dll
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/Newtonsoft.Json.dll
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/UnityCodeGenerator.exe
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/windows/clean.exe
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/windows/unity-csharp-invoker.exe
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/windows/unity-invoker.exe
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/windows/unity-mono-invoker.exe
100644 → 100755
Empty file.
Empty file modified workers/unity/Improbable/bin/windows/unity-zip.exe
100644 → 100755
Empty file.

0 comments on commit fe31599

Please sign in to comment.