aboutsummaryrefslogtreecommitdiff
path: root/engines/wintermute/Base/BFader.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/wintermute/Base/BFader.cpp')
-rw-r--r--engines/wintermute/Base/BFader.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/wintermute/Base/BFader.cpp b/engines/wintermute/Base/BFader.cpp
index cd78ece27a..b20d377e93 100644
--- a/engines/wintermute/Base/BFader.cpp
+++ b/engines/wintermute/Base/BFader.cpp
@@ -72,7 +72,7 @@ HRESULT CBFader::Update() {
if (time >= _duration) _currentAlpha = _targetAlpha;
else {
- _currentAlpha = _sourceAlpha + (float)time / (float)_duration * AlphaDelta;
+ _currentAlpha = (byte)(_sourceAlpha + (float)time / (float)_duration * AlphaDelta);
}
_currentAlpha = MIN((unsigned char)255, MAX(_currentAlpha, (byte)0)); // TODO: clean