VOYEUR: Use boolean for _isAM instead of int

This commit is contained in:
Strangerke 2014-01-06 07:47:47 +01:00
parent 1fb73446e3
commit 996b2aa43c
4 changed files with 5 additions and 6 deletions

View File

@ -61,7 +61,7 @@ bool Debugger::Cmd_Time(int argc, const char **argv) {
_vm->_voy._transitionId = timeId;
_vm->_gameHour = LEVEL_H[timeId - 1];
_vm->_gameMinute = LEVEL_M[timeId - 1];
_vm->_voy._isAM = timeId == 6;
_vm->_voy._isAM = (timeId == 6);
// Camera back to full charge
_vm->_voy._RTVNum = 0;

View File

@ -67,7 +67,7 @@ struct VoyeurEvent {
class SVoy {
public:
int _isAM;
bool _isAM;
int _RTANum;
int _RTVNum;
int _switchBGNum;

View File

@ -546,7 +546,7 @@ void ThreadResource::parsePlayCommands() {
_vm->_voy._RTANum = 255;
}
_vm->_voy._isAM = _vm->_voy._transitionId == 6;
_vm->_voy._isAM = (_vm->_voy._transitionId == 6);
}
dataP += 6;

View File

@ -38,7 +38,7 @@ void VoyeurEngine::playStamp() {
ThreadResource *threadP = threadsList->_entries[0]->_threadResource;
threadP->initThreadStruct(0, 0);
_voy._isAM = 0;
_voy._isAM = false;
_gameHour = 9;
_gameMinute = 0;
_eventsManager._v2A0A2 = 0;
@ -1121,8 +1121,7 @@ Common::String VoyeurEngine::getTimeOfDay() {
if (_voy._transitionId == 17)
return "";
const char *amPm = _voy._isAM ? AM : PM;
return Common::String::format("%d:%02d%s", _gameHour, _gameMinute, amPm);
return Common::String::format("%d:%02d%s", _gameHour, _gameMinute, _voy._isAM ? AM : PM);
}
bool VoyeurEngine::doComputerText(int maxLen) {