C# Class Danmaku_no_Kyojin.Shapes.PolygonShape

Afficher le fichier Open project: Noxalus/Danmaku-no-Kyojin Class Usage Examples

Méthodes publiques

Méthode Description
Draw ( Matrix viewMatrix, Vector2 position, Color color, float rotation, Vector2 origin, Vector2 scale ) : void
GetArea ( ) : float
GetCenter ( ) : Vector2
GetSize ( ) : Vector2
PolygonShape ( DnK game, Vector2 vertices ) : System

A Polygon object that you will be able to draw. Animations are being implemented as we speak.

UpdateVertices ( Vector2 vertices ) : void

Private Methods

Méthode Description
ComputeArea ( ) : void
ComputeCenter ( ) : void
ComputeSize ( ) : void
Triangulate ( ) : void

Triangulate the set of VertexPositionColors so it will be drawn properly

Method Details

Draw() public méthode

public Draw ( Matrix viewMatrix, Vector2 position, Color color, float rotation, Vector2 origin, Vector2 scale ) : void
viewMatrix Matrix
position Vector2
color Color
rotation float
origin Vector2
scale Vector2
Résultat void

GetArea() public méthode

public GetArea ( ) : float
Résultat float

GetCenter() public méthode

public GetCenter ( ) : Vector2
Résultat Vector2

GetSize() public méthode

public GetSize ( ) : Vector2
Résultat Vector2

PolygonShape() public méthode

A Polygon object that you will be able to draw. Animations are being implemented as we speak.
public PolygonShape ( DnK game, Vector2 vertices ) : System
game DnK
vertices Vector2 The vertices in a clockwise order
Résultat System

UpdateVertices() public méthode

public UpdateVertices ( Vector2 vertices ) : void
vertices Vector2
Résultat void