main
Alexandre B A Villares 2018-04-22 23:41:40 -03:00
rodzic a05d98b404
commit 3b4e975acf
1 zmienionych plików z 9 dodań i 1 usunięć

Wyświetl plik

@ -15,7 +15,15 @@ If you enjoy this, make a small donation [here](https://www.paypal.com/cgi-bin/w
Hexagons!
```python
def hexagon(x, y, r):
with pushMatrix():
translate(x, y)
beginShape()
for i in range(6):
vx = cos(i * TWO_PI /6) * r
vy = sin(i * TWO_PI /6) * r
vertex(vx, vy)
endShape(CLOSE)
```
----