meleedamagespell.cpp 422 B

1234567891011121314151617
  1. //
  2. // Created by IgorBat on 23.04.2018.
  3. //
  4. #pragma once
  5. #include <cassert>
  6. #include "spells/meleedamagespell.h"
  7. #include "units/unit.h"
  8. #include "cell.h"
  9. #include <string>
  10. void MeleeDamageSpell::CastSpell(Cell* from, Cell* where, Unit* who, Unit* whom){
  11. effects_[0] -> OperateOnUnit(whom);
  12. }
  13. bool MeleeDamageSpell::canCastToCell(Cell* destination, Cell* from){
  14. return isNeirbor(Cell* destination, Cell* from);
  15. }