baobao
10/12/2017 - 1:12 PM

[WIP]NGUIのDOTween対応したエクステンション

[WIP]NGUIのDOTween対応したエクステンション

using DG.Tweening;

public static  class DOTweenNGUIExtensions
{
	public static Tweener DOFade (this UIPanel p, float endValue, float duration)
	{
		return DOTween.To (() => p.alpha, x => p.alpha = x, endValue, duration);
	}

	public static Tweener DOFade (this UIWidget p, float endValue, float duration)
	{
		return DOTween.To (() => p.alpha, x => p.alpha = x, endValue, duration);
	}
}