Daily update on 20230413 by nitload youmu

This commit is contained in:
Nitload
2023-04-13 01:37:16 +08:00
parent 2e1b0fe351
commit de494a35e6
45 changed files with 294 additions and 206 deletions
+48
View File
@@ -0,0 +1,48 @@
using System;
using System.Collections.Generic;
using System.Numerics;
using System.Text;
namespace StgSharp.Geometries
{
public class Polygon : IGeometryCombination
{
internal Point[] pointsArray;
public Polygon(uint bornTime) : base(bornTime)
{
}
public Polygon(int pointNum)
{
pointsArray = new Point[pointNum];
this.toSimpleGeometry();
}
public Polygon(Point[] pointsArray)
{
PointsArray = pointsArray;
this.toSimpleGeometry();
}
internal override void toSimpleGeometry()
{
Point begin = pointsArray[0];
for (int i = 1; i <= pointsArray.Length; i++)
{
Triangle a = new Triangle(this._bornTick);
this.Add(a);
}
}
public Point[] PointsArray
{
get { return pointsArray; }
set { pointsArray = value; }
}
}
}