diff options
author | Christoph Mallon | 2011-05-18 14:40:49 +0200 |
---|---|---|
committer | Max Horn | 2011-05-18 15:30:23 +0200 |
commit | f143668db4b0bb1efee9e97fc3b764cb90489c3a (patch) | |
tree | 7467107d0cd5cb4d5f76d9d69044740d47657985 /engines/tinsel/cliprect.cpp | |
parent | 9c01c385124e80cce56504b57d5fc17b863ee601 (diff) | |
download | scummvm-rg350-f143668db4b0bb1efee9e97fc3b764cb90489c3a.tar.gz scummvm-rg350-f143668db4b0bb1efee9e97fc3b764cb90489c3a.tar.bz2 scummvm-rg350-f143668db4b0bb1efee9e97fc3b764cb90489c3a.zip |
TINSEL: Correctly handle the pDispList OBJECT linked lists, i.e. use OBJECT** for a pointer to the head.
Signed-off-by: Max Horn <max@quendi.de>
Diffstat (limited to 'engines/tinsel/cliprect.cpp')
-rw-r--r-- | engines/tinsel/cliprect.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/tinsel/cliprect.cpp b/engines/tinsel/cliprect.cpp index 34724c4b77..f8d8011b12 100644 --- a/engines/tinsel/cliprect.cpp +++ b/engines/tinsel/cliprect.cpp @@ -105,10 +105,10 @@ static bool LooseIntersectRectangle(const Common::Rect &pSrc1, const Common::Rec * @param bNoVelocity When reset, objects pos is updated with velocity * @param bScrolled) When set, playfield has scrolled */ -void FindMovingObjects(OBJECT *pObjList, Common::Point *pWin, Common::Rect *pClip, bool bNoVelocity, bool bScrolled) { +void FindMovingObjects(OBJECT **pObjList, Common::Point *pWin, Common::Rect *pClip, bool bNoVelocity, bool bScrolled) { OBJECT *pObj; // object list traversal pointer - for (pObj = pObjList->pNext; pObj != NULL; pObj = pObj->pNext) { + for (pObj = *pObjList; pObj != NULL; pObj = pObj->pNext) { if (!bNoVelocity) { // we want to add velocities to objects position @@ -203,7 +203,7 @@ void MergeClipRect() { * @param pWin Window top left position * @param pClip Pointer to clip rectangle */ -void UpdateClipRect(OBJECT *pObjList, Common::Point *pWin, Common::Rect *pClip) { +void UpdateClipRect(OBJECT **pObjList, Common::Point *pWin, Common::Rect *pClip) { int x, y, right, bottom; // object corners int hclip, vclip; // total size of object clipping DRAWOBJECT currentObj; // filled in to draw the current object in list @@ -212,7 +212,7 @@ void UpdateClipRect(OBJECT *pObjList, Common::Point *pWin, Common::Rect *pClip) // Initialise the fields of the drawing object to empty memset(¤tObj, 0, sizeof(DRAWOBJECT)); - for (pObj = pObjList->pNext; pObj != NULL; pObj = pObj->pNext) { + for (pObj = *pObjList; pObj != NULL; pObj = pObj->pNext) { if (pObj->flags & DMA_ABS) { // object position is absolute x = fracToInt(pObj->xPos); |