Skip to content

Commit

Permalink
Merge pull request #22 from ettore3091/master
Browse files Browse the repository at this point in the history
Fixed last commit excluding versions between 5 and 5.3
  • Loading branch information
HandCircus committed Jul 26, 2017
2 parents b50b005 + 3a8fa94 commit a5621a6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ResourceChecker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ int GetBitsPerPixel(TextureFormat format)
return 8;
case TextureFormat.BGRA32:// Format returned by iPhone camera
return 32;
#if !UNITY_5_3_OR_NEWER
#if !UNITY_5 && !UNITY_5_3_OR_NEWER
case TextureFormat.ATF_RGB_DXT1:// Flash-specific RGB DXT1 compressed color texture format.
case TextureFormat.ATF_RGBA_JPG:// Flash-specific RGBA JPG-compressed color texture format.
case TextureFormat.ATF_RGB_JPG:// Flash-specific RGB JPG-compressed color texture format.
Expand Down Expand Up @@ -775,7 +775,7 @@ void CheckResources()
{
#if UNITY_4_6 || UNITY_4_5 || UNITY_4_4 || UNITY_4_3
UnityEditorInternal.AnimatorController ac = anim.runtimeAnimatorController as UnityEditorInternal.AnimatorController;
#elif UNITY_5_3_OR_NEWER
#elif UNITY_5 || UNITY_5_3_OR_NEWER
UnityEditor.Animations.AnimatorController ac = anim.runtimeAnimatorController as UnityEditor.Animations.AnimatorController;
#endif

Expand All @@ -788,7 +788,7 @@ void CheckResources()
#if UNITY_4_6 || UNITY_4_5 || UNITY_4_4 || UNITY_4_3
UnityEditorInternal.StateMachine sm = ac.GetLayer(x).stateMachine;
int cnt = sm.stateCount;
#elif UNITY_5_3_OR_NEWER
#elif UNITY_5 || UNITY_5_3_OR_NEWER
UnityEditor.Animations.AnimatorStateMachine sm = ac.layers[x].stateMachine;
int cnt = sm.states.Length;
#endif
Expand All @@ -798,7 +798,7 @@ void CheckResources()
#if UNITY_4_6 || UNITY_4_5 || UNITY_4_4 || UNITY_4_3
UnityEditorInternal.State state = sm.GetState(i);
Motion m = state.GetMotion();
#elif UNITY_5_3_OR_NEWER
#elif UNITY_5 || UNITY_5_3_OR_NEWER
UnityEditor.Animations.AnimatorState state = sm.states[i].state;
Motion m = state.motion;
#endif
Expand Down Expand Up @@ -928,7 +928,7 @@ void CheckResources()

private static GameObject[] GetAllRootGameObjects()
{
#if !UNITY_5_3_OR_NEWER
#if !UNITY_5 && !UNITY_5_3_OR_NEWER
return UnityEngine.SceneManagement.SceneManager.GetActiveScene().GetRootGameObjects().ToArray();
#else
List<GameObject> allGo = new List<GameObject>();
Expand Down

0 comments on commit a5621a6

Please sign in to comment.