Polygon:addPoint: Difference between revisions
From GiderosMobile
Created page with "__NOTOC__ '''Available since:''' Gideros 2015.03.22<br/> '''Class:''' Clipper<br/> === Description === Appends a vertex to the polygon. <syntaxhighlight lang="lua"> Polyg..." |
No edit summary |
||
| Line 6: | Line 6: | ||
Appends a vertex to the polygon. | Appends a vertex to the polygon. | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua"> | ||
Polygon:addPoint(x, y) | Polygon:addPoint(x,y) | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Latest revision as of 22:06, 14 November 2026
Available since: Gideros 2015.03.22
Class: Clipper
Description
Appends a vertex to the polygon.
Polygon:addPoint(x,y)
Points are stored in the order they are added; the polygon is implicitly closed (last point to first point) when used by Clipper or by getArea().
Parameters
x: (number) horizontal coordinate, stored as an integer
y: (number) vertical coordinate, stored as an integer