Total Complexity | 3 |
Total Lines | 23 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | from pypen import * |
||
2 | from pypen import _COLORS |
||
3 | |||
4 | def start(): |
||
5 | settings.fps = 120 |
||
6 | |||
7 | |||
8 | colors = [] |
||
9 | |||
10 | colors += _COLORS.values() |
||
11 | colors += _COLORS.keys() |
||
12 | |||
13 | |||
14 | def update(): |
||
15 | global colors |
||
16 | clear() |
||
17 | i = 0 |
||
18 | radius = 10 |
||
19 | for x, y in grid(radius*2): |
||
20 | circle(x, y + cos(TIME*2 + x*0.1)*10, radius, colors[i]) |
||
21 | i += 1 |
||
22 | i %= len(colors) |
||
23 |