Permalink
Browse files

STARTREK: Fix Various Compiler Warnings.

  • Loading branch information...
digitall committed Aug 9, 2018
1 parent cb55775 commit 86c6e3f4604c0932ed450f0c349383bc2f375dea
@@ -744,6 +744,12 @@ SharedPtr<Bitmap> StarTrekEngine::loadAnimationFrame(const Common::String &filen
case 's': // Spock
colorShift = 0;
break;
case 'm': // McCoy
colorShift = 0;
break;
default:
colorShift = 0;
break;
}
if (colorShift == 0) {
@@ -460,7 +460,7 @@ bool compareSpritesByLayer(Sprite *s1, Sprite *s2) {
return s1->pos.x < s2->pos.x;
}
void Graphics::drawAllSprites(bool updateScreen) {
void Graphics::drawAllSprites(bool updateScreenFlag) {
// TODO: different video modes?
if (_numSprites != 0) {
@@ -584,7 +584,7 @@ void Graphics::drawAllSprites(bool updateScreen) {
surface.free();
}
if (updateScreen)
if (updateScreenFlag)
this->updateScreen();
}
@@ -603,10 +603,10 @@ void Graphics::drawAllSpritesInRectToSurface(const Common::Rect &rect, ::Graphic
}
}
void Graphics::forceDrawAllSprites(bool updateScreen) {
void Graphics::forceDrawAllSprites(bool updateScreenFlag) {
for (int i = 0; i < _numSprites; i++)
_sprites[i]->bitmapChanged = true;
drawAllSprites(updateScreen);
drawAllSprites(updateScreenFlag);
}
void Graphics::updateScreen() {
@@ -115,7 +115,7 @@ class Graphics {
@ @param rectTop Y-offset to subtract before drawing to surface.
*/
void drawSprite(const Sprite &sprite, ::Graphics::Surface *surface, const Common::Rect &rect, int rectLeft = 0, int rectTop = 0);
void drawAllSprites(bool updateScreen = true);
void drawAllSprites(bool updateScreenFlag = true);
/**
* This function should only be called after "drawAllSprites" (so that sprite rects
* are updated).
@@ -124,7 +124,7 @@ class Graphics {
/**
* Sets "bitmapChanged" to true on all sprites before calling drawAllSprites.
*/
void forceDrawAllSprites(bool updateScreen = true);
void forceDrawAllSprites(bool updateScreenFlag = true);
/**
* Flushes the screen. Usually called by "drawAllSprites".
*/
@@ -104,7 +104,7 @@ void StarTrekEngine::playIntro() {
_sound->loadMusicFile("title");
clockTicks = _clockTicks;
int32 starfieldZoomSpeed;
int32 starfieldZoomSpeed = 0;
int16 frame = 0;
bool buttonPressed = false;
@@ -174,7 +174,7 @@ void Room::demon1KlingonFinishedAimingWeapon() {
playSoundEffectIndex(0x06);
_roomVar.demon.attackIndex++;
int crewman;
int crewman = OBJECT_REDSHIRT;
if (_roomVar.demon.attackIndex == 1) {
loadActorAnim2(OBJECT_REDSHIRT, "rstunn", -1, -1, 0);
crewman = OBJECT_REDSHIRT;
View
@@ -238,14 +238,14 @@ void StarTrekEngine::drawR3Shape(R3 *r3) {
double dbl68 = ((double)r3->field24 * _starfieldPointDivisor) / r3->field36.z;
double dbl70 = 1.0 / dbl68;
double dbl30;
double dbl28;
double dbl20;
double dbl18;
double dbl60;
double dbl58;
double dbl50;
double dbl48;
double dbl30 = 1.0;
double dbl28 = 0.0;
double dbl20 = 0.0;
double dbl18 = 1.0;
double dbl60 = 1.0;
double dbl58 = 0.0;
double dbl50 = 0.0;
double dbl48 = 0.0;
switch (r3->field1e) {
case 1: // TODO
@@ -392,7 +392,7 @@ void StarTrekEngine::drawR3Shape(R3 *r3) {
debug("Top: %d, Bot: %d", shpImageTop, shpImageBottom);
if (shpImageTop <= shpImageBottom) {
bool var3fa;
bool var3fa = false;
if (r3->field1e == 2) {
// TODO
} else

0 comments on commit 86c6e3f

Please sign in to comment.