19 lines
494 B
C#
19 lines
494 B
C#
![]() |
using UnityEngine;
|
||
|
using UnityEngine.UI;
|
||
|
|
||
|
namespace Prefab
|
||
|
{
|
||
|
public class TemporaryAnimatorImageUI:TemporaryAnimator
|
||
|
{
|
||
|
public UIImageAnimator imageAnimator;
|
||
|
|
||
|
public void Init(Sprite[] sprite,float fps=3)
|
||
|
{
|
||
|
if (imageAnimator == null)
|
||
|
imageAnimator = GetComponentInChildren<UIImageAnimator>();
|
||
|
if (!imageAnimator) return;
|
||
|
imageAnimator.SetSprites(sprite);
|
||
|
imageAnimator.SetFPS(fps);
|
||
|
}
|
||
|
}
|
||
|
}
|