46 namespace DragonAge2 {
49 _engine(&engine), _console(&console) {
142 static const char *
const kTextureQualityName[
kTextureQualityMAX] = {
"high",
"medium" };
147 loadResourceDir(dir +
"/textures/" + kTextureQualityName[quality], priority + 300, res);
176 files.relativize(tlkDir);
181 if (f->toLower().endsWith(languageTLK)) {
186 }
else if (f->toLower().endsWith(languageTLKP)) {
202 TalkMan.addTable(tlkM, tlkF,
false, priority, &changes.back());
221 for (std::list<Common::ChangeID>::iterator t = changes.begin(); t != changes.end(); ++t)
Campaigns & getCampaigns()
Return the campaigns context.
#define ResMan
Shortcut for accessing the sound manager.
Game(DragonAge2Engine &engine, ::Engines::Console &console)
static void loadResourceDir(const Common::UString &dir, uint32 priority, ChangeList &changes)
A creature in a Dragon Age II area.
#define TalkMan
Shortcut for accessing the talk manager.
static void unloadTalkTables(ChangeList &changes)
Unload this set of talk tables.
A class holding an UTF-8 string.
static UString getExtension(const UString &p)
Return a file name's extension.
static Common::UString getLanguageString(Aurora::Language language)
Return the string Dragon Age II uses to representing this language.
::Engines::Console * _console
bool indexOptionalArchive(const Common::UString &file, uint32 priority, const std::vector< byte > &password, Common::ChangeID *changeID)
bool getLanguage(Aurora::Language &language) const
Return the game's current language.
Engine class handling Dragon Age II.
bool equalsIgnoreCase(const UString &str) const
void truncate(const iterator &it)
The context handling the gameplay in Dragon Age II.
std::list< UString >::const_iterator const_iterator
bool indexOptionalDirectory(const Common::UString &dir, const char *glob, int depth, uint32 priority, Common::ChangeID *changeID)
Add a directory to the resource manager, if it exists.
std::list< Common::ChangeID > ChangeList
Basic exceptions to throw.
void indexMandatoryArchive(const Common::UString &file, uint32 priority, const std::vector< byte > &password, Common::ChangeID *changeID)
Common::ScopedPtr< Functions > _functions
static void loadTexturePack(const Common::UString &dir, uint32 priority, ChangeList &res, TextureQuality quality)
The global events manager.
DragonAge2Engine * _engine
#define EventMan
Shortcut for accessing the events manager.
void relativize(const Common::UString &basePath)
Express all files in this archive as relative to the given base path.
The context holding a Dragon Age II campaign.
The context managing and running the Dragon Age II campaigns.
size_t size() const
Return the size of the string, in characters.
A class representing an undoable change.
The global talk manager for Aurora strings.
static void loadTalkTable(const Common::UString &tlk, const Common::UString &suffix, Aurora::Language language, uint32 priority, ChangeList &changes)
Common::ScopedPtr< Campaigns > _campaigns
const_iterator begin() const
Return a const_iterator pointing to the beginning of the list.
void sort(bool caseInsensitive)
Sort this list alphabetically.
void loadTalkTables(const Common::UString &dir, uint32 priority, ChangeList &res)
Load all talk tables in the current language found in this directory.
Dragon Age II engine functions.
void createFakePC()
Create a fake player character creature for testing purposes.
The global resource manager for Aurora resources.
Utility class for manipulating file paths.
const_iterator end() const
Return a const_iterator pointing past the end of the list.
static UString findSubDirectory(const UString &directory, const UString &subDirectory, bool caseInsensitive=false)
Find a directory's subdirectory.
void loadResources(const Common::UString &dir, uint32 priority, ChangeList &res)
Load all game resource archives in the current language found in this directory.