Esempio n. 1
0
        /// <summary>
        /// 设置所有灯的关注对象为keyMan
        /// </summary>
        /// <param id="dm"></param>
        void UpdateDancerStatus(int i, DancerDataModel dm)
        {
            DancerEntity entity = utilsEntity.
                                  GetEntity <DancerEntity>(dm.gameObject);

            entity.isDancing = true;
        }
Esempio n. 2
0
        private void Update()
        {
            DancerEntity entity = utilsEntity.GetEntity <DancerEntity>(gameObject);

            if (entity.isDancing)
            {
                int speed = Random.Range(1, 3);
                transform.Rotate(Vector3.up * speed * Time.deltaTime, speed);
            }
        }