コード例 #1
0
        protected override Variant _formatConfig(Variant conf)
        {
            instance = this;

            if (conf.ContainsKey("skill"))
            {
                conf["skill"] = GameTools.array2Map(conf["skill"], "id");

                Variant skills = conf["skill"];
                foreach (Variant data in skills.Values)
                {
                    if (data.ContainsKey("Level"))
                    {
                        data["Level"] = GameTools.array2Map(data["Level"], "level");
                    }
                }
            }



            //if (conf.ContainsKey("equip_upgrade"))
            //{
            //    conf["equip_upgrade"] = GameTools.array2Map(conf["equip_upgrade"], "item_id");
            //}
            return(conf);
        }
コード例 #2
0
        protected override Variant _formatConfig(Variant conf)
        {
            SkillConf.instance = this;
            bool flag = conf.ContainsKey("skill");

            if (flag)
            {
                conf["skill"] = GameTools.array2Map(conf["skill"], "id", 1u);
                Variant variant = conf["skill"];
                foreach (Variant current in variant.Values)
                {
                    bool flag2 = current.ContainsKey("Level");
                    if (flag2)
                    {
                        current["Level"] = GameTools.array2Map(current["Level"], "level", 1u);
                    }
                }
            }
            return(conf);
        }