コード例 #1
0
    private void Awake()
    {
        var blood = GetComponent <BloodParticleSystem>();

        if (blood != null)
        {
            bloodParticleSystem = blood;
        }

        var copyMotion = GetComponent <CopyMotion>();

        if (copyMotion != null)
        {
            isCopyMotionTarget = true;
            AddScriptToChild(transform);
        }
        else
        {
            AddScript(transform);
            AddScriptToChild(transform);
        }

        var interactive = GetComponent <XRGrabInteractable>();

        if (interactive != null)
        {
            _interactable  = interactive;
            isInteractable = true;
        }
    }
コード例 #2
0
 private void Awake()
 {
     Instance           = this;
     meshParticleSystem = GetComponent <MeshParticleSystem>();
     singleList         = new List <Single>();
 }