mirror of
https://git.do.srb2.org/STJr/ZoneBuilder.git
synced 2025-02-21 11:21:26 +00:00
Edit Selection mode: add actions for moving the selection around the grid.
This commit is contained in:
parent
af673f3270
commit
8c290a9e7c
2 changed files with 88 additions and 0 deletions
|
@ -1910,6 +1910,54 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
||||||
General.Interface.RedrawDisplay();
|
General.Interface.RedrawDisplay();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[BeginAction("moveselectionup")]
|
||||||
|
public void MoveSelectionUp()
|
||||||
|
{
|
||||||
|
offset.y += General.Map.Grid.GridSize;
|
||||||
|
|
||||||
|
// Update
|
||||||
|
UpdateGeometry();
|
||||||
|
UpdateRectangleComponents();
|
||||||
|
General.Map.Map.Update();
|
||||||
|
General.Interface.RedrawDisplay();
|
||||||
|
}
|
||||||
|
|
||||||
|
[BeginAction("moveselectiondown")]
|
||||||
|
public void MoveSelectionDown()
|
||||||
|
{
|
||||||
|
offset.y -= General.Map.Grid.GridSize;
|
||||||
|
|
||||||
|
// Update
|
||||||
|
UpdateGeometry();
|
||||||
|
UpdateRectangleComponents();
|
||||||
|
General.Map.Map.Update();
|
||||||
|
General.Interface.RedrawDisplay();
|
||||||
|
}
|
||||||
|
|
||||||
|
[BeginAction("moveselectionleft")]
|
||||||
|
public void MoveSelectionLeft()
|
||||||
|
{
|
||||||
|
offset.x -= General.Map.Grid.GridSize;
|
||||||
|
|
||||||
|
// Update
|
||||||
|
UpdateGeometry();
|
||||||
|
UpdateRectangleComponents();
|
||||||
|
General.Map.Map.Update();
|
||||||
|
General.Interface.RedrawDisplay();
|
||||||
|
}
|
||||||
|
|
||||||
|
[BeginAction("moveselectionright")]
|
||||||
|
public void MoveSelectionRight()
|
||||||
|
{
|
||||||
|
offset.x += General.Map.Grid.GridSize;
|
||||||
|
|
||||||
|
// Update
|
||||||
|
UpdateGeometry();
|
||||||
|
UpdateRectangleComponents();
|
||||||
|
General.Map.Map.Update();
|
||||||
|
General.Interface.RedrawDisplay();
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1325,6 +1325,46 @@ flipselectionh
|
||||||
allowscroll = true;
|
allowscroll = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
moveselectionup
|
||||||
|
{
|
||||||
|
title = "Move Selection Up by grid size";
|
||||||
|
category = "edit";
|
||||||
|
description = "Moves the selection in Edit Selection mode up by the current grid size.";
|
||||||
|
allowkeys = true;
|
||||||
|
allowmouse = true;
|
||||||
|
allowscroll = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
moveselectiondown
|
||||||
|
{
|
||||||
|
title = "Move Selection Down by grid size";
|
||||||
|
category = "edit";
|
||||||
|
description = "Moves the selection in Edit Selection mode down by the current grid size.";
|
||||||
|
allowkeys = true;
|
||||||
|
allowmouse = true;
|
||||||
|
allowscroll = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
moveselectionleft
|
||||||
|
{
|
||||||
|
title = "Move Selection Left by grid size";
|
||||||
|
category = "edit";
|
||||||
|
description = "Moves the selection in Edit Selection mode left by the current grid size.";
|
||||||
|
allowkeys = true;
|
||||||
|
allowmouse = true;
|
||||||
|
allowscroll = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
moveselectionright
|
||||||
|
{
|
||||||
|
title = "Move Selection Right by grid size";
|
||||||
|
category = "edit";
|
||||||
|
description = "Moves the selection in Edit Selection mode right by the current grid size.";
|
||||||
|
allowkeys = true;
|
||||||
|
allowmouse = true;
|
||||||
|
allowscroll = true;
|
||||||
|
}
|
||||||
|
|
||||||
//mxd
|
//mxd
|
||||||
rotateclockwise
|
rotateclockwise
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue