Tools.drawGlobalPoly
Appearance
| Environment: | Mission Scripting | |
|---|---|---|
| Function: | tools.drawGlobalPoly | |
| Function Description: | Draws a set of global vec3 points as a single drawing. | |
| File Location: | cmm.tools.lua | |
| Syntax: | CMM.tools.drawGlobalPoly( table PointsArray , table Line , table Fill ) | |
| Return Value: | nil | |
| Parameters: | Name | Description |
| PointsArray | Table of relative point definitions, each containing 'dir' and 'range' fields specifying direction and distance to offset from the base position. | |
| Line | R,G,B,A values for line color (0-1 range) | |
| Fill | R,G,B,A values for fill color (0-1 range | |
| Example: | CMM.tools.drawPoly({x=100, y=200, z=0}, {{dir={x=1, y=0, z=0}, range=50}, {dir={x=0, y=1, z=0}, range=30}}) | |
| Example Description: | Creates a polygon with two relative points, one to the right and one upward from the base position, drawing a visible shape with default line and fill colors. | |
| Related Functions: | ||
| Notes: | ||