summaryrefslogtreecommitdiff
path: root/src/gfx.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-05-13 17:39:00 +0000
committerrubidium <rubidium@openttd.org>2009-05-13 17:39:00 +0000
commit5f81ba886c0d1341441d68b3346a374c77aac972 (patch)
tree8a948f402fa6e255d5db8ab2c42b0552ef62dd38 /src/gfx.cpp
parentd23f616e9f2a381c6431d8374d52fe13f5ad5052 (diff)
downloadopenttd-5f81ba886c0d1341441d68b3346a374c77aac972.tar.xz
(svn r16297) -Codechange: silence more ICC warnings
Diffstat (limited to 'src/gfx.cpp')
-rw-r--r--src/gfx.cpp20
1 files changed, 14 insertions, 6 deletions
diff --git a/src/gfx.cpp b/src/gfx.cpp
index 9f762301c..775cd94a5 100644
--- a/src/gfx.cpp
+++ b/src/gfx.cpp
@@ -1058,18 +1058,26 @@ void DoPaletteAnimations()
byte i = (_palette_animation_counter >> 1) & 0x7F;
byte v;
- (v = 255, i < 0x3f) ||
- (v = 128, i < 0x4A || i >= 0x75) ||
- (v = 20);
+ if (i < 0x3f) {
+ v = 255;
+ } else if (i < 0x4A || i >= 0x75) {
+ v = 128;
+ } else {
+ v = 20;
+ }
palette_pos->r = v;
palette_pos->g = 0;
palette_pos->b = 0;
palette_pos++;
i ^= 0x40;
- (v = 255, i < 0x3f) ||
- (v = 128, i < 0x4A || i >= 0x75) ||
- (v = 20);
+ if (i < 0x3f) {
+ v = 255;
+ } else if (i < 0x4A || i >= 0x75) {
+ v = 128;
+ } else {
+ v = 20;
+ }
palette_pos->r = v;
palette_pos->g = 0;
palette_pos->b = 0;