summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-10-07 15:26:20 +0000
committerrubidium <rubidium@openttd.org>2007-10-07 15:26:20 +0000
commitbcd2e7448b05a76946044126e3fd9b1335d34309 (patch)
tree92a690562f78f728ba25b2c189513cfa9557e9c0
parent1bf8d64eb8105361c32a4ec617d45e47ee3acd3e (diff)
downloadopenttd-bcd2e7448b05a76946044126e3fd9b1335d34309.tar.xz
(svn r11225) -Fix: if a sprite shares the bounding box of another sprite, the offset is unsigned instead of signed.
-rw-r--r--src/newgrf_house.cpp2
-rw-r--r--src/newgrf_industrytiles.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/newgrf_house.cpp b/src/newgrf_house.cpp
index b7718ee62..568225667 100644
--- a/src/newgrf_house.cpp
+++ b/src/newgrf_house.cpp
@@ -346,7 +346,7 @@ void DrawTileLayout(const TileInfo *ti, const SpriteGroup *group, byte stage, Ho
HASBIT(_transparent_opt, TO_HOUSES)
);
} else {
- AddChildSpriteScreen(image, pal, dtss->delta_x, dtss->delta_y, HASBIT(_transparent_opt, TO_HOUSES));
+ AddChildSpriteScreen(image, pal, (byte)dtss->delta_x, (byte)dtss->delta_y, HASBIT(_transparent_opt, TO_HOUSES));
}
}
}
diff --git a/src/newgrf_industrytiles.cpp b/src/newgrf_industrytiles.cpp
index 1c1d74199..0e0b77fb8 100644
--- a/src/newgrf_industrytiles.cpp
+++ b/src/newgrf_industrytiles.cpp
@@ -196,7 +196,7 @@ void IndustryDrawTileLayout(const TileInfo *ti, const SpriteGroup *group, byte r
!HASBIT(image, SPRITE_MODIFIER_OPAQUE) && HASBIT(_transparent_opt, TO_INDUSTRIES)
);
} else {
- AddChildSpriteScreen(image, pal, dtss->delta_x, dtss->delta_y, HASBIT(_transparent_opt, TO_INDUSTRIES));
+ AddChildSpriteScreen(image, pal, (byte)dtss->delta_x, (byte)dtss->delta_y, HASBIT(_transparent_opt, TO_INDUSTRIES));
}
}
}