Ejemplo n.º 1
0
    public void InitInfo(int id)
    {
        AssetList _assetList = UserDataSettings.Instance.AssetList[id];
        Type      curType    = _assetList.GetType();

        FieldInfo[] Fields = curType.GetFields();
        for (int i = 0; i < Fields.Length; i++)
        {
            if (Fields[i].Name == "Status" || Fields[i].Name == "GameObjectName" || Fields[i].Name == "posX" || Fields[i].Name == "posY" ||
                Fields[i].Name == "posZ")
            {
                continue;
            }

            textInfo.Find(x => x.name == Fields[i].Name).text = Fields[i].GetValue(_assetList).ToString();
        }
    }