예제 #1
0
    // Start is called before the first frame update
    void Start()
    {
        x = N;
        z = N;
        for (int x = 0; x < N; x++)
        {
            for (int z = 0; z < N; z++)
            {
                GameObject tile = Instantiate(Tile, new Vector3(x, y, z), Quaternion.identity);
                tile.transform.parent = transform;
                string tag = (x * 8 + z).ToString();
                Level2.AddTag(tag);
                TilesList.Add(tile);
            }
            z = N;
        }

        for (int i = 0; i < TilesList.Capacity; i++)
        {
            TilesList.ElementAt(i).tag = i.ToString();
        }
    }
예제 #2
0
 // Start is called before the first frame update
 void Start()
 {
     rb = GetComponent <Rigidbody>();
     Level2.AddTag("2");
     tag = "2";
 }
예제 #3
0
 // Start is called before the first frame update
 void Start()
 {
     Level2.AddTag("Box");
     tag = "Box";
 }
예제 #4
0
 // Update is called once per frame
 void Update()
 {
     Level2.AddTag("Box");
     tag = "Box";
 }
예제 #5
0
 // Start is called before the first frame update
 void Start()
 {
     Level2.AddTag("RobotMaterial");
     tag = "RobotMaterial";
 }
예제 #6
0
 // Update is called once per frame
 void Update()
 {
     Level2.AddTag("RobotMaterial");
     tag = "RobotMaterial";
 }
예제 #7
0
 // Start is called before the first frame update
 void Start()
 {
     Level2.AddTag("Inside");
     tag = "Inside";
 }