Exemplo n.º 1
0
    void Start()
    {
        templates    = GameObject.FindGameObjectWithTag("Rooms").GetComponent <RoomTemplates>();
        templateRoom = templates.templateRoom;
        tunnelRoom   = templates.tunnelRoom;

        GameManager = GameObject.Find("GameManager").GetComponent <GameManager>();

        myIndex = templates.GetRoomSpawnerIndex();
        myRoomsDestroyer.GetComponent <Destroyer>().myIndex = myIndex;

        foreach (var checker in myRoomCheckers)
        {
            validSpawnRoomExits.Add(checker.GetName());
        }
    }