mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-09 04:06:53 +08:00
[unity] Disable baking with new prefab system.
This commit is contained in:
parent
54dd3825f7
commit
bd342bc10d
@ -3,6 +3,11 @@ using System.Collections.Generic;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
|
|
||||||
|
#if UNITY_2018_3 || UNITY_2019
|
||||||
|
#define NEW_PREFAB_SYSTEM
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
namespace Spine.Unity.Editor {
|
namespace Spine.Unity.Editor {
|
||||||
|
|
||||||
using Editor = UnityEditor.Editor;
|
using Editor = UnityEditor.Editor;
|
||||||
@ -11,6 +16,7 @@ namespace Spine.Unity.Editor {
|
|||||||
public class SkeletonBakingWindow : EditorWindow {
|
public class SkeletonBakingWindow : EditorWindow {
|
||||||
const bool IsUtilityWindow = true;
|
const bool IsUtilityWindow = true;
|
||||||
|
|
||||||
|
#if !NEW_PREFAB_SYSTEM
|
||||||
[MenuItem("CONTEXT/SkeletonDataAsset/Skeleton Baking", false, 5000)]
|
[MenuItem("CONTEXT/SkeletonDataAsset/Skeleton Baking", false, 5000)]
|
||||||
public static void Init (MenuCommand command) {
|
public static void Init (MenuCommand command) {
|
||||||
var window = EditorWindow.GetWindow<SkeletonBakingWindow>(IsUtilityWindow);
|
var window = EditorWindow.GetWindow<SkeletonBakingWindow>(IsUtilityWindow);
|
||||||
@ -20,6 +26,7 @@ namespace Spine.Unity.Editor {
|
|||||||
window.skeletonDataAsset = command.context as SkeletonDataAsset;
|
window.skeletonDataAsset = command.context as SkeletonDataAsset;
|
||||||
window.Show();
|
window.Show();
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
public SkeletonDataAsset skeletonDataAsset;
|
public SkeletonDataAsset skeletonDataAsset;
|
||||||
[SpineSkin(dataField:"skeletonDataAsset")]
|
[SpineSkin(dataField:"skeletonDataAsset")]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user