| | |
| | | [SerializeField] UIAlphaTween alphaTween;
|
| | | [SerializeField] List<Vector2> startPos = new List<Vector2>();
|
| | | [SerializeField] List<Vector2> endPos = new List<Vector2>();
|
| | | [Header("最小时间间隔")] [SerializeField] int minDuration = 3;
|
| | | [Header("最大时间间隔")] [SerializeField] int maxDuration = 6;
|
| | |
|
| | | ItemTipsModel tipsModel { get { return ModelCenter.Instance.GetModel<ItemTipsModel>(); } }
|
| | | WishingPoolModel wishingModel { get { return ModelCenter.Instance.GetModel<WishingPoolModel>(); } }
|
| | |
| | | alphaTween.to = 1;
|
| | | alphaTween.SetStartState();
|
| | | handImg.gameObject.SetActive(true);
|
| | | int offset = wishingModel.handStartIndex % 4 - wishingModel.handEndIndex;
|
| | | positionTween.duration = Mathf.Max(2, Mathf.Abs(offset));
|
| | | int offset = Mathf.Abs(wishingModel.handStartIndex % 4 - wishingModel.handEndIndex);
|
| | | if(offset < minDuration)
|
| | | {
|
| | | offset = minDuration;
|
| | | }
|
| | | else if(offset > maxDuration)
|
| | | {
|
| | | offset = maxDuration;
|
| | | }
|
| | | positionTween.duration = offset;
|
| | | alphaTween.Play();
|
| | | positionTween.Play(() =>
|
| | | {
|
| | |
| | | #region 活动逻辑
|
| | | private void OperationEndEvent(Operation type, int state)
|
| | | {
|
| | | if(type == Operation.WishingWellInfo && state == 1)
|
| | | if(type == Operation.WishingWellInfo && state == 0)
|
| | | {
|
| | | UpdateActivityState();
|
| | | }
|