try to make selection feel better
This commit is contained in:
@@ -203,7 +203,7 @@ namespace OpenRA.Editor
|
|||||||
else if (IsPaste)
|
else if (IsPaste)
|
||||||
PasteSelection();
|
PasteSelection();
|
||||||
else
|
else
|
||||||
SelectionEnd = GetBrushLocation();
|
SelectionEnd = GetBrushLocationBR();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void OnMouseDown(MouseEventArgs e)
|
protected override void OnMouseDown(MouseEventArgs e)
|
||||||
@@ -294,6 +294,14 @@ namespace OpenRA.Editor
|
|||||||
return new CPos(vX / TileSet.TileSize, vY / TileSet.TileSize);
|
return new CPos(vX / TileSet.TileSize, vY / TileSet.TileSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public CPos GetBrushLocationBR()
|
||||||
|
{
|
||||||
|
var vX = (int)Math.Floor((MousePos.X - Offset.X) / Zoom);
|
||||||
|
var vY = (int)Math.Floor((MousePos.Y - Offset.Y) / Zoom);
|
||||||
|
return new CPos((vX + TileSet.TileSize - 1) / TileSet.TileSize,
|
||||||
|
(vY + TileSet.TileSize - 1) / TileSet.TileSize);
|
||||||
|
}
|
||||||
|
|
||||||
public void DrawActor(SGraphics g, CPos p, ActorTemplate t, ColorPalette cp)
|
public void DrawActor(SGraphics g, CPos p, ActorTemplate t, ColorPalette cp)
|
||||||
{
|
{
|
||||||
var centered = t.Appearance == null || !t.Appearance.RelativeToTopLeft;
|
var centered = t.Appearance == null || !t.Appearance.RelativeToTopLeft;
|
||||||
|
|||||||
Reference in New Issue
Block a user