Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
31 | halyavin | 1 | draw_menu: |
2 | |||
3 | cmp byte[menu],'0' |
||
4 | jne menu1 |
||
5 | |||
6 | mov eax,4 |
||
7 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-39)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*4) |
||
8 | mov ecx,0x10ffff00 |
||
9 | mov edx,startgame |
||
10 | mov esi,instr-startgame |
||
11 | int 0x40 |
||
12 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-84)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*5) |
||
13 | mov ecx,0x10ff0000 |
||
14 | mov edx,instr |
||
15 | mov esi,hist-instr |
||
16 | int 0x40 |
||
17 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-50)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*6) |
||
18 | mov ecx,0x10ff0000 |
||
19 | mov edx,hist |
||
20 | mov esi,quit-hist |
||
21 | int 0x40 |
||
22 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-26)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*7) |
||
23 | mov ecx,0x10ff0000 |
||
24 | mov edx,quit |
||
25 | mov esi,paused-quit |
||
26 | int 0x40 |
||
27 | |||
28 | menu1: |
||
29 | cmp byte[menu],'1' |
||
30 | jne menu2 |
||
31 | |||
32 | |||
33 | mov eax,4 |
||
34 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-39)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*4) |
||
35 | mov ecx,0x10ff0000 |
||
36 | mov edx,startgame |
||
37 | mov esi,instr-startgame |
||
38 | int 0x40 |
||
39 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-84)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*5) |
||
40 | mov ecx,0x10ffff00 |
||
41 | mov edx,instr |
||
42 | mov esi,hist-instr |
||
43 | int 0x40 |
||
44 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-50)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*6) |
||
45 | mov ecx,0x10ff0000 |
||
46 | mov edx,hist |
||
47 | mov esi,quit-hist |
||
48 | int 0x40 |
||
49 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-26)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*7) |
||
50 | mov ecx,0x10ff0000 |
||
51 | mov edx,quit |
||
52 | mov esi,paused-quit |
||
53 | int 0x40 |
||
54 | |||
55 | menu2: |
||
56 | cmp byte[menu],'2' |
||
57 | jne menu3 |
||
58 | |||
59 | mov eax,4 |
||
60 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-39)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*4) |
||
61 | mov ecx,0x10ff0000 |
||
62 | mov edx,startgame |
||
63 | mov esi,instr-startgame |
||
64 | int 0x40 |
||
65 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-84)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*5) |
||
66 | mov ecx,0x10ff0000 |
||
67 | mov edx,instr |
||
68 | mov esi,hist-instr |
||
69 | int 0x40 |
||
70 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-50)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*6) |
||
71 | mov ecx,0x10ffff00 |
||
72 | mov edx,hist |
||
73 | mov esi,quit-hist |
||
74 | int 0x40 |
||
75 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-26)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*7) |
||
76 | mov ecx,0x10ff0000 |
||
77 | mov edx,quit |
||
78 | mov esi,paused-quit |
||
79 | int 0x40 |
||
80 | |||
81 | menu3: |
||
82 | cmp byte[menu],'3' |
||
83 | jne menu4 |
||
84 | |||
85 | mov eax,4 |
||
86 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-39)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*4) |
||
87 | mov ecx,0x10ff0000 |
||
88 | mov edx,startgame |
||
89 | mov esi,instr-startgame |
||
90 | int 0x40 |
||
91 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-84)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*5) |
||
92 | mov ecx,0x10ff0000 |
||
93 | mov edx,instr |
||
94 | mov esi,hist-instr |
||
95 | int 0x40 |
||
96 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-50)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*6) |
||
97 | mov ecx,0x10ff0000 |
||
98 | mov edx,hist |
||
99 | mov esi,quit-hist |
||
100 | int 0x40 |
||
101 | mov ebx,((LEN_X-BORDER_LEFT-BORDER_RIGHT)*ADOBE_SIZE+X_LOCATION*2+98-26)/2*65536+(((LEN_Y-BORDER_TOP-BORDER_BOTTOM)*ADOBE_SIZE+Y_LOCATION-2)/8*7) |
||
102 | mov ecx,0x10ffff00 |
||
103 | mov edx,quit |
||
104 | mov esi,paused-quit |
||
105 | int 0x40 |
||
106 | |||
107 | menu4: |
||
108 | |||
109 | |||
110 | ret |
||
111 | |||
112 | exemenu: |
||
113 | cmp byte[menu],'0' ;start |
||
114 | jne exemenu1 |
||
115 | call new_game |
||
116 | |||
117 | exemenu1: |
||
118 | cmp byte[menu],'1' ;instr |
||
119 | jne exemenu2 |
||
120 | mov byte[status],'4' |
||
121 | call draw_window |
||
122 | |||
123 | exemenu2: |
||
124 | cmp byte[menu],'2' ;history |
||
125 | jne exemenu3 |
||
126 | mov byte[status],'3' |
||
127 | call draw_window |
||
128 | |||
129 | exemenu3: |
||
130 | cmp byte[menu],'3' ;exit |
||
131 | jne exemenu4 |
||
132 | mov eax,-1 |
||
133 | int 0x40 |
||
134 | |||
135 | exemenu4: |
||
136 | |||
137 | ret |