Update ItemData.cs
Fixed EDGE case where Shape.Inset would cut off columns of the inset shape when inset position was close the rightmost EDGE of parent shape.
This commit is contained in:
parent
219bafd8da
commit
eaedf0cee8
1 changed files with 1 additions and 1 deletions
|
|
@ -154,7 +154,7 @@ public class Shape
|
|||
|
||||
public Shape Inset(Shape inset, int2 insetPosition, ItemRotation rotation = ItemRotation.None)
|
||||
{
|
||||
var shape = new Shape(Width, Height);
|
||||
var shape = new Shape(max(Width,insetPosition.x + inset.Width - 1), max(Height, insetPosition.y + inset.Height - 1));
|
||||
foreach (var v in inset.Coordinates)
|
||||
{
|
||||
var insetCoord = inset.Rotate(v, rotation) + insetPosition;
|
||||
|
|
|
|||
Loading…
Reference in a new issue