2010-07-26 09:58:49 +00:00
|
|
|
#ifndef GAME_MWMECHANICS_MECHANICSMANAGER_H
|
|
|
|
#define GAME_MWMECHANICS_MECHANICSMANAGER_H
|
2010-07-26 09:15:38 +00:00
|
|
|
|
2010-07-27 12:05:05 +00:00
|
|
|
#include <set>
|
|
|
|
|
|
|
|
#include "../mwworld/ptr.hpp"
|
|
|
|
|
2010-07-27 13:59:41 +00:00
|
|
|
#include "creaturestats.hpp"
|
|
|
|
|
2010-07-26 09:15:38 +00:00
|
|
|
namespace ESMS
|
|
|
|
{
|
|
|
|
class ESMStore;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace MWGui
|
|
|
|
{
|
|
|
|
class WindowManager;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace MWMechanics
|
|
|
|
{
|
|
|
|
class MechanicsManager
|
|
|
|
{
|
2010-07-27 12:05:05 +00:00
|
|
|
const ESMS::ESMStore& mStore;
|
|
|
|
MWGui::WindowManager& mWindowManager;
|
|
|
|
std::set<MWWorld::Ptr> mActors;
|
2010-07-27 13:59:41 +00:00
|
|
|
MWWorld::Ptr mWatched;
|
|
|
|
CreatureStats mWatchedCreature;
|
2010-07-26 09:15:38 +00:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
MechanicsManager (const ESMS::ESMStore& store, MWGui::WindowManager& windowManager);
|
|
|
|
|
|
|
|
void configureGUI();
|
2010-07-27 12:05:05 +00:00
|
|
|
|
|
|
|
void addActor (const MWWorld::Ptr& ptr);
|
|
|
|
///< Register an actor for stats management
|
2010-07-27 12:43:46 +00:00
|
|
|
|
|
|
|
void removeActor (const MWWorld::Ptr& ptr);
|
|
|
|
///< Deregister an actor for stats management
|
|
|
|
|
2010-07-27 12:05:05 +00:00
|
|
|
void dropActors (const MWWorld::Ptr::CellStore *cellStore);
|
|
|
|
///< Deregister all actors in the given cell.
|
2010-07-27 12:46:05 +00:00
|
|
|
|
2010-07-27 13:59:41 +00:00
|
|
|
void watchActor (const MWWorld::Ptr& ptr);
|
|
|
|
///< On each update look for changes in a previously registered actor and update the
|
|
|
|
/// GUI accordingly.
|
|
|
|
|
2010-07-27 12:46:05 +00:00
|
|
|
void update();
|
|
|
|
///< Update actor stats
|
2010-07-26 09:15:38 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|