lot's of fixes, fixed animation retargetting, fixed FSM
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEditor;
|
||||
using UnityEditor.Build;
|
||||
using UnityEditor.Build.Reporting;
|
||||
|
||||
namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
{
|
||||
[InitializeOnLoad]
|
||||
public class CrossPlatformInitialize
|
||||
public class CrossPlatformInitialize : IPreprocessBuildWithReport
|
||||
{
|
||||
// Custom compiler defines:
|
||||
//
|
||||
@@ -13,6 +15,8 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
// EDITOR_MOBILE_INPUT : denotes that mobile input should be used in editor, if a mobile build target is selected. (i.e. using Unity Remote app).
|
||||
// MOBILE_INPUT : denotes that mobile input should be used right now!
|
||||
|
||||
public int callbackOrder { get { return 0; } }
|
||||
|
||||
static CrossPlatformInitialize()
|
||||
{
|
||||
var defines = GetDefinesList(buildTargetGroups[0]);
|
||||
@@ -23,6 +27,14 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
}
|
||||
}
|
||||
|
||||
public void OnPreprocessBuild(BuildReport report)
|
||||
{
|
||||
if (report.summary.platform == BuildTarget.iOS)
|
||||
{
|
||||
SetEnabled("MOBILE_INPUT", true, true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
[MenuItem("Mobile Input/Enable")]
|
||||
private static void Enable()
|
||||
@@ -32,7 +44,7 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
{
|
||||
case BuildTarget.Android:
|
||||
case BuildTarget.iOS:
|
||||
case BuildTarget.WSAPlayer:
|
||||
case BuildTarget.WSAPlayer:
|
||||
EditorUtility.DisplayDialog("Mobile Input",
|
||||
"You have enabled Mobile Input. You'll need to use the Unity Remote app on a connected device to control your game in the Editor.",
|
||||
"OK");
|
||||
@@ -90,7 +102,7 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
{
|
||||
BuildTargetGroup.Android,
|
||||
BuildTargetGroup.iOS,
|
||||
BuildTargetGroup.WSA
|
||||
BuildTargetGroup.WSA
|
||||
};
|
||||
|
||||
|
||||
@@ -130,4 +142,4 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector
|
||||
return new List<string>(PlayerSettings.GetScriptingDefineSymbolsForGroup(group).Split(';'));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user