fixing a pile of stupid texel-offset-related bugs
This commit is contained in:
@@ -19,10 +19,10 @@ namespace OpenRa.Game.Graphics
|
|||||||
this.channel = channel;
|
this.channel = channel;
|
||||||
|
|
||||||
uv = new RectangleF(
|
uv = new RectangleF(
|
||||||
(float)(bounds.Left + 0.5f) / sheet.Size.Width,
|
(float)(bounds.Left + .5f) / sheet.Size.Width,
|
||||||
(float)(bounds.Top + 0.5f) / sheet.Size.Height,
|
(float)(bounds.Top + .5f) / sheet.Size.Height,
|
||||||
(float)(bounds.Width) / sheet.Size.Width,
|
(float)(bounds.Width - .5f) / sheet.Size.Width,
|
||||||
(float)(bounds.Height) / sheet.Size.Height);
|
(float)(bounds.Height - .5f) / sheet.Size.Height);
|
||||||
|
|
||||||
uvhax = new float2[]
|
uvhax = new float2[]
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -90,9 +90,6 @@ namespace OpenRa.Game
|
|||||||
Game.CellSize * new float2(starti, j),
|
Game.CellSize * new float2(starti, j),
|
||||||
PaletteType.Shroud,
|
PaletteType.Shroud,
|
||||||
new float2(Game.CellSize * (i - starti), Game.CellSize));
|
new float2(Game.CellSize * (i - starti), Game.CellSize));
|
||||||
r.DrawSprite(sprites[i-1, j],
|
|
||||||
Game.CellSize * new float2(i-1, j),
|
|
||||||
PaletteType.Shroud);
|
|
||||||
starti = i+1;
|
starti = i+1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user