Skip to content

Commit

Permalink
ACCESS: Finish moving timer flag from bool to byte based on the assem…
Browse files Browse the repository at this point in the history
…bly, modify some comments and TODOs
  • Loading branch information
Strangerke committed Aug 20, 2014
1 parent 23a4424 commit 70b8efa
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions engines/access/amazon/amazon_game.cpp
Expand Up @@ -169,12 +169,12 @@ void AmazonEngine::setupGame() {
for (int i = 0; i < 32; ++i) {
TimerEntry te;
te._initTm = te._timer = (i < 8) ? TIMER_DEFAULTS[i] : 1;
te._flag = true;
te._flag = 1;

_timers.push_back(te);
}

// Miscellaenous
// Miscellaneous
_fonts._font2.load(FONT2_INDEX, FONT2_DATA);
_fonts._font6x6.load(FONT6x6_INDEX, FONT6x6_DATA);

Expand Down
2 changes: 1 addition & 1 deletion engines/access/data.cpp
Expand Up @@ -52,7 +52,7 @@ void TimerList::updateTimers() {
if (te._flag) {
if (!--te._timer) {
te._timer = te._initTm;
te._flag = false;
te._flag = 0;
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion engines/access/data.h
Expand Up @@ -47,7 +47,7 @@ struct TimerEntry {

TimerEntry() {
_initTm = _timer = 0;
_flag = false;
_flag = 0;
}
};

Expand Down
20 changes: 10 additions & 10 deletions engines/access/player.cpp
Expand Up @@ -97,7 +97,7 @@ void Player::load() {

_vm->_timers[8]._initTm = 7;
_vm->_timers[8]._timer = 7;
_vm->_timers[8]._flag = true;
++_vm->_timers[8]._flag;

_sideWalkMin = 0;
_sideWalkMax = 5;
Expand Down Expand Up @@ -191,7 +191,7 @@ void Player::walk() {
return;
}

_vm->_timers[0]._flag = true;
++_vm->_timers[0]._flag;
switch (_move) {
case UP:
_playerMove = false;
Expand Down Expand Up @@ -260,7 +260,7 @@ void Player::walkUp() {

calcManScale();
if (_vm->_currentMan != 3 && (_frame == 17 || _frame == 21)) {
// TODO: si = 0?
warning("TODO: walkUp - si = 0?");
}

if (++_frame > _upWalkMax)
Expand Down Expand Up @@ -289,7 +289,7 @@ void Player::walkDown() {

calcManScale();
if (_vm->_currentMan != 3 && (_frame == 10 || _frame == 14)) {
// TODO: si = 0?
warning("TODO: walkDown - si = 0?");
}

if (++_frame > _downWalkMax)
Expand Down Expand Up @@ -330,7 +330,7 @@ void Player::walkLeft() {
++_frame;

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkLeft - si = 0?");
}

if (_frame > _sideWalkMax)
Expand Down Expand Up @@ -371,7 +371,7 @@ void Player::walkRight() {
++_frame;

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkRight - si = 0?");
}

if (_frame > _sideWalkMax)
Expand Down Expand Up @@ -422,7 +422,7 @@ void Player::walkUpLeft() {
calcManScale();

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkUpLeft - si = 0?");
}

if (_frame > _diagUpWalkMax)
Expand Down Expand Up @@ -473,7 +473,7 @@ void Player::walkDownLeft() {
calcManScale();

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkDownLeft - si = 0?");
}

if (_frame > _diagDownWalkMax)
Expand Down Expand Up @@ -524,7 +524,7 @@ void Player::walkUpRight() {
calcManScale();

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkUpRight - si = 0?");
}

if (_frame > _diagUpWalkMax)
Expand Down Expand Up @@ -576,7 +576,7 @@ void Player::walkDownRight() {
calcManScale();

if (_vm->_currentMan != 3 && (_frame == 1 || _frame == 5)) {
// TODO: si = 0?
warning("TODO: walkDownRight - si = 0?");
}

if (_frame > _diagDownWalkMax)
Expand Down
2 changes: 1 addition & 1 deletion engines/access/scripts.cpp
Expand Up @@ -189,7 +189,7 @@ void Scripts::printString(const Common::String &msg) {
_vm->_fonts._printStart = Common::Point(20, 42);
_vm->_timers[PRINT_TIMER]._timer = 50;
_vm->_timers[PRINT_TIMER]._initTm = 50;
_vm->_timers[PRINT_TIMER]._flag = true;
++_vm->_timers[PRINT_TIMER]._flag;

// Display the text in a bubble, and wait for a keypress or mouse click
_vm->_bubbleBox->placeBubble(msg);
Expand Down

0 comments on commit 70b8efa

Please sign in to comment.