private void SpawnDesk(DeskAsset asset, Node node)
        {
            DeskView view = Object.Instantiate(asset.ViewPrefab);
            DeskData data = new DeskData(asset, node);

            data.AttachView(view);
            Game.Player.DeskDatas.Add(data);
            Debug.Log("Spawned Desk");
            Debug.Log(view.transform.position);
            //Game.Player.TurretSpawned(data);

            //node.IsOccupied = true; // TryOccupy()
            //m_Grid.UpdatePathfinding();
        }
示例#2
0
 public DeskData(DeskAsset mAsset, Node node)
 {
     m_Asset = mAsset;
     m_Node  = node;
     m_Skill = mAsset.Skill;
 }