2
* This file is part of the dis-Emi-A HaXe Library. Copyright © edA-qa mort-ora-y
3
* For full copyright and license information please refer to doc/license.txt.
6
package draw.fragments;
8
//TODO: Merge with Actor Polygon (with new Shape framework we can make the actor now use this Shape)
11
PARAM(sides,Int,5,`The number of sides for the polygon')
12
PARAM(angleStart,Float,0,`Which orientation the polygon has, where the first vertex is drawn')
16
var angD = Math.PI*2 / sides;
17
var pts = new Array<Point2>();
21
Math.cos( angleStart + i * angD )/2.0,
22
Math.sin( angleStart + i * angD )/2.0
25
gfx.polyLine( pts, true );