diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/crcombat.hh | 43 | ||||
| -rw-r--r-- | src/creature.hh | 53 | ||||
| -rw-r--r-- | src/crskill.cc (renamed from src/skill.cc) | 3 | ||||
| -rw-r--r-- | src/crskill.hh (renamed from src/skill.hh) | 6 | ||||
| -rw-r--r-- | src/player.hh | 2 |
5 files changed, 55 insertions, 52 deletions
diff --git a/src/crcombat.hh b/src/crcombat.hh new file mode 100644 index 0000000..ce75002 --- /dev/null +++ b/src/crcombat.hh @@ -0,0 +1,43 @@ +#ifndef TIBIA_CRCOMBAT_HH_ +#define TIBIA_CRCOMBAT_HH_ 1 + +struct TCreature; + +struct TCombatEntry{ + uint32 ID; + uint32 Damage; + int TimeStamp; +}; + +struct TCombat{ + // REGULAR FUNCTIONS + // ========================================================================= + TCombat(void); + void CheckCombatValues(void); + + // DATA + // ========================================================================= + TCreature *Master; + uint32 EarliestAttackTime; + uint32 EarliestDefendTime; + uint32 LastDefendTime; + uint32 LatestAttackTime; + uint32 AttackMode; + uint32 ChaseMode; + uint32 SecureMode; + uint32 AttackDest; + bool Following; + Object Shield; + Object Close; + Object Missile; + Object Throw; + Object Wand; + Object Ammo; + bool Fist; + uint32 CombatDamage; + int ActCombatEntry; + TCombatEntry CombatList[20]; + int LearningPoints; +}; + +#endif //TIBIA_CRCOMBAT_HH_ diff --git a/src/creature.hh b/src/creature.hh index 423ad8c..bafc55e 100644 --- a/src/creature.hh +++ b/src/creature.hh @@ -5,45 +5,16 @@ #include "connection.hh" #include "containers.hh" #include "map.hh" -#include "skill.hh" -struct TCreature; +#include "crcombat.hh" +#include "crskill.hh" -struct TCombatEntry{ - uint32 ID; - uint32 Damage; - int TimeStamp; -}; - -struct TCombat{ - // REGULAR FUNCTIONS - // ========================================================================= - TCombat(void); - void CheckCombatValues(void); - - // DATA - // ========================================================================= - TCreature *Master; - uint32 EarliestAttackTime; - uint32 EarliestDefendTime; - uint32 LastDefendTime; - uint32 LatestAttackTime; - uint32 AttackMode; - uint32 ChaseMode; - uint32 SecureMode; - uint32 AttackDest; - bool Following; - Object Shield; - Object Close; - Object Missile; - Object Throw; - Object Wand; - Object Ammo; - bool Fist; - uint32 CombatDamage; - int ActCombatEntry; - TCombatEntry CombatList[20]; - int LearningPoints; +struct TOutfit{ + int OutfitID; + union{ + uint16 ObjectType; + uint8 Colors[4]; + }; }; struct TToDoEntry { @@ -99,14 +70,6 @@ struct TToDoEntry { }; }; -struct TOutfit{ - int OutfitID; - union{ - uint16 ObjectType; - uint8 Colors[4]; - }; -}; - struct TCreature: TSkillBase { // REGULAR FUNCTIONS // ========================================================================= diff --git a/src/skill.cc b/src/crskill.cc index aa69658..ce12cad 100644 --- a/src/skill.cc +++ b/src/crskill.cc @@ -1,8 +1,5 @@ -#include "skill.hh" -#include "enums.hh" #include "creature.hh" #include "monster.hh" -#include "player.hh" #include "stubs.hh" diff --git a/src/skill.hh b/src/crskill.hh index 353eb7d..abb2476 100644 --- a/src/skill.hh +++ b/src/crskill.hh @@ -1,5 +1,5 @@ -#ifndef TIBIA_SKILL_HH_ -#define TIBIA_SKILL_HH_ 1 +#ifndef TIBIA_CRSKILL_HH_ +#define TIBIA_CRSKILL_HH_ 1 #include "common.hh" @@ -170,4 +170,4 @@ struct TSkillBase{ uint16 FirstFreeTimer; }; -#endif //TIBIA_SKILL_HH_ +#endif //TIBIA_CRSKILL_HH_ diff --git a/src/player.hh b/src/player.hh index c985408..bb58ac3 100644 --- a/src/player.hh +++ b/src/player.hh @@ -2,8 +2,8 @@ #define TIBIA_PLAYER_HH_ 1 #include "common.hh" -#include "creature.hh" #include "containers.hh" +#include "creature.hh" struct TPlayerData { uint32 CharacterID; |
