示例#1
0
文件: module.cpp 项目: Hellzed/xoreos
void Module::unload() {
	unloadAreas();
	unloadTexturePack();
	unloadHAKs();
	unloadPC();
	unloadModule();
}
示例#2
0
文件: module.cpp 项目: jbowtie/xoreos
void Module::unload(bool completeUnload) {
	unloadAreas();
	unloadHAKs();
	unloadTLK();
	unloadModule();

	if (!completeUnload)
		return;

	unloadPC();
	unloadTexturePack();
}
示例#3
0
void Module::loadTexturePack() {
	int level = ConfigMan.getInt("texturepack", 2);
	if (_currentTexturePack == level)
		// Nothing to do
		return;

	unloadTexturePack();

	status("Loading texture pack %d", level);
	indexOptionalArchive(Aurora::kArchiveERF, texturePacks[level], 25, &_textures);

	// If we already had a texture pack loaded, reload all textures
	if (_currentTexturePack != -1)
		TextureMan.reloadAll();

	_currentTexturePack = level;
}
示例#4
0
文件: module.cpp 项目: Hellzed/xoreos
void Module::loadTexturePack() {
	int level = ConfigMan.getInt("texturepack", 1);
	if (_currentTexturePack == level)
		// Nothing to do
		return;

	unloadTexturePack();

	status("Loading texture pack %d", level);
	indexMandatoryArchive(Aurora::kArchiveERF, texturePacks[level][0], 13, &_resTP[0]);
	indexMandatoryArchive(Aurora::kArchiveERF, texturePacks[level][1], 14, &_resTP[1]);
	indexOptionalArchive (Aurora::kArchiveERF, texturePacks[level][2], 15, &_resTP[2]);
	indexOptionalArchive (Aurora::kArchiveERF, texturePacks[level][3], 16, &_resTP[3]);

	// If we already had a texture pack loaded, reload all textures
	if (_currentTexturePack != -1)
		TextureMan.reloadAll();

	_currentTexturePack = level;
}
示例#5
0
文件: module.cpp 项目: jbowtie/xoreos
void Module::loadTexturePack() {
	int level = ConfigMan.getInt("texturepack", 1);
	if (_currentTexturePack == level)
		// Nothing to do
		return;

	const int oldTexturePack = _currentTexturePack;

	unloadTexturePack();

	status("Loading texture pack %d", level);
	indexMandatoryArchive(texturePacks[level][0], 400, &_resTP[0]);
	indexMandatoryArchive(texturePacks[level][1], 401, &_resTP[1]);
	indexOptionalArchive (texturePacks[level][2], 402, &_resTP[2]);
	indexOptionalArchive (texturePacks[level][3], 403, &_resTP[3]);

	// If we already had a texture pack loaded, reload all textures
	if (oldTexturePack != -1)
		TextureMan.reloadAll();

	_currentTexturePack = level;
}
示例#6
0
void Module::unload(bool completeUnload) {
	leaveArea();
	unloadArea();

	if (completeUnload) {
		unloadPC();
		unloadTexturePack();
	}

	unloadIFO();
	unloadResources();

	_eventQueue.clear();
	_delayedActions.clear();

	_newModule.clear();
	_hasModule = false;

	_module.clear();

	_entryLocation.clear();
	_entryLocationType = kObjectTypeAll;
}
示例#7
0
void Module::clear() {
	unload();
	unloadTexturePack();
};