[Scummvm-cvs-logs] scummvm master -> 3fee10eb604d31aa731362404fc7eaa080032642

dreammaster dreammaster at scummvm.org
Wed Apr 20 15:03:33 CEST 2011


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
3fee10eb60 TSAGE: Cleaner bugfix for text colours being incorrect


Commit: 3fee10eb604d31aa731362404fc7eaa080032642
    https://github.com/scummvm/scummvm/commit/3fee10eb604d31aa731362404fc7eaa080032642
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2011-04-20T06:02:07-07:00

Commit Message:
TSAGE: Cleaner bugfix for text colours being incorrect

Changed paths:
    engines/tsage/converse.cpp
    engines/tsage/core.cpp



diff --git a/engines/tsage/converse.cpp b/engines/tsage/converse.cpp
index 18ba28d..57c5c48 100644
--- a/engines/tsage/converse.cpp
+++ b/engines/tsage/converse.cpp
@@ -791,7 +791,6 @@ Speaker::Speaker() : EventHandler() {
 	_fontNumber = 2;
 	_textMode = ALIGN_LEFT;
 	_color1 = _color2 = _color3 = _globals->_scenePalette._colors.foreground;
-	_color2 = _color3 = 0;
 	_action = NULL;
 	_speakerName = "SPEAKER";
 }
diff --git a/engines/tsage/core.cpp b/engines/tsage/core.cpp
index d064917..1b38599 100644
--- a/engines/tsage/core.cpp
+++ b/engines/tsage/core.cpp
@@ -1300,7 +1300,7 @@ uint8 ScenePalette::indexOf(uint r, uint g, uint b, int threshold) {
 		int bDiff = abs(ib - (int)b);
 
 		int idxThreshold = rDiff * rDiff + gDiff * gDiff + bDiff * bDiff;
-		if (idxThreshold <= threshold) {
+		if (idxThreshold < threshold) {
 			threshold = idxThreshold;
 			palIndex = i;
 		}






More information about the Scummvm-git-logs mailing list