Skip to content

Commit

Permalink
fix: workaround for #70
Browse files Browse the repository at this point in the history
  • Loading branch information
mob-sakai committed Feb 17, 2020
1 parent 0a43740 commit 4bbcc33
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 2 deletions.
19 changes: 19 additions & 0 deletions Packages/UIParticle/Scripts/Editor/OpenSesamePortable.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#if !OPEN_SESAME && UNITY_EDITOR
using UnityEditor;
using UnityEditor.Compilation;

namespace Coffee.OpenSesame
{
[InitializeOnLoad]
internal class Portable
{
static Portable()
{
var assemblyName = typeof(Portable).Assembly.GetName().Name;
var asmdefPath = CompilationPipeline.GetAssemblyDefinitionFilePathFromAssemblyName(assemblyName);
UnityEngine.Debug.LogFormat("<b>Request to recompile: {0} ({1})</b>", assemblyName, asmdefPath);
AssetDatabase.ImportAsset(asmdefPath);
}
}
}
#endif
11 changes: 11 additions & 0 deletions Packages/UIParticle/Scripts/Editor/OpenSesamePortable.cs.meta

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

4 changes: 3 additions & 1 deletion Packages/UIParticle/Scripts/Editor/UIParticleEditor.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using UnityEditor;
#if OPEN_SESAME
using UnityEditor;
using UnityEditor.UI;
using UnityEngine;
using System.Collections.Generic;
Expand Down Expand Up @@ -278,3 +279,4 @@ void OnSceneGUI()
}
}
}
#endif
4 changes: 3 additions & 1 deletion Packages/UIParticle/Scripts/Editor/UIParticleMenu.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#if !UNITY_2019_1_OR_NEWER
#if OPEN_SESAME
#if !UNITY_2019_1_OR_NEWER
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
Expand All @@ -22,4 +23,5 @@ static void ImportSample()
}
}
}
#endif
#endif

0 comments on commit 4bbcc33

Please sign in to comment.