From 77a42df9c7ac6a65bc261123d6a772228e685d39 Mon Sep 17 00:00:00 2001 From: mafiesto4 Date: Sun, 2 Sep 2018 12:32:13 +0200 Subject: [PATCH] Plugins tweaks --- FlaxEditor/API/Static/GameCooker.cs | 2 +- FlaxEditor/Windows/PluginsWindow.cs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/FlaxEditor/API/Static/GameCooker.cs b/FlaxEditor/API/Static/GameCooker.cs index e7eb8b75..72f0b097 100644 --- a/FlaxEditor/API/Static/GameCooker.cs +++ b/FlaxEditor/API/Static/GameCooker.cs @@ -217,7 +217,7 @@ internal static void Internal_CanDeployPlugin(BuildPlatform buildPlatform, Assem // Check if plugins supports the given platform var platform = GetPlatformType(buildPlatform); - if (!desc.SupportedPlatforms.Contains(platform)) + if (desc.SupportedPlatforms != null && !desc.SupportedPlatforms.Contains(platform)) { Debug.Write(LogType.Log, "Skip game plugin from assembly " + assembly.FullName); result = false; diff --git a/FlaxEditor/Windows/PluginsWindow.cs b/FlaxEditor/Windows/PluginsWindow.cs index 3df5a1dd..7195613c 100644 --- a/FlaxEditor/Windows/PluginsWindow.cs +++ b/FlaxEditor/Windows/PluginsWindow.cs @@ -90,7 +90,7 @@ public PluginEntry(Plugin plugin, CategoryEntry category, ref PluginDescription else if (desc.IsBeta) versionString = "BETA "; versionString += "Version "; - versionString += desc.Version.ToString(); + versionString += desc.Version != null ? desc.Version.ToString() : "1.0"; var versionLabel = new Label(Width - 140 - margin, margin, 140, 14) { HorizontalAlignment = TextAlignment.Far, @@ -104,9 +104,9 @@ public PluginEntry(Plugin plugin, CategoryEntry category, ref PluginDescription if (!string.IsNullOrEmpty(desc.AuthorUrl)) url = desc.AuthorUrl; else if (!string.IsNullOrEmpty(desc.HomepageUrl)) - url = desc.AuthorUrl; + url = desc.HomepageUrl; else if (!string.IsNullOrEmpty(desc.RepositoryUrl)) - url = desc.AuthorUrl; + url = desc.RepositoryUrl; versionLabel.Font.Font.WaitForLoaded(); var font = versionLabel.Font.GetFont(); var authorWidth = font.MeasureText(desc.Author).X + 8;