protected override void OnFocusExit(GameObject obj, FocusArgs args) { if (!ManipulatingNow) { //TODO hide handle mesh } base.OnFocusExit(obj, args); }
/// <summary> /// FocusManager SendMessage("FocusEnter") receiver. /// </summary> public void FocusEnter(FocusArgs args) { if (!m_disabled && args.CurNumFocusers == 1) { ButtonStateEnum newState = Veil.Instance.HandVisible ? ButtonStateEnum.Targeted : ButtonStateEnum.ObservationTargeted; this.OnStateChange(newState); } }
/// <summary> /// Toggle targets active when in focus /// </summary> protected override void OnFocusEnter(GameObject obj, FocusArgs args) { // First check that the obj is ours and we have targets if (IsInteractible(obj) && Targets.Count > 0) { foreach (GameObject target in Targets) { target.SetActive(true); } } }
protected void FocusExit(FocusArgs args) { if (args.CurNumFocusers == 0) { bGazing = false; if (RequireGaze) { StopCoroutine("SelectHoldCheck"); } } }
/// <summary> /// Toggle targets inactive when out of focus /// </summary> protected override void OnFocusExit(GameObject obj, FocusArgs args) { // First check that the obj is ours and we have targets if (IsInteractible(obj) && Targets.Count > 0 && args.CurNumFocusers == 0) { foreach (GameObject target in Targets) { target.SetActive(false); } } }
public void FocusEnter(FocusArgs args) { switch (Behavior) { default: break; case ToggleBehaviorEnum.OnFocus: State = !State; break; } }
// When if gaze then stop animation if gaze ended protected void FocusExit(FocusArgs args) { if (args.CurNumFocusers == 0) { Animation targetAnim = TargetObject.GetComponent <Animation>(); if (AnimCondition == StartType.OnGaze && TargetObject != null && targetAnim != null) { targetAnim.Stop(AnimName); bPlaying = false; } } }
/// <summary> /// FocusManager SendMessage("FocusExit") receiver. /// </summary> public void FocusExit(FocusArgs args) { if (!m_disabled && args.CurNumFocusers == 0) { if (ButtonState == ButtonStateEnum.Pressed) { DoButtonCancelled(); } ButtonStateEnum newState = Veil.Instance.HandVisible ? ButtonStateEnum.Interactive : ButtonStateEnum.Observation; if (RequireGaze || ButtonState != ButtonStateEnum.Pressed) { this.OnStateChange(newState); } } }
protected override void OnFocusEnter(GameObject obj, FocusArgs args) { base.OnFocusEnter(obj, args); switch (obj.name) { case "Easy": difficultyMenu.GetComponent <SimpleMenuCollection>().Subtitle = "Lots of fuel and a forgiving landing speed."; break; case "Medium": difficultyMenu.GetComponent <SimpleMenuCollection>().Subtitle = "Moderate fuel and a challenging landing speed."; break; case "Hard": difficultyMenu.GetComponent <SimpleMenuCollection>().Subtitle = "Very little fuel and no room for error!"; break; } }
protected override void OnFocusEnter(GameObject obj, FocusArgs args) { base.OnFocusEnter(obj, args); switch (obj.name) { case "GamepadInput": selectControlsMenu.GetComponent <SimpleInteractableMenuCollection>().SubtitleText = "Use a gamepad to control the lander"; break; case "HololensInput": selectControlsMenu.GetComponent <SimpleInteractableMenuCollection>().SubtitleText = "Use fingers to control the lander"; break; default: // Do nothing break; } }
protected void FocusEnter(FocusArgs args) { if (args.CurNumFocusers == 1) { if (AnimState == AnimStateEnum.Proximity) { return; } if (Veil.Instance.HandVisible) { SetState(AnimStateEnum.Interactive); } else { SetState(AnimStateEnum.ObservationTargeted); } } }
protected void FocusExit(FocusArgs args) { if (args.CurNumFocusers == 0) { if (AnimState == AnimStateEnum.Proximity) { return; } if (Veil.Instance.HandVisible) { SetState(AnimStateEnum.Observation); } else { SetState(AnimStateEnum.Observation); } } }
// When if set to gaze trigger then play anim when gazing protected void FocusEnter(FocusArgs args) { if (args.CurNumFocusers == 1) { Animation targetAnim = TargetObject.GetComponent <Animation>(); if (AnimCondition == StartType.OnGaze && TargetObject != null && targetAnim != null) { var time = BlendTime; if (time < 0.001f) { targetAnim.Play(AnimName, AnimPlayMode); } else { targetAnim.CrossFade(AnimName, time, AnimPlayMode); } bPlaying = true; } } }
// ReSharper disable once RedundantOverriddenMember protected override bool OnFocus(SciterElement element, FocusArgs args) { //Console.WriteLine($"{args.Event} | {args.Cancel} | {args.IsMouseClick}"); return(base.OnFocus(element, args)); }
protected override void OnFocusEnter(GameObject obj, FocusArgs args) { txt.text = obj.name + " : OnFocusEnter"; base.OnFocusEnter(obj, args); }
/// <summary> /// FocusManager SendMessage("FocusExit") receiver. /// </summary> public void FocusExit(FocusArgs args) { hasFocus = false; }
/// <summary> /// FocusManager SendMessage("FocusEnter") receiver. /// </summary> public void FocusEnter(FocusArgs args) { hasFocus = true; }
protected override void OnFocusExit(GameObject obj, FocusArgs args) { base.OnFocusExit(obj, args); hasFocus = false; lastFocusExit = Time.time; }
protected override void OnFocusExit(GameObject obj, FocusArgs args) { //txt.text = obj.name + " : OnFocusExit"; base.OnFocusExit(obj, args); }
protected override void OnFocusExit(GameObject obj, FocusArgs args) { base.OnFocusExit(obj, args); }
protected override void OnFocusEnter(GameObject obj, FocusArgs args) { base.OnFocusEnter(obj, args); hasFocus = true; lastFocusExit = Mathf.NegativeInfinity; }
protected void FocusEnter(FocusArgs args) { bScaling = true; }
protected void FocusExit(FocusArgs args) { args.Focuser.SetCursorActive(true); }
protected void FocusEnter(FocusArgs args) { args.Focuser.SetCursorActive(false); }
protected virtual void OnFocusExit(GameObject obj, FocusArgs args) { }