|
@@ -8,14 +8,20 @@
|
|
#pragma once
|
|
#pragma once
|
|
#include <iostream>
|
|
#include <iostream>
|
|
#include <vector>
|
|
#include <vector>
|
|
|
|
+#include <list>
|
|
//#include "AbstractFactory.h"
|
|
//#include "AbstractFactory.h"
|
|
#include "effect.h"
|
|
#include "effect.h"
|
|
-class Cell;
|
|
|
|
|
|
|
|
|
|
+class Unit{
|
|
|
|
+ std :: list <Effect> effectsOnUnit;
|
|
|
|
+};
|
|
|
|
+class Cell{
|
|
|
|
+ std :: list <Effect> effectsOnCell;
|
|
|
|
+};
|
|
class Spell {
|
|
class Spell {
|
|
|
|
|
|
protected:
|
|
protected:
|
|
- std::vector <Effect> effects_;
|
|
|
|
|
|
+ std :: list <Effect> effects_;
|
|
|
|
|
|
private:
|
|
private:
|
|
int distance_;
|
|
int distance_;
|
|
@@ -33,12 +39,14 @@ public:
|
|
bool getForCell();
|
|
bool getForCell();
|
|
void setForCell(bool value);
|
|
void setForCell(bool value);
|
|
|
|
|
|
- int lenOfActualPath(Cell* destination);
|
|
|
|
|
|
+ //int lenOfSmallestPath(Cell* destination);
|
|
|
|
|
|
virtual bool canCastForDistance(int distance);
|
|
virtual bool canCastForDistance(int distance);
|
|
|
|
|
|
virtual bool canCastToCell(Cell* destination);
|
|
virtual bool canCastToCell(Cell* destination);
|
|
|
|
|
|
virtual void castToCell(Cell* destination);
|
|
virtual void castToCell(Cell* destination);
|
|
|
|
+
|
|
|
|
+ void CastSpell(Cell* from, Cell* where, Unit* who, Unit* whom);
|
|
};
|
|
};
|
|
#endif //THE_GAME_SPELL_H
|
|
#endif //THE_GAME_SPELL_H
|