-
Notifications
You must be signed in to change notification settings - Fork 0
/
car.kv
130 lines (121 loc) · 2.61 KB
/
car.kv
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
#:kivy 1.10.1
#:import utils kivy.utils
<Button>:
background_normal: ''
background_color: utils.get_color_from_hex('#0c90c8')
canvas.before:
Color:
rgba: .0, .0, .0, 1
Line:
width: 3
rectangle: self.x, self.y, self.width, self.height
font_size: 32
size: 230, 96
<Agent>:
size: 120, 96
canvas:
PushMatrix
Rotate:
angle: self.angle
origin: self.center
Rectangle:
pos: self.pos
size: self.size
source : './img/agent-4.png'
PopMatrix
<Ball1>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball2>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball3>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball4>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball5>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball6>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Ball7>:
color: 0,0,1,1
size: 12,12
canvas:
Color:
rgba: self.color
Ellipse:
pos: self.pos
size: self.size
<Game>:
agent: game_agent
ball1: game_ball1
ball2: game_ball2
ball3: game_ball3
ball4: game_ball4
ball5: game_ball5
ball6: game_ball6
ball7: game_ball7
Agent:
id: game_agent
center: self.parent.center
Ball1:
id: game_ball1
center: self.parent.center
Ball2:
id: game_ball2
center: self.parent.center
Ball3:
id: game_ball3
center: self.parent.center
Ball4:
id: game_ball4
center: self.parent.center
Ball5:
id: game_ball5
center: self.parent.center
Ball6:
id: game_ball6
center: self.parent.center
Ball7:
id: game_ball7
center: self.parent.center