void Awake()
    {
        //get Suimono Specific Objects
        suimonoGameObject = GameObject.Find("SUIMONO_Module");
        if (suimonoGameObject != null)
        {
            suimonoModuleObject = suimonoGameObject.GetComponent <Suimono.Core.SuimonoModule>();
        }

        targetPosition = cameraTarget.position;
        targetRotation = cameraTarget.rotation;

        if (cameraTarget != null)
        {
            targetAnimator = cameraTarget.gameObject.GetComponent <sui_demo_animCharacter>();
        }

        if (buoyancyTarget != null)
        {
            buoyancyObject = buoyancyTarget.GetComponent <Suimono.Core.fx_buoyancy>();
        }

        MC = this.gameObject.GetComponent <sui_demo_ControllerMaster>() as sui_demo_ControllerMaster;
        IC = this.gameObject.GetComponent <sui_demo_InputController>() as sui_demo_InputController;
    }
    void Awake()
    {
        //get Suimono Specific Objects
        suimonoGameObject = GameObject.Find("SUIMONO_Module");
        if (suimonoGameObject != null)
        {
            suimonoModuleObject = suimonoGameObject.GetComponent <Suimono.Core.SuimonoModule>();
        }

        targetPosition = cameraTarget.position;
        targetRotation = cameraTarget.rotation;

        MC = this.gameObject.GetComponent <sui_demo_ControllerMaster>() as sui_demo_ControllerMaster;
        IC = this.gameObject.GetComponent <sui_demo_InputController>() as sui_demo_InputController;
    }
Ejemplo n.º 3
0
 void Start()
 {
     CM = GameObject.Find("_CONTROLLER").GetComponent <sui_demo_ControllerMaster>();
 }