コード例 #1
0
        public static void GetModelPoint(HighEffectData data, out Vector3 localPosition, out Vector3 localRotation)
        {
            localPosition = Vector3.zero;
            localRotation = Vector3.zero;
            SkillUnitData vo = Singleton <SkillUnitDataMgr> .Instance.GetVo(data.unit_id);

            string     model_id   = vo.config.model_id;
            GameObject gameObject = ResourceManager.Load <GameObject>(model_id, true, true, null, 0, false);

            if (gameObject == null)
            {
                Debug.LogError(" GetModelPoint Error : " + model_id);
            }
            localPosition = gameObject.transform.localPosition;
            localRotation = gameObject.transform.localEulerAngles;
        }
コード例 #2
0
 public void ParseTables()
 {
     if (!this.isParseTable)
     {
         Dictionary <string, object> dicByType = BaseDataMgr.instance.GetDicByType <SysSkillUnitVo>();
         if (dicByType == null)
         {
             Debug.LogError("==> SysSkillUnitVo is NULL !!");
             return;
         }
         this.isParseTable = true;
         this._dataVos.Clear();
         Dictionary <string, object> .Enumerator enumerator = dicByType.GetEnumerator();
         while (enumerator.MoveNext())
         {
             KeyValuePair <string, object> current = enumerator.Current;
             string key = current.Key;
             KeyValuePair <string, object> current2 = enumerator.Current;
             SysSkillUnitVo config = current2.Value as SysSkillUnitVo;
             SkillUnitData  value  = new SkillUnitData(key, config);
             this._dataVos.Add(key, value);
         }
     }
 }