Exemplo n.º 1
0
 public DebugSpellCasting(FFACE fface)
 {
     InitializeComponent();
     this._fface      = fface;
     this._XITools    = XITools.GetInstance(fface);
     this.DataContext = new CastingViewModel(fface);
 }
Exemplo n.º 2
0
            /// <summary>
            /// Casts spell using spell name
            /// </summary>
            /// <returns></returns>
            public bool CastSpell()
            {
                bool success = false;

                var ability = _ftools.AbilityService.CreateAbility(_spellName);

                if (ability.IsValidName)
                {
                    bool valid = XITools.GetInstance(_fface).AbilityExecutor.IsActionValid(ability);
                    success = _ftools.AbilityExecutor.UseAbility(ability, Constants.SPELL_CAST_LATENCY, Constants.GLOBAL_SPELL_COOLDOWN);
                }

                return(success);
            }