-
Notifications
You must be signed in to change notification settings - Fork 0
/
SnakeGame.rc
313 lines (268 loc) · 22.5 KB
/
SnakeGame.rc
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
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#ifndef APSTUDIO_INVOKED
#include "targetver.h"
#endif
#define APSTUDIO_HIDDEN_SYMBOLS
#include "windows.h"
#undef APSTUDIO_HIDDEN_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// 中文(简体,中国) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
IDC_SNAKEGAME MENU
BEGIN
POPUP "&MENU"
BEGIN
MENUITEM "Start(&S) Enter", IDM_START
MENUITEM "Pause(&P) Space", IDM_PAURES
MENUITEM "Exit(&E) Esc", IDM_EXIT
END
POPUP "&SETTING"
BEGIN
MENUITEM "Armory(&A) Alt+A", IDM_ARMORY
MENUITEM "Difficulty(&D) Alt+D", IDM_DIFFICULTY
END
POPUP "&HELP"
BEGIN
MENUITEM "Help(&H) Alt+H", IDM_HELP
MENUITEM "Game Info.(&G) Alt+G", IDM_ABOUT
END
END
/////////////////////////////////////////////////////////////////////////////
//
// Accelerator
//
IDC_ACCELERATOR ACCELERATORS
BEGIN
VK_RETURN, IDM_START, VIRTKEY, NOINVERT
VK_SPACE, IDM_PAURES, VIRTKEY, NOINVERT
VK_ESCAPE, IDM_EXIT, VIRTKEY, NOINVERT
"^A", IDM_ARMORY, ASCII, ALT, NOINVERT
"^D", IDM_DIFFICULTY, ASCII, ALT, NOINVERT
"^H", IDM_HELP, ASCII, ALT, NOINVERT
"^G", IDM_ABOUT, ASCII, ALT, NOINVERT
END
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_INFO DIALOGEX 0, 0, 214, 86
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "About"
FONT 9, "Segoe Print", 700, 0, 0x0
BEGIN
CTEXT "SnakeGame, Version 1.0",IDC_STATIC,60,3,94,13,SS_NOPREFIX | SS_CENTERIMAGE | SS_REALSIZECONTROL | WS_BORDER,WS_EX_STATICEDGE
LTEXT "Copyright (C) 2016",IDC_STATIC,147,75,65,8,0,WS_EX_TRANSPARENT
DEFPUSHBUTTON "Got it ! (&G)",IDOK,86,61,52,14,WS_GROUP
LTEXT "Producted BY",IDC_STATIC,5,22,51,8
CONTROL IDB_ME,IDC_ME,"Static",SS_BITMAP,162,25,34,26,WS_EX_ACCEPTFILES
CONTROL IDB_SIGN,IDC_SIGN,"Static",SS_BITMAP,60,32,76,18,WS_EX_ACCEPTFILES
END
IDD_ARMORY DIALOGEX 0, 0, 161, 85
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "The Hall of Fame"
FONT 10, "Segoe Print", 700, 0, 0x0
BEGIN
CTEXT "Name",IDC_STATIC,63,3,31,9
CTEXT "Score",IDC_STATIC,112,3,31,9
CTEXT "Champion :",IDC_STATIC,10,17,44,8
CTEXT "Runner-up :",IDC_STATIC,11,35,43,8
CTEXT "Third Place :",IDC_STATIC,10,53,44,8
EDITTEXT IDC_NAME1,59,16,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
EDITTEXT IDC_SCORE1,107,16,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
EDITTEXT IDC_NAME2,59,33,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
EDITTEXT IDC_SCORE2,107,33,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
EDITTEXT IDC_NAME3,59,51,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
EDITTEXT IDC_SCORE3,107,51,40,12,ES_CENTER | ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER
DEFPUSHBUTTON "That's it !",IDOK,26,70,52,10
PUSHBUTTON "Reset it !",IDC_RESET,94,70,36,10
END
IDD_DIFFICULTY DIALOGEX 0, 0, 146, 98
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Difficulty"
FONT 9, "Segoe Print", 700, 0, 0x0
BEGIN
CONTROL "Level 1",IDC_LEVEL1,"Button",BS_AUTORADIOBUTTON,23,7,42,10
CONTROL "Level 2",IDC_LEVEL2,"Button",BS_AUTORADIOBUTTON,23,18,42,10
CONTROL "Level 3",IDC_LEVEL3,"Button",BS_AUTORADIOBUTTON,23,30,42,10
CONTROL "Level 4",IDC_LEVEL4,"Button",BS_AUTORADIOBUTTON,23,41,42,10
CONTROL "Level 5",IDC_LEVEL5,"Button",BS_AUTORADIOBUTTON,23,53,42,10
CONTROL "Level 6",IDC_LEVEL6,"Button",BS_AUTORADIOBUTTON,87,8,42,10
CONTROL "Level 7",IDC_LEVEL7,"Button",BS_AUTORADIOBUTTON,87,19,42,10
CONTROL "Level 8",IDC_LEVEL8,"Button",BS_AUTORADIOBUTTON,87,31,42,10
CONTROL "Level 9",IDC_LEVEL9,"Button",BS_AUTORADIOBUTTON,87,42,42,10
CONTROL "Level 10",IDC_LEVEL10,"Button",BS_AUTORADIOBUTTON,87,54,46,10
DEFPUSHBUTTON "Confirm(&C)",IDOK,21,71,41,12
PUSHBUTTON "Cancel(&B)",IDCANCEL,83,71,43,12
END
IDD_ADDRECORD DIALOGEX 0, 0, 210, 91
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Congratulations !"
FONT 12, "Segoe Print", 700, 0, 0x0
BEGIN
CTEXT "How excellent you are ! You have broken the records !!!",IDC_STATIC,19,5,171,8,0,WS_EX_TRANSPARENT
DEFPUSHBUTTON "This is my name.",IDOK,38,46,124,10
PUSHBUTTON "Forget about it :)",IDCANCEL,64,63,70,9
EDITTEXT IDC_NEWNAME,77,28,48,12,ES_AUTOHSCROLL
CTEXT "Could you please tell me your name?",IDC_STATIC,45,16,115,8,0,WS_EX_TRANSPARENT
END
IDD_HELP DIALOGEX 0, 0, 244, 105
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Help"
FONT 10, "Segoe Print", 700, 0, 0x0
BEGIN
PUSHBUTTON "Got it !",IDOK,101,78,50,12
LTEXT "→ : Turn right",IDC_STATIC,16,11,47,8,0,WS_EX_TRANSPARENT
LTEXT "← : Turn left",IDC_STATIC,16,23,42,8,0,WS_EX_TRANSPARENT
LTEXT "↑ : Turn up",IDC_STATIC,19,35,36,8,0,WS_EX_TRANSPARENT
LTEXT "↓ : Turn down",IDC_STATIC,19,48,45,8
LTEXT "Food. You can increase",IDC_STATIC,152,9,72,8
LTEXT "your score by eating it.",IDC_STATIC,151,20,74,8
LTEXT "Its value is different in different level.",IDC_STATIC,105,33,118,8
LTEXT "REMEMBER : It will be GAME OVER",IDC_STATIC,94,45,116,8
LTEXT "if you bump into the wall",IDC_STATIC,138,54,81,8,0,WS_EX_TRANSPARENT
LTEXT "or bump into yourself...",IDC_STATIC,137,63,74,8,0,WS_EX_TRANSPARENT
CONTROL IDB_FOOD,IDC_FOOD,"Static",SS_BITMAP,114,12,21,15,WS_EX_ACCEPTFILES | WS_EX_TRANSPARENT
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO
BEGIN
IDD_INFO, DIALOG
BEGIN
RIGHTMARGIN, 212
TOPMARGIN, 3
BOTTOMMARGIN, 83
END
IDD_ARMORY, DIALOG
BEGIN
TOPMARGIN, 1
BOTTOMMARGIN, 80
END
IDD_DIFFICULTY, DIALOG
BEGIN
LEFTMARGIN, 9
RIGHTMARGIN, 136
TOPMARGIN, 5
BOTTOMMARGIN, 89
END
IDD_ADDRECORD, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 203
TOPMARGIN, 3
BOTTOMMARGIN, 84
END
IDD_HELP, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 237
TOPMARGIN, 7
BOTTOMMARGIN, 98
END
END
#endif // APSTUDIO_INVOKED
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#ifndef APSTUDIO_INVOKED\r\n"
"#include ""targetver.h""\r\n"
"#endif\r\n"
"#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
"#include ""windows.h""\r\n"
"#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Bitmap
//
IDB_BACKGROUND BITMAP "Resource\\Background.bmp"
IDB_GAMEOVER BITMAP "Resource\\Gameover.bmp"
IDB_ME BITMAP "Resource\\ME.bmp"
IDB_SIGN BITMAP "Resource\\SIGN.bmp"
IDB_FOOD BITMAP "Resource\\apple.bmp"
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_APPLE ICON "Resource\\apple.ico"
IDI_BODY ICON "Resource\\BODY.ICO"
IDI_BODYLEVEL ICON "Resource\\BODYLEVEL.ICO"
IDI_BODYVERTICAL ICON "Resource\\BODYVERTICAL.ICO"
IDI_GAMEICON ICON "Resource\\GameIcon.ico"
IDI_SCORE0 ICON "Resource\\Score0.ICO"
IDI_SCORE1 ICON "Resource\\Score1.ICO"
IDI_SCORE2 ICON "Resource\\Score2.ICO"
IDI_SCORE3 ICON "Resource\\Score3.ICO"
IDI_SCORE4 ICON "Resource\\Score4.ICO"
IDI_SCORE5 ICON "Resource\\Score5.ICO"
IDI_SCORE6 ICON "Resource\\Score6.ICO"
IDI_SCORE7 ICON "Resource\\Score7.ICO"
IDI_SCORE8 ICON "Resource\\Score8.ICO"
IDI_SCORE9 ICON "Resource\\Score9.ICO"
IDI_HEADDOWN ICON "Resource\\headdown.ico"
IDI_HEADDOWN_DEAD ICON "Resource\\headdown_dead.ico"
IDI_HEADLEFT ICON "Resource\\headleft.ico"
IDI_HEADLEFT_DEAD ICON "Resource\\headleft_dead.ico"
IDI_HEADRIGHT ICON "Resource\\headright.ico"
IDI_HEADRIGHT_DEAD ICON "Resource\\headright_dead.ico"
IDI_HEADUP ICON "Resource\\headup.ico"
IDI_HEADUP_DEAD ICON "Resource\\headup_dead.ico"
/////////////////////////////////////////////////////////////////////////////
//
// WAVE
//
IDR_EAT WAVE "Resource\\Eat.wav"
IDR_GAMEOVER WAVE "Resource\\GameOver.wav"
IDR_BGM WAVE "Resource\\TheMass.wav"
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE
BEGIN
IDS_APP_TITLE "Snake Game"
IDC_SNAKEGAME "SNAKEGAME"
END
#endif // 中文(简体,中国) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED