public BasicAbility Clone() { BasicAbility temp = (BasicAbility)this.MemberwiseClone(); temp.abilityIcon = abilityIcon.Clone(); temp.statModifier = statModifier.Clone(); temp.EnemyStatModifier = EnemyStatModifier.Clone(); temp.abilityModifier = abilityModifier.Clone(); //temp.AbilityManaCost = new List<int>(AbilityManaCost); //temp.AbilityAPCost = new List<int>(AbilityAPCost); //temp.AbilityHitChance = new List<int>(AbilityHitChance); //temp.AbilityCritChance = new List<int>(AbilityCritChance); temp.abiAOEM = abiAOEM.Clone(); temp.abiAOEMAS = abiAOEMAS.Clone(); temp.targetableTypes = new List <BaseClass.CLASSType>(targetableTypes); //temp.abilityDescription = ""; return(temp); }
private BaseCharacter GenerateAICharacter() { BaseCharacter temp = EnemyChar.Clone(); temp.statChart = enemyStats.Clone(); temp.displayName = enemyName; temp.weapon = EnemyWeapon; temp.enemyWeaponArray = enemyWeaponArray; temp.armour = EnemyArmor; temp.enemyArmourArray = enemyArmourArray; temp.CCC = CCC.Clone(); temp.CCC.parent = temp; if (HasProperLua() && GameProcessor.bIsInGame) { ExecuteLuaCreation(ref temp); } temp.statChart.MakeSureActiveAndPassiveStatsEqual(); temp.bIsAI = true; temp.eai = this; return(temp); }