Permalink
Browse files

STARTREK: Fix compilation on macOS

nullptr is an object on macOS.
  • Loading branch information...
sev- committed Aug 9, 2018
1 parent ad90059 commit 85cd34750395475701cad009d221646744eb2f16
Showing with 6 additions and 6 deletions.
  1. +1 −1 engines/startrek/awaymission.cpp
  2. +2 −2 engines/startrek/intro.cpp
  3. +2 −2 engines/startrek/space.cpp
  4. +1 −1 engines/startrek/textbox.cpp
@@ -565,7 +565,7 @@ void StarTrekEngine::handleAwayMissionAction() {
break;
case OBJECT_REDSHIRT:
showTextbox(nullptr, getLoadedText(GROUNDTX_REDSHIRT_USE), 20, 20, TEXTCOLOR_YELLOW, 0);
showTextbox(NULL, getLoadedText(GROUNDTX_REDSHIRT_USE), 20, 20, TEXTCOLOR_YELLOW, 0);
break;
case OBJECT_IPHASERS:
@@ -39,8 +39,8 @@ void StarTrekEngine::playIntro() {
R3 planetR3 = R3();
planetR3.matrix = initMatrix();
planetR3.field1e = 3;
planetR3.funcPtr1 = nullptr;
planetR3.funcPtr2 = nullptr;
planetR3.funcPtr1 = NULL;
planetR3.funcPtr2 = NULL;
planetR3.bitmapOffset = 0;
_gfx->clearScreenAndPriBuffer();
@@ -228,7 +228,7 @@ void StarTrekEngine::drawR3Shape(R3 *r3) {
if (r3->field1e != 3) // TODO: remove this
return;
if (r3->funcPtr1 != nullptr) {
if (r3->funcPtr1 != NULL) {
// TODO: call it
}
@@ -485,7 +485,7 @@ void StarTrekEngine::drawR3Shape(R3 *r3) {
}
}
if (r3->funcPtr2 != nullptr) {
if (r3->funcPtr2 != NULL) {
// TODO: call it
}
}
@@ -636,7 +636,7 @@ String StarTrekEngine::readLineFormattedText(TextGetterFunc textGetter, uintptr
return lineFormattedText;
} else
return nullptr;
return NULL;
}
String StarTrekEngine::readTextFromArray(int choiceIndex, uintptr data, String *headerTextOutput) {

0 comments on commit 85cd347

Please sign in to comment.