編輯

共用方式為


HitBehaviorDestroyOnSelect Class

Definition

Destroys the game object when selected and optionally plays a sound or animation when destroyed.

public ref class HitBehaviorDestroyOnSelect : UnityEngine::MonoBehaviour
[UnityEngine.AddComponentMenu("Scripts/MRTK/Examples/HitBehaviorDestroyOnSelect")]
[UnityEngine.RequireComponent(typeof(Microsoft.MixedReality.Toolkit.Input.EyeTrackingTarget))]
public class HitBehaviorDestroyOnSelect : UnityEngine.MonoBehaviour
[<UnityEngine.AddComponentMenu("Scripts/MRTK/Examples/HitBehaviorDestroyOnSelect")>]
[<UnityEngine.RequireComponent(typeof(Microsoft.MixedReality.Toolkit.Input.EyeTrackingTarget))>]
type HitBehaviorDestroyOnSelect = class
    inherit MonoBehaviour
Public Class HitBehaviorDestroyOnSelect
Inherits MonoBehaviour
Inheritance
UnityEngine.MonoBehaviour
HitBehaviorDestroyOnSelect
Attributes
UnityEngine.AddComponentMenuAttribute UnityEngine.RequireComponentAttribute

Constructors

HitBehaviorDestroyOnSelect()

Methods

TargetSelected()

Applies to