{{htmlmetatags>metatag-robots=() metatag-title=(POLYLINE | ugBASIC User Manual) metatag-keywords=(ugBASIC,Commodore 64,Commodore PLUS/4,ZX Spectrum) metatag-description=(Manual page for POLYLINE) metatag-media-og:image=(:ugbasic:logo-ugbasic-fb.png) metatag-og:title=(POLYLINE | ugBASIC User Manual) metatag-og:description=(Manual page for POLYLINE) }} ====== ugBASIC User Manual ====== ===== POLYLINE ✓ ===== ===== SYNTAX ===== POLYLINE { [x1] },{ [y1] } TO { [x2] },{ [x2] } { TO ... },{ [c] } POLYLINE { [x1] },{ [y1] } TO { [x2] },{ [x2] } { TO ... } POLYLINE TO { [x2] },{ [x2] } { TO ... },{ [c] } POLYLINE TO { [x2] },{ [x2] } { TO ... } ==== PURPOSE ==== This instruction draws a polyline, that is a line formed by multiple lines, on the screen, starting from the coordinates ''(x1, y1)'' to arrive at the coordinates ''(xn, yn)'', using the color ''c''. The start can be omitted: in this case, ugBASIC will draw starting from the last drawn position. If the color is omitted, the last color selected with the ''INK'' or ''PEN'' command will be used. Finally, the default line style is full but a 16 bit bitmask can be set with the ''SET LINE'' command. ==== EXAMPLE ==== POLYLINE 10,10 TO 20,20 TO 20,30 TO 20,10, WHITE See also the following example files: * ''[[https://github.com/spotlessmind1975/ugbasic/tree/main/examples/graphics_shapes_01.bas|graphics_shapes_01.bas]]'' ==== ABBREVIATION ==== Ply ==== AVAILABLE ON ==== * Commodore 64 * ZX Spectrum 48K * Commodore PLUS/4 * Atari (400/800/XL) * Dragon 32 * Dragon 64 * PC128 Olivetti Prodest * Thomson MO5 * Commodore VIC-20 * MSX 1 * ColecoVision * SEGA SC-3000 * SEGA SG-1000 ==== ANY PROBLEM? ==== If you have encountered a problem using this command, if you think there is a bug or the explanation is unclear, please [[https://github.com/spotlessmind1975/ugbasic/issues/new?title=ISSUE ON POLYLINE|open an issue]] for this keyword on GitHub. Thank you!===== POWERED BY ===== [[:ugbasic:user:index|{{ :ugbasic:user:logo-ugbasic.png?nolink&600 |}}]]