private void FlyToSkill(int iconId, Vector3 startPos, int equipPos, Action <Vector3> callBack) { CreateNewPage("UI/MainUI/FlyIcon.prefab", iconId, startPos, true, (go) => { EventDispatcher.Instance.DispatchEvent(new Show_UI_Event(UIConfig.MainUI)); var evn = new MainUI_FlyIcon_Event(equipPos, callBack); evn.FlyIcon.From = startPos; evn.FlyIcon.Delay = 0.3f; evn.FlyIcon.Time = 0.5f; evn.FlyIcon.Stay = 0.2f; evn.SetAlphaTo(1.0f, 1.0f); evn.FlyIcon.FlyObject = go; EventDispatcher.Instance.DispatchEvent(new MainUI_FlyIcon2_Event(evn)); }); }
private void FlyToMayaBook(int iconId, Vector3 startPos, Action <Vector3> callBack) { //UI/MainUI/BookPage.prefab CreateNewPage("UI/MainUI/FlyIcon.prefab", iconId, startPos, true, (go) => { var path = Table.GetClientConfig(703); var evn = new MainUI_FlyIcon_Event(path.Value, callBack); evn.FlyIcon.From = startPos; evn.FlyIcon.Delay = 0.2f; evn.FlyIcon.Time = 0.7f; evn.FlyIcon.Stay = 0.1f; evn.SetAlphaTo(1.0f, 0.6f); evn.FlyIcon.UseBezier = true; evn.FlyIcon.UseRotate = true; evn.FlyIcon.FlyObject = go; EventDispatcher.Instance.DispatchEvent(new UIEvent_EraGetAlpha(0.8f, 0.01f, () => { EventDispatcher.Instance.DispatchEvent(new Show_UI_Event(UIConfig.MainUI)); Logger.Debug("...UIEvent_EraGetAlpha ..CallBack"); EventDispatcher.Instance.DispatchEvent(new MainUI_FlyIcon2_Event(evn)); })); }); }