Daily update on 20231211 by nitload youmu
This commit is contained in:
@@ -32,19 +32,29 @@ namespace StgSharp.Geometries
|
||||
|
||||
public Line() { }
|
||||
|
||||
//method to calculate begin point of the the line
|
||||
/// <summary>
|
||||
/// Move begin side of a line.
|
||||
/// It is recommended to override this function rather than
|
||||
/// loading an <see cref="GetLocationHandler"/> with same function.
|
||||
/// </summary>
|
||||
/// <param name="tick">Time passed since current line was created.</param>
|
||||
public virtual vec3d MoveBeginPoint(uint tick)
|
||||
=> movBegin.Invoke(tick);
|
||||
=> movBegin.Invoke(time);
|
||||
|
||||
//计算线重点的方法,通过对线的派生的重写实现功能
|
||||
/// <summary>
|
||||
/// Move end side of a line.
|
||||
/// It is recommended to override this function rather than
|
||||
/// loading an <see cref="GetLocationHandler"/> with same function.
|
||||
/// </summary>
|
||||
/// <param name="tick">Time passed since current line was created.</param>
|
||||
/// <returns></returns>
|
||||
public virtual vec3d MoveEndPoint(uint tick)
|
||||
=> movEnd.Invoke(tick);
|
||||
=> movEnd.Invoke(time);
|
||||
|
||||
internal override void UpdateCoordinate(uint tick)
|
||||
{
|
||||
tick -= bornTick;
|
||||
beginPoint.Position = coordinate.origin + MoveBeginPoint(tick);
|
||||
endPoint.Position = coordinate.origin + MoveEndPoint(tick);
|
||||
beginPoint.Position = coordinate.origin + MoveBeginPoint(time);
|
||||
endPoint.Position = coordinate.origin + MoveEndPoint(time);
|
||||
}
|
||||
|
||||
public override Line[] GetAllSides()
|
||||
|
||||
Reference in New Issue
Block a user