/// <summary> /// 主线任务引导 /// </summary> /// <param name="button"></param> private void OnMainTaskButtonClick(GameObject button) { if (GuideModel.Instance.IsShowGuide) { return; //触发了指引则不响应任务引导 } int needLevel = StringUtils.GetStringToInt(_taskMode.CurrentMainTaskVo.SysTaskVo.level)[0]; if (needLevel > MeVo.instance.Level) { MessageManager.Show("请升级到" + needLevel + "级再来接取"); return; } string trace = TaskUtil.GetTraceInfo(_taskMode.CurrentMainTaskVo); string[] items = trace.Split('.'); uint taskTargetMapId = uint.Parse(items[1]); if (taskTargetMapId == AppMap.Instance.mapParser.MapId) { MapMode.Instance.NeedGuideMainTask = false; BaseDisplay display = TaskUtil.GetTaskDisplay(trace); MoveTo(display); } else { MapMode.Instance.NeedGuideMainTask = true; CopyControl.Instance.AutoChangeWorld(taskTargetMapId); } vp_Timer.CancelAll("ShowTaskGuide"); _taskGuide.SetActive(false); }
/// <summary> /// 支线任务引导 /// </summary> /// <param name="button"></param> private void OnSubTaskButtonClick(GameObject button) { string trace = TaskUtil.GetTraceInfo(_taskMode.CurrentSubTaskVo); BaseDisplay display = TaskUtil.GetTaskDisplay(trace); MoveTo(display); }