Example #1
0
        private void loadMeshSets(ConfigNode[] nodes)
        {
            meshSets = new Dictionary <string, SWVariant>();
            SWVariant variant;

            for (int index = 0; index < nodes.Length; index++)
            {
                variant = new SWVariant();
                variant.Load(nodes[index]);
                if (!meshSets.ContainsKey(variant.name))
                {
                    meshSets.Add(variant.name, variant);
                }
            }
        }
Example #2
0
        private void loadVariantConfigs(ConfigNode node)
        {
            variants = new List <SWVariant>();
            if (!node.HasNode("VARIANT"))
            {
                return;
            }
            ConfigNode[] variantNodes = node.GetNodes("VARIANT");
            SWVariant    variant;

            for (int index = 0; index < variantNodes.Length; index++)
            {
                variant = new SWVariant();
                variant.Load(variantNodes[index]);
                if (!string.IsNullOrEmpty(variant.name))
                {
                    variants.Add(variant);
                }
            }
        }