aboutsummaryrefslogtreecommitdiff
path: root/engines/tinsel
diff options
context:
space:
mode:
Diffstat (limited to 'engines/tinsel')
-rw-r--r--engines/tinsel/polygons.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/tinsel/polygons.cpp b/engines/tinsel/polygons.cpp
index 69031d7a9b..cb5b21f0c0 100644
--- a/engines/tinsel/polygons.cpp
+++ b/engines/tinsel/polygons.cpp
@@ -1336,11 +1336,11 @@ static bool MatchingLevels(PPOLYGON p1, PPOLYGON p2) {
Poly pp1(pps, p1->pIndex); // This polygon 1
Poly pp2(pps, p2->pIndex); // This polygon 2
- assert(pp1.level1 <= pp1.level2);
- assert(pp2.level1 <= pp2.level2);
+ assert((int32)FROM_LE_32(pp1.level1) <= (int32)FROM_LE_32(pp1.level2));
+ assert((int32)FROM_LE_32(pp2.level1) <= (int32)FROM_LE_32(pp2.level2));
- for (int pl = pp1.level1; pl <= pp1.level2; pl++) {
- if (pl >= pp2.level1 && pl <= pp2.level2)
+ for (int pl = (int32)FROM_LE_32(pp1.level1); pl <= (int32)FROM_LE_32(pp1.level2); pl++) {
+ if (pl >= (int32)FROM_LE_32(pp2.level1) && pl <= (int32)FROM_LE_32(pp2.level2))
return true;
}