mirror of
https://github.com/OpenMW/openmw.git
synced 2025-04-02 16:36:41 +00:00
Use forward declarations instead of including aistate.hpp
This commit is contained in:
parent
f5c2e09df9
commit
d2b7253c7f
4 changed files with 19 additions and 9 deletions
|
@ -4,12 +4,13 @@
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
||||||
#include <components/detournavigator/areatype.hpp>
|
#include <components/detournavigator/areatype.hpp>
|
||||||
|
|
||||||
#include "pathfinding.hpp"
|
#include "pathfinding.hpp"
|
||||||
#include "obstacle.hpp"
|
#include "obstacle.hpp"
|
||||||
#include "aistate.hpp"
|
|
||||||
#include "aipackagetypeid.hpp"
|
#include "aipackagetypeid.hpp"
|
||||||
#include "aitimer.hpp"
|
#include "aitimer.hpp"
|
||||||
|
#include "aistatefwd.hpp"
|
||||||
|
|
||||||
#include "../mwworld/ptr.hpp"
|
#include "../mwworld/ptr.hpp"
|
||||||
|
|
||||||
namespace ESM
|
namespace ESM
|
||||||
|
|
|
@ -27,10 +27,6 @@ namespace MWMechanics
|
||||||
{
|
{
|
||||||
class AiPackage;
|
class AiPackage;
|
||||||
class CharacterController;
|
class CharacterController;
|
||||||
|
|
||||||
template< class Base > class DerivedClassStorage;
|
|
||||||
struct AiTemporaryBase;
|
|
||||||
typedef DerivedClassStorage<AiTemporaryBase> AiState;
|
|
||||||
|
|
||||||
using AiPackages = std::vector<std::shared_ptr<AiPackage>>;
|
using AiPackages = std::vector<std::shared_ptr<AiPackage>>;
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
#ifndef AISTATE_H
|
#ifndef AISTATE_H
|
||||||
#define AISTATE_H
|
#define AISTATE_H
|
||||||
|
|
||||||
|
#include "aistatefwd.hpp"
|
||||||
#include "aitemporarybase.hpp"
|
#include "aitemporarybase.hpp"
|
||||||
|
|
||||||
namespace MWMechanics
|
namespace MWMechanics
|
||||||
|
@ -71,9 +72,6 @@ namespace MWMechanics
|
||||||
delete mStorage;
|
delete mStorage;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
/// \brief Container for AI package status.
|
|
||||||
typedef DerivedClassStorage<AiTemporaryBase> AiState;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // AISTATE_H
|
#endif // AISTATE_H
|
||||||
|
|
15
apps/openmw/mwmechanics/aistatefwd.hpp
Normal file
15
apps/openmw/mwmechanics/aistatefwd.hpp
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#ifndef OPENMW_MWMECHANICS_AISTATEFWD_H
|
||||||
|
#define OPENMW_MWMECHANICS_AISTATEFWD_H
|
||||||
|
|
||||||
|
namespace MWMechanics
|
||||||
|
{
|
||||||
|
template <class Base>
|
||||||
|
class DerivedClassStorage;
|
||||||
|
|
||||||
|
struct AiTemporaryBase;
|
||||||
|
|
||||||
|
/// \brief Container for AI package status.
|
||||||
|
using AiState = DerivedClassStorage<AiTemporaryBase>;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
Loading…
Reference in a new issue