Exemplo n.º 1
0
        private void LoadRookieMa()
        {
            for (int _i = 0; _i < m_maPosList.Length; ++_i)
            {
                GameObject _rookieMa = (GameObject)GameManager.ResManager.LoadPrefabSync(PlayerPrefabPath, "woHorse", typeof(GameObject));
                _rookieMa.transform.SetParent(GameManager.GameManagerObj.GetComponent <GameManager>().SceneLayer);
                Follower _follower = _rookieMa.GetComponent <Follower>();
                _follower.SetType(FollowerType.MA);
                _follower.SetPosition(m_maPosList[_i].m_row, m_maPosList[_i].m_col);

                m_followList.Add(_rookieMa);
            }
        }
Exemplo n.º 2
0
        private void DelayLoadRookieXiang(EventArgs args)
        {
            for (int _i = 0; _i < m_xiangPosList.Length; ++_i)
            {
                GameObject _rookieXiang = (GameObject)GameManager.ResManager.LoadPrefabSync(PlayerPrefabPath, "woXiang", typeof(GameObject));
                _rookieXiang.transform.SetParent(GameManager.GameManagerObj.GetComponent <GameManager>().SceneLayer);
                Follower _follower = _rookieXiang.GetComponent <Follower>();
                _follower.SetType(FollowerType.XIANG);
                _follower.SetPosition(m_xiangPosList[_i].m_row, m_xiangPosList[_i].m_col);
                m_followList.Add(_rookieXiang);
            }
            long _id = TimerManager.StartTimer(1000, false, null, DelayActiveXiangBtn, 0);

            m_timerIdList.Add(_id);
        }