public Tween LoadTween(DoTweenType type, Transform trans) { Tween _tw = null; switch (type) { case DoTweenType.PanelNoraml: _tw = DoTweenRoot.TransformMoveByTw(trans, 0.5f, new Vector2(0, 1000), new Vector2(0, 0)); break; case DoTweenType.IptMove: _tw = DoTweenRoot.TransformMoveByTw(trans, 0.5f, trans.localPosition, new Vector2(trans.localPosition.x + 395, trans.localPosition.y)); break; case DoTweenType.InfoBoxAni: _tw = DoTweenRoot.TransformMoveByTw(trans, 1f, new Vector2(-1390, 0), new Vector2(-160, 0)); break; case DoTweenType.TransRotate: _tw = DoTweenRoot.TransformRotaByTw(trans, 1f, new Vector3(0, 0, 0), new Vector3(0, 0, 180)); break; default: break; } return(_tw); }
public override void ReqOpenWnd() { SetActive(gameObject, true); Sequence seq = DOTween.Sequence(); seq = DoTweenRoot.GetColorSeq(img, 0.3f); seq.PlayForward(); seq.OnComplete(() => { SetActive(gameObject, false); }); }