예제 #1
0
        public static System.Collections.Generic.Dictionary <int, Config.ConfHeroSkin> Read(IBinaryReader o, System.Collections.Generic.Dictionary <int, Config.ConfHeroSkin> d)
        {
            if (o.ReadBoolean() == false)
            {
                return(null);
            }

            int size = o.ReadInt32();

            if (d == null)
            {
                d = new System.Collections.Generic.Dictionary <int, Config.ConfHeroSkin>(size, Int32EqualityComparer.Instance);
            }
            else
            {
                d.Clear();
            }
            for (int i = 0; i < size; ++i)
            {
                int key = o.ReadInt32();
                Config.ConfHeroSkin value = ConfHeroSkinSerializer.Read(o, default(Config.ConfHeroSkin) as Config.ConfHeroSkin);
                d.Add(key, value);
            }
            return(d);
        }