void Start()
    {
        if (cam == null)
        {
            Debug.LogError("working");
            this.enabled = false;
        }

        weaponManager = GetComponent <weaponManager>();
    }
예제 #2
0
    private void Start()
    {
        if (cam == null)
        {
            Debug.LogError("Camera missing");
            this.enabled = false;
        }

        WeaponManager = GetComponent <weaponManager>();
    }
예제 #3
0
    // Start is called before the first frame update
    void Awake()
    {
        ac = GetComponent <ActorController>();
        GameObject model = ac.model;

        //GameObject npcSensor = transform.Find("npcSensor").gameObject;
        if (camIdentify.GetComponent <cameraController>().isAI == false)
        {
            GameObject sensor = transform.Find("sensor").gameObject;
            bm = Bind <BattleManager>(sensor);
        }
        else if (camIdentify.GetComponent <cameraController>().isAI)
        {
            GameObject sensor = transform.Find("npcSensor").gameObject;
            bm = Bind <BattleManager>(sensor);
        }


        wm = Bind <weaponManager>(model);
        sm = Bind <StateManager>(gameObject);
    }
예제 #4
0
 private void Awake()
 {
     manager = this;
 }
예제 #5
0
 void Awake() {
     wm = this;
 }