SUPERNOVA: Renames NULL to nullptr

This commit is contained in:
Joseph-Eugene Winzer 2018-03-23 02:22:10 +01:00 committed by Thierry Crozat
parent d963827dbb
commit 6187e25199
5 changed files with 14 additions and 14 deletions

View File

@ -32,7 +32,7 @@
static const PlainGameDescriptor supernovaGames[] = {
{"msn1", "Mission Supernova 1"},
{"msn2", "Mission Supernova 2"},
{NULL, NULL}
{nullptr, nullptr}
};
namespace Supernova {
@ -40,7 +40,7 @@ static const ADGameDescription gameDescriptions[] = {
// Mission Supernova 1
{
"msn1",
NULL,
nullptr,
AD_ENTRY1s("msn_data.000", "f64f16782a86211efa919fbae41e7568", 24163),
Common::DE_DEU,
Common::kPlatformDOS,
@ -49,7 +49,7 @@ static const ADGameDescription gameDescriptions[] = {
},
{
"msn1",
NULL,
nullptr,
AD_ENTRY1s("msn_data.000", "f64f16782a86211efa919fbae41e7568", 24163),
Common::EN_ANY,
Common::kPlatformDOS,
@ -60,7 +60,7 @@ static const ADGameDescription gameDescriptions[] = {
// Mission Supernova 2
{
"msn2",
NULL,
nullptr,
AD_ENTRY1s("ms2_data.000", "e595610cba4a6d24a763e428d05cc83f", 24805),
Common::DE_DEU,
Common::kPlatformDOS,
@ -69,7 +69,7 @@ static const ADGameDescription gameDescriptions[] = {
},
{
"msn2",
NULL,
nullptr,
AD_ENTRY1s("ms2_data.000", "e595610cba4a6d24a763e428d05cc83f", 24805),
Common::EN_ANY,
Common::kPlatformDOS,
@ -131,7 +131,7 @@ bool SupernovaMetaEngine::createInstance(OSystem *syst, Engine **engine, const A
*engine = new Supernova::SupernovaEngine(syst);
}
return desc != NULL;
return desc != nullptr;
}
SaveStateList SupernovaMetaEngine::listSaves(const char *target) const {

View File

@ -241,11 +241,11 @@ bool MSNImage::loadSections() {
void MSNImage::destroy() {
if (_palette) {
delete[] _palette;
_palette = NULL;
_palette = nullptr;
}
if (_encodedImage) {
delete[] _encodedImage;
_encodedImage = NULL;
_encodedImage = nullptr;
}
for (Common::Array<Graphics::Surface *>::iterator it = _sectionSurfaces.begin();
it != _sectionSurfaces.end(); ++it) {

View File

@ -193,7 +193,7 @@ static Common::MemoryReadStream *convertToMod(const char *filename, int version)
msnFile.open(filename);
if (!msnFile.isOpen()) {
warning("Data file '%s' not found", msnFile.getName());
return NULL;
return nullptr;
}
for (int i = 0 ; i < nbInstr2 ; ++i) {

View File

@ -77,9 +77,9 @@ ObjectType &operator^=(ObjectType &a, ObjectType b) {
SupernovaEngine::SupernovaEngine(OSystem *syst)
: Engine(syst)
, _console(NULL)
, _gm(NULL)
, _currentImage(NULL)
, _console(nullptr)
, _gm(nullptr)
, _currentImage(nullptr)
, _rnd("supernova")
, _brightness(255)
, _menuBrightness(255)
@ -315,7 +315,7 @@ bool SupernovaEngine::setCurrentImage(int filenumber) {
_currentImage = new MSNImage();
if (!_currentImage->init(filenumber)) {
delete _currentImage;
_currentImage = NULL;
_currentImage = nullptr;
return false;
}

View File

@ -53,7 +53,7 @@ struct ScreenBuffer {
, _y(0)
, _width(0)
, _height(0)
, _pixels(NULL)
, _pixels(nullptr)
{}
byte *_pixels;