public TypeData( string ID, string baseID = null, string typeName = "", string typeColor = "ffffff", string maxMove = "maxstrike", bool combineResistances = false, IEnumerable <string> resistances = null, bool combineWeaknesses = false, IEnumerable <string> weaknesses = null, bool combineImmunities = false, IEnumerable <string> immunities = null, bool combineTags = false, IEnumerable <TypeTag> tags = null, bool combineEffects = false, TypeEffect[] effects = null, EffectDatabase.TypeEff.TypeEffect[] effectsNew = null) { this.ID = ID; this.baseID = baseID; this.typeName = typeName; this.combineResistances = combineResistances; this.resistances = (resistances == null) ? new List <string>() { "" } : new List <string>(resistances); this.combineWeaknesses = combineWeaknesses; this.weaknesses = (weaknesses == null) ? new List <string>() { "" } : new List <string>(weaknesses); this.combineImmunities = combineImmunities; this.immunities = (immunities == null) ? new List <string>() { "" } : new List <string>(immunities); this.combineTags = combineTags; this.tags = (tags == null) ? new HashSet <TypeTag>() : new HashSet <TypeTag>(tags); this.combineEffects = combineEffects; this.effects = new List <TypeEffect>(); if (effects != null) { List <TypeEffect> newEffects = new List <TypeEffect>(); for (int i = 0; i < effects.Length; i++) { newEffects.Add(TypeEffect.Clone(effects[i])); } this.effects = new List <TypeEffect>(newEffects); } this.effectsNew = new List <EffectDatabase.TypeEff.TypeEffect>(); if (effectsNew != null) { List <EffectDatabase.TypeEff.TypeEffect> addableEffects = new List <EffectDatabase.TypeEff.TypeEffect>(); for (int i = 0; i < effectsNew.Length; i++) { addableEffects.Add(effectsNew[i].Clone()); } this.effectsNew = addableEffects; } this.typeColor = typeColor; this.maxMove = maxMove; }