コード例 #1
0
    public override void OnAwake()
    {
        if (!m_isInitialized)
        {
            m_isInitialized = true;

            // Initialize Variables of this NPC
            npcInfo.SetValue(GetComponent <NPCInfo>());
            seeker.SetValue(GetComponent <Seeker>());
            rvoController.SetValue(GetComponent <RVOController>());
            animator.SetValue(gameObject.GetComponentInChildren <Animator>());
        }
        // Get all Target Transforms in the Scene
        List <Transform> targetsTransform = GetComponent <NPCInfo>().patrolWaypoints; //GameInfo.npcPatrolWaypoints;

        waypointTargets.SetValue(targetsTransform);
    }