예제 #1
0
 private AbilityData getAbilityForUse(UnitDescriptor unit)
 {
     Kingmaker.UnitLogic.Abilities.Ability ab = unit.Abilities.GetAbility(ability);
     if (ab == null)
     {
         return((AbilityData)null);
     }
     return(this.CreateAbilityData(unit, ab, null));
 }
예제 #2
0
        private AbilityData CreateAbilityData(
            UnitDescriptor caster,
            Kingmaker.UnitLogic.Abilities.Ability fact,
            BlueprintSpellbook spellbook)
        {
            AbilityData ad = new AbilityData(ability, caster, fact, spellbook);

            if (variant == null)
            {
                return(ad);
            }
            return(new AbilityData(variant, caster, fact, spellbook)
            {
                ConvertedFrom = ad
            });
        }