fixed wrong palette remapping for neutral buildings in editor

for TEMPERAT (fields) and DESERT (buildings, trees, rocks)
This commit is contained in:
Matthias Mailänder
2012-11-26 12:21:50 +01:00
parent 4e0e53c714
commit aad0b3d2d8
5 changed files with 31 additions and 15 deletions

View File

@@ -308,7 +308,10 @@ namespace OpenRA.Editor
public void DrawActor(SGraphics g, CPos p, ActorTemplate t, ColorPalette cp)
{
var centered = t.Appearance == null || !t.Appearance.RelativeToTopLeft;
DrawImage(g, t.Bitmap, p, centered, cp);
var actorPalette = cp;
if (t.Appearance != null && t.Appearance.UseTerrainPalette)
actorPalette = Palette.AsSystemPalette();
DrawImage(g, t.Bitmap, p, centered, actorPalette);
}
float2 GetDrawPosition(CPos location, Bitmap bmp, bool centered)