From a854c7e274e1cd5ed77b219762eea6d4d67c47be Mon Sep 17 00:00:00 2001 From: Colin Snover Date: Sun, 16 Oct 2016 21:18:59 -0500 Subject: SCI32: Fix screen items incorrectly drawing over higher planes Fixes Trac#9583. --- engines/sci/graphics/plane32.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'engines/sci') diff --git a/engines/sci/graphics/plane32.cpp b/engines/sci/graphics/plane32.cpp index e7da8b815d..7dfaed4243 100644 --- a/engines/sci/graphics/plane32.cpp +++ b/engines/sci/graphics/plane32.cpp @@ -191,7 +191,7 @@ void Plane::addPicInternal(const GuiResourceId pictureId, const Common::Point *p delete screenItem->_celObj; screenItem->_celObj = celObj; } - _type = transparent ? kPlaneTypeTransparentPicture : kPlaneTypePicture; + _type = (getSciVersion() == SCI_VERSION_3 && transparent) ? kPlaneTypeTransparentPicture : kPlaneTypePicture; } GuiResourceId Plane::addPic(const GuiResourceId pictureId, const Common::Point &position, const bool mirrorX, const bool deleteDuplicate) { @@ -751,8 +751,12 @@ void Plane::setType() { _type = kPlaneTypeOpaque; break; case kPlanePicTransparentPicture: - _type = kPlaneTypeTransparentPicture; - break; + if (getSciVersion() == SCI_VERSION_3) { + warning("TODO: Using transparent picture plane. Rendering may be incomplete"); + _type = kPlaneTypeTransparentPicture; + break; + } + // fall through for sci2/2.1 default: if (_type != kPlaneTypeTransparentPicture) { _type = kPlaneTypePicture; -- cgit v1.2.3