Skip to content

Commit

Permalink
FULLPIPE: Implement StaticANIObject::show1()
Browse files Browse the repository at this point in the history
  • Loading branch information
sev- committed Sep 6, 2013
1 parent e08340e commit e826d35
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 3 deletions.
3 changes: 2 additions & 1 deletion engines/fullpipe/messages.cpp
Expand Up @@ -302,7 +302,8 @@ void MessageQueue::update() {
}

void MessageQueue::messageQueueCallback1(int par) {
warning("STUB: MessageQueue::messageQueueCallback1()");
// Autosave
debug(3, "STUB: MessageQueue::messageQueueCallback1()");
}

ExCommand *MessageQueue::getExCommandByIndex(uint idx) {
Expand Down
47 changes: 45 additions & 2 deletions engines/fullpipe/statics.cpp
Expand Up @@ -774,8 +774,51 @@ void StaticANIObject::hide() {
}
}

void StaticANIObject::show1(int x, int y, int movementId, int mqId) {
warning("STUB: StaticANIObject::show1(%d, %d, %d, %d)", x, y, movementId, mqId);
void StaticANIObject::show1(int x, int y, int movId, int mqId) {
debug(0, "StaticANIObject::show1(%d, %d, %d, %d)", x, y, movId, mqId);

if (_messageQueueId)
return;

if (movId == -1) {
_flags |= 4u;
if (x != -1 && y != -1)
setOXY(x, y);

return;
}

Movement *mov = getMovementById(movId);
if (!mov)
return;

if (x != -1 && y != -1)
setOXY(x, y);

_statics = mov->_staticsObj1;

Common::Point point;

mov->_staticsObj1->getSomeXY(point);
_statics->_x = x - point.x;
_statics->_y = y - point.y;

_statics->_countdown = _statics->_initialCountdown;

_flags |= 4;
_ox = x;
_oy = y;
_movement = 0;

if (mov->_currMovement)
_flags |= 8;
else if (_flags & 8)
_flags ^= 8;

if (_flags & 1)
_flags ^= 1;

_messageQueueId = mqId;
}

void StaticANIObject::show2(int x, int y, int movementId, int mqId) {
Expand Down

0 comments on commit e826d35

Please sign in to comment.