-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshow_animation.py
More file actions
42 lines (35 loc) · 989 Bytes
/
show_animation.py
File metadata and controls
42 lines (35 loc) · 989 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
from microbit import *
Red=(2, 0, 0)
love1 = Image("01010:"
"10101:"
"01010:"
"00100:"
"00000")
love2 = Image("00000:"
"01010:"
"10101:"
"01010:"
"00100")
love3 = Image("00000:"
"00000:"
"01010:"
"10101:"
"01010")
love4 = Image("00000:"
"00000:"
"00000:"
"01010:"
"10101")
love5 = Image("00000:"
"00000:"
"00000:"
"00000:"
"01010")
love6 = Image("00000:"
"00000:"
"00000:"
"00000:"
"00000")
all_loves = [love1, love2, love3, love4, love5, love6]
display.show(all_loves, delay=500, loop=True,color=Red) # 通过 `loop=True`,使Python 保持循环状态
# `delay=100`设置这个动画切换图片的时间