-
Notifications
You must be signed in to change notification settings - Fork 0
/
FoxAndGeese.kv
96 lines (93 loc) · 2 KB
/
FoxAndGeese.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
#:kivy 1.9.1
<GameController>:
id: fox_and_geese
canvas:
Color:
hsv: 0.5,0.2,0.5
Rectangle:
pos: 0,0
size: self.width, self.height
TitleScreen:
id: title_screen
<TitleScreen>:
Label:
text: "FOX AND GEESE"
pos_hint: {'center_x': 0.5, 'center_y': 0.8}
Button:
text: "Start Game"
pos_hint: {'center_x': 0.5, 'center_y': 0.3}
size_hint: .1,.1
on_release: root.on_release_go_to_mission()
<KivyMissionView>:
id: mission_view
window_width: self.width*0.7
bar_width: self.width*0.3
bar_height: self.height
background_color: 0.1,0.1,0.4
canvas:
Color:
hsv: 0.1,0.1,0.4
Rectangle:
pos: 0, 0
size: self.width*0.7, self.height
Color:
hsv: 0.1,0.1,0.8
Rectangle:
pos: self.width*0.7,0
size: self.width*0.3, self.height
BoxLayout:
orientation: 'vertical'
pos: (mission_view.window_width,0)
size: (mission_view.bar_width,self.height)
padding: 10
spacing: 10
Label:
color: 0,0,0,1
text: "Fox and Geese"
size_hint: 1, 0.5
BoxLayout:
orientation: 'vertical'
padding: 0
BoxLayout:
orientation: 'horizontal'
padding: 0
spacing: 0
Button:
text: "UL"
on_release: root.accept_player_input('UL')
Button:
text: "U"
on_release: root.accept_player_input('U')
Button:
text: "UR"
on_release: root.accept_player_input('UR')
BoxLayout:
orientation: 'horizontal'
padding: 0
spacing: 0
Button:
text: "L"
on_release: root.accept_player_input('L')
Button:
text: "W"
on_release: root.accept_player_input('W')
Button:
text: "R"
on_release: root.accept_player_input('R')
BoxLayout:
orientation: 'horizontal'
padding: 0
spacing: 0
Button:
text: "DL"
on_release: root.accept_player_input('DL')
Button:
text: "D"
on_release: root.accept_player_input('D')
Button:
text: "DR"
on_release: root.accept_player_input('DR')
Button:
text: "Return to title"
size_hint: 1,0.3
on_release: root.on_release_return_to_title()