Esempio n. 1
0
        /*********
        ** Public Methods
        *********/
        /// <summary>Constructs an instance.</summary>
        /// <param name="name">The name of the persona.</param>
        /// <param name="arcana">The arcana of the persona.</param>
        /// <param name="level">The base level of the persona.</param>
        /// <param name="stats">The stats of the persona.</param>
        /// <param name="elementAffinities">The element affinities of the persona.</param>
        /// <param name="skills">The skills of the persona.</param>
        /// <param name="isUltimate">Whether the persona is an ultimate persona.</param>
        /// <param name="isNewGamePlus">Whether the persona is a new game plus persona.</param>
        /// <param name="isSpecial">Whether the persona has a special fusion recipe.</param>
        public Persona(string name, string arcana, int level, Stats stats, ElementAffinities elementAffinities, List <PersonaSkill> skills, bool isUltimate = false, bool isNewGamePlus = false, bool isSpecial = false)
        {
            Name              = name;
            Arcana            = arcana;
            Level             = level;
            Stats             = stats;
            ElementAffinities = elementAffinities;
            Skills            = skills ?? new();
            IsUltimate        = isUltimate;
            IsNewGamePlus     = isNewGamePlus;
            IsSpecial         = isSpecial;

            Cost = (int)MathF.Pow(Stats.Strength + Stats.Magic + Stats.Endurance + Stats.Agility + Stats.Luck, 2) + 2000;
        }
Esempio n. 2
0
 /// <inheritdoc/>
 public override bool DoesModelPassFilter(string filter) =>
 Name.Contains(filter, StringComparison.OrdinalIgnoreCase) ||
 Arcana.Contains(filter, StringComparison.OrdinalIgnoreCase) ||
 Level.ToString().Contains(filter) ||
 Stats.DoesModelPassFilter(filter) ||
 ElementAffinities.DoesModelPassFilter(filter);