aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorMatthew Hoops2012-09-09 16:25:45 -0400
committerMatthew Hoops2012-09-09 16:25:45 -0400
commit428702ca49a1fa25d0d439cb764ee9c88a54ee1e (patch)
tree57da86ab9760ee6898d402161e87ee646bac6650 /engines
parent9855f7b5d8a5d6ae0537313ea1f3737f25e4d97f (diff)
downloadscummvm-rg350-428702ca49a1fa25d0d439cb764ee9c88a54ee1e.tar.gz
scummvm-rg350-428702ca49a1fa25d0d439cb764ee9c88a54ee1e.tar.bz2
scummvm-rg350-428702ca49a1fa25d0d439cb764ee9c88a54ee1e.zip
PEGASUS: Fix some formatting issues
Diffstat (limited to 'engines')
-rw-r--r--engines/pegasus/gamestate.h2
-rw-r--r--engines/pegasus/transition.cpp57
2 files changed, 30 insertions, 29 deletions
diff --git a/engines/pegasus/gamestate.h b/engines/pegasus/gamestate.h
index 7812003e15..14ff5335f5 100644
--- a/engines/pegasus/gamestate.h
+++ b/engines/pegasus/gamestate.h
@@ -313,7 +313,7 @@ public:
RoomViewID getCurrentRoomAndView();
void getNextLocation(NeighborhoodID &neighborhood, RoomID &room, DirectionConstant &direction);
- void setNextLocation(const NeighborhoodID neighborhood, const RoomID room, const DirectionConstant direction);
+ void setNextLocation(const NeighborhoodID neighborhood, const RoomID room, const DirectionConstant direction);
NeighborhoodID getNextNeighborhood();
void setNextNeighborhood(const NeighborhoodID neighborhood);
diff --git a/engines/pegasus/transition.cpp b/engines/pegasus/transition.cpp
index 0de63d6080..4bcc4f0a25 100644
--- a/engines/pegasus/transition.cpp
+++ b/engines/pegasus/transition.cpp
@@ -163,36 +163,37 @@ void Slide::drawSlideElement(const Common::Rect &drawRect, const Common::Rect &o
void Push::adjustSlideRects(Common::Rect &oldBounds, Common::Rect &newBounds) {
switch (_direction & kSlideHorizMask) {
- case kSlideLeftMask:
- newBounds.left = oldBounds.right = _bounds.right - pegasusRound(getFaderValue() * _boundsWidth, kTransitionRange);
- newBounds.right = newBounds.left + _boundsWidth;
- oldBounds.left = oldBounds.right - _boundsWidth;
- break;
- case kSlideRightMask:
- oldBounds.left = newBounds.right = _bounds.left + pegasusRound(getFaderValue() * _boundsWidth, kTransitionRange);
- oldBounds.right = oldBounds.left + _boundsWidth;
- newBounds.left = newBounds.right - _boundsWidth;
- break;
- default:
- newBounds.left = oldBounds.left = _bounds.left;
- newBounds.right = oldBounds.right = _bounds.right;
- break;
+ case kSlideLeftMask:
+ newBounds.left = oldBounds.right = _bounds.right - pegasusRound(getFaderValue() * _boundsWidth, kTransitionRange);
+ newBounds.right = newBounds.left + _boundsWidth;
+ oldBounds.left = oldBounds.right - _boundsWidth;
+ break;
+ case kSlideRightMask:
+ oldBounds.left = newBounds.right = _bounds.left + pegasusRound(getFaderValue() * _boundsWidth, kTransitionRange);
+ oldBounds.right = oldBounds.left + _boundsWidth;
+ newBounds.left = newBounds.right - _boundsWidth;
+ break;
+ default:
+ newBounds.left = oldBounds.left = _bounds.left;
+ newBounds.right = oldBounds.right = _bounds.right;
+ break;
}
+
switch (_direction & kSlideVertMask) {
- case kSlideDownMask:
- oldBounds.top = newBounds.bottom = _bounds.top + pegasusRound(getFaderValue() * _boundsHeight, kTransitionRange);
- oldBounds.bottom = oldBounds.top + _boundsHeight;
- newBounds.top = newBounds.bottom - _boundsHeight;
- break;
- case kSlideUpMask:
- newBounds.top = oldBounds.bottom = _bounds.bottom - pegasusRound(getFaderValue() * _boundsHeight, kTransitionRange);
- newBounds.bottom = newBounds.top + _boundsHeight;
- oldBounds.top = oldBounds.bottom - _boundsHeight;
- break;
- default:
- newBounds.top = oldBounds.top = _bounds.top;
- newBounds.bottom = oldBounds.bottom = _bounds.bottom;
- break;
+ case kSlideDownMask:
+ oldBounds.top = newBounds.bottom = _bounds.top + pegasusRound(getFaderValue() * _boundsHeight, kTransitionRange);
+ oldBounds.bottom = oldBounds.top + _boundsHeight;
+ newBounds.top = newBounds.bottom - _boundsHeight;
+ break;
+ case kSlideUpMask:
+ newBounds.top = oldBounds.bottom = _bounds.bottom - pegasusRound(getFaderValue() * _boundsHeight, kTransitionRange);
+ newBounds.bottom = newBounds.top + _boundsHeight;
+ oldBounds.top = oldBounds.bottom - _boundsHeight;
+ break;
+ default:
+ newBounds.top = oldBounds.top = _bounds.top;
+ newBounds.bottom = oldBounds.bottom = _bounds.bottom;
+ break;
}
}