1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-03 00:46:55 +02:00

* enum for secondary skills

* THex for battle positions
* towards removal of battleGetStackByID

TODO:
investigate the necessity of putting implementation of BattleAction CGlobalAI::activeStack( const CStack * stack ) in CGeniusAI.cpp
This commit is contained in:
mateuszb
2010-12-23 20:18:10 +00:00
parent 2fe8b07f4f
commit 4929cf9782
22 changed files with 191 additions and 157 deletions

View File

@ -246,6 +246,13 @@ public:
class DLL_EXPORT CGHeroInstance : public CArmedInstance, public IBoatGenerator
{
public:
enum SecondarySkill
{
PATHFINDING = 0, ARCHERY, LOGISTICS, SCOUTING, DIPLOMACY, NAVIGATION, LEADERSHIP, WISDOM, MYSTICISM,
LUCK, BALLISTICS, EAGLE_EYE, NECROMANCY, ESTATES, FIRE_MAGIC, AIR_MAGIC, WATER_MAGIC, EARTH_MAGIC,
SCHOLAR, TACTICS, ARTILLERY, LEARNING, OFFENCE, ARMORER, INTELLIGENCE, SORCERY, RESISTANCE,
FIRST_AID
};
//////////////////////////////////////////////////////////////////////////
ui8 moveDir; //format: 123
@ -338,8 +345,8 @@ public:
int getCurrentMorale(int stack=-1, bool town=false) const; //if stack - position of creature, if -1 then morale for hero is calculated; town - if bonuses from town (tavern) should be considered
TModDescr getCurrentMoraleModifiers(int stack=-1, bool town=false) const; //args as above
int getPrimSkillLevel(int id) const; //0-attack, 1-defence, 2-spell power, 3-knowledge
ui8 getSecSkillLevel(const int & ID) const; //0 - no skill
void setSecSkillLevel(int which, int val, bool abs);// abs == 0 - changes by value; 1 - sets to value
ui8 getSecSkillLevel(SecondarySkill skill) const; //0 - no skill
void setSecSkillLevel(SecondarySkill which, int val, bool abs);// abs == 0 - changes by value; 1 - sets to value
int maxMovePoints(bool onLand) const;