Exemple #1
0
    public void Setup(GridPoint gridPos, Vector3 worldPos)
    {
        IsEmpty            = true;
        this.gridPos       = gridPos;
        transform.position = worldPos;
        levelLayoutManager lm = GameObject.FindObjectOfType <levelLayoutManager>();

        lm.Tiles.Add(gridPos, this);
    }
Exemple #2
0
 void Start()
 {
     lm       = GameObject.FindObjectOfType <levelLayoutManager>();
     animator = this.GetComponent <Animator>();
     foreach (var item in lm.nodes)
     {
         var spe = new GridPoint(item.x, item.y);
         waypoints.Add(lm.Tiles[spe].gameObject);
     }
 }