ULTIMA: Disable unstable subengines by default

This commit is contained in:
Cameron Cawley 2020-09-09 15:57:02 +01:00 committed by Paul Gilbert
parent 44147fd01a
commit 4a1d7a1753
4 changed files with 18 additions and 1 deletions

View File

@ -38,7 +38,9 @@
namespace Ultima {
static const PlainGameDescriptor ULTIMA_GAMES[] = {
#ifndef RELEASE_BUILD
{ "ultima1", "Ultima I - The First Age of Darkness" },
#endif
{ "ultima4", "Ultima IV - Quest of the Avatar" },
{ "ultima4_enh", "Ultima IV - Quest of the Avatar - Enhanced" },
{ "ultima6", "Ultima VI - The False Prophet" },
@ -69,9 +71,11 @@ bool UltimaMetaEngine::createInstance(OSystem *syst, Engine **engine, const ADGa
const Ultima::UltimaGameDescription *gd = (const Ultima::UltimaGameDescription *)desc;
if (gd) {
switch (gd->gameId) {
#ifndef RELEASE_BUILD
case Ultima::GAME_ULTIMA1:
*engine = new Ultima::Shared::UltimaEarlyEngine(syst, gd);
break;
#endif
case Ultima::GAME_ULTIMA4:
*engine = new Ultima::Ultima4::Ultima4Engine(syst, gd);
break;

View File

@ -23,6 +23,7 @@
namespace Ultima {
static const UltimaGameDescription GAME_DESCRIPTIONS[] = {
#ifndef RELEASE_BUILD
{
// Ultima I - The First Age of Darkness
{
@ -76,6 +77,7 @@ static const UltimaGameDescription GAME_DESCRIPTIONS[] = {
GAME_ULTIMA1,
0
},
#endif
{
// Ultima IV - Quest of the Avatar

View File

@ -29,13 +29,17 @@
#include "graphics/scaler.h"
#include "gui/saveload.h"
#include "ultima/shared/early/ultima_early.h"
#include "ultima/shared/early/game.h"
#include "ultima/shared/engine/ultima.h"
#include "ultima/shared/engine/debugger.h"
#include "ultima/shared/engine/events.h"
#include "ultima/shared/engine/resources.h"
#include "ultima/shared/core/mouse_cursor.h"
#include "ultima/shared/gfx/screen.h"
#ifndef RELEASE_BUILD
#include "ultima/ultima1/game.h"
#endif
namespace Ultima {
@ -117,8 +121,10 @@ Graphics::Screen *UltimaEarlyEngine::getScreen() const {
Game *UltimaEarlyEngine::createGame() const {
switch (getGameId()) {
#ifndef RELEASE_BUILD
case GAME_ULTIMA1:
return new Ultima1::Ultima1Game();
#endif
default:
error("Unknown game");
}

View File

@ -22,9 +22,12 @@
#include "ultima/shared/engine/resources.h"
#include "ultima/shared/early/font_resources.h"
#include "ultima/ultima1/core/resources.h"
#include "common/endian.h"
#ifndef RELEASE_BUILD
#include "ultima/ultima1/core/resources.h"
#endif
namespace Ultima {
namespace Shared {
@ -34,8 +37,10 @@ bool Resources::open() {
// Save locally constructred resources to the archive manager for access
Shared::FontResources sharedFonts(this);
sharedFonts.save();
#ifndef RELEASE_BUILD
Ultima1::GameResources u1Data(this);
u1Data.save();
#endif
return true;
}