[unity] Fixed a second example component compile error on 2017.2, see commit 9317241. See #2056.

This commit is contained in:
Harald Csaszar 2024-08-21 17:20:19 +02:00
parent 9317241256
commit efdf1d3b41

View File

@ -31,8 +31,8 @@
#define HAS_FORCE_RENDER_OFF
#endif
#if UNITY_2017_2_OR_NEWER
#define HAS_VECTOR_INT
#if UNITY_2018_2_OR_NEWER
#define HAS_GET_SHARED_MATERIALS
#endif
using UnityEngine;
@ -78,10 +78,10 @@ namespace Spine.Unity.Examples {
return;
}
float fadeoutAlpha = fadeoutSecondsRemaining / fadeoutSeconds;
#if HAS_VECTOR_INT
#if HAS_GET_SHARED_MATERIALS
skeletonRenderTexture.color.a = fadeoutAlpha;
#else
Debug.LogError("The SkeletonRenderTexture component requires Unity 2017.2 or newer.");
Debug.LogError("The SkeletonRenderTexture component requires Unity 2018.2 or newer.");
#endif
}
}