Class PointyHexShapeInfo<TCell>
Provides the implementation for AbstractShapeInfo to be used with PointyHexGrid.
public class PointyHexShapeInfo<TCell> : AbstractShapeInfo<PointyHexShapeInfo<TCell>, PointyHexGrid<TCell>, PointyHexPoint, PointyHexPoint, PointyHexOp<TCell>>, IShapeInfo<PointyHexShapeInfo<TCell>, PointyHexGrid<TCell>, PointyHexPoint, PointyHexPoint, PointyHexOp<TCell>>
Type Parameters
TCell
- Inheritance
-
AbstractShapeInfo<PointyHexShapeInfo<TCell>, PointyHexGrid<TCell>, PointyHexPoint, PointyHexPoint, PointyHexOp<TCell>>PointyHexShapeInfo<TCell>
- Implements
-
IShapeInfo<PointyHexShapeInfo<TCell>, PointyHexGrid<TCell>, PointyHexPoint, PointyHexPoint, PointyHexOp<TCell>>
- Inherited Members
- Extension Methods
Constructors
PointyHexShapeInfo(ShapeStorageInfo<PointyHexPoint>)
public PointyHexShapeInfo(ShapeStorageInfo<PointyHexPoint> info)
Parameters
Methods
ArrayPointFromGridPoint(PointyHexPoint)
protected override ArrayPoint ArrayPointFromGridPoint(PointyHexPoint point)
Parameters
point
PointyHexPoint
Returns
EndGroup(PointyHexOp<TCell>)
Only call this method from within a PointyHexOp method (usually, in client code, this will be in an extension).
Since 1.1
public PointyHexShapeInfo<TCell> EndGroup(PointyHexOp<TCell> op)
Parameters
op
PointyHexOp<TCell>The operator on which this shape is defined.
Returns
- PointyHexShapeInfo<TCell>
GridPointFromArrayPoint(ArrayPoint)
protected override PointyHexPoint GridPointFromArrayPoint(ArrayPoint point)
Parameters
point
ArrayPoint
Returns
MakeOp(ShapeStorageInfo<PointyHexPoint>, Func<ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>>)
protected override PointyHexOp<TCell> MakeOp(ShapeStorageInfo<PointyHexPoint> shapeInfo, Func<ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>> combineInfo)
Parameters
shapeInfo
ShapeStorageInfo<PointyHexPoint>combineInfo
Func<ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>, ShapeStorageInfo<PointyHexPoint>>
Returns
- PointyHexOp<TCell>
MakePoint(int, int)
protected override PointyHexPoint MakePoint(int x, int y)
Parameters
Returns
MakeShape(int, int, Func<PointyHexPoint, bool>, PointyHexPoint)
protected override PointyHexGrid<TCell> MakeShape(int x, int y, Func<PointyHexPoint, bool> isInside, PointyHexPoint offset)
Parameters
x
inty
intisInside
Func<PointyHexPoint, bool>offset
PointyHexPoint
Returns
- PointyHexGrid<TCell>
MakeShapeInfo(ShapeStorageInfo<PointyHexPoint>)
protected override PointyHexShapeInfo<TCell> MakeShapeInfo(ShapeStorageInfo<PointyHexPoint> shapeStorageInfo)
Parameters
shapeStorageInfo
ShapeStorageInfo<PointyHexPoint>
Returns
- PointyHexShapeInfo<TCell>