Subversion Repositories Kolibri OS

Rev

Rev 552 | Rev 2677 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 552 Rev 2062
1
;
1
;
2
;   Phenix Dynamic Game Created by Pavlushin Evgeni for ASCL
2
;   Phenix Dynamic Game Created by Pavlushin Evgeni for ASCL
3
;
3
;
4
;   100% Full relase!
4
;   100% Full relase!
5
;
5
;
6
;   www.waptap@mail.ru
6
;   www.waptap@mail.ru
7
;
7
;
8
 
8
 
9
 
9
 
10
;******************************************************************************
10
;******************************************************************************
11
    use32
11
    use32
12
    org    0x0
12
    org    0x0
13
    db     'MENUET01'              ; 8 byte id
13
    db     'MENUET01'              ; 8 byte id
14
    dd     0x01                    ; header version
14
    dd     0x01                    ; header version
15
    dd     START                   ; start of code
15
    dd     START                   ; start of code
16
    dd     IM_END                  ; size of image
16
    dd     IM_END                  ; size of image
17
    dd     I_END                   ; memory for app
17
    dd     I_END                   ; memory for app
18
    dd     I_END                   ; esp
18
    dd     I_END                   ; esp
19
    dd     0x0 , 0x0               ; I_Param , I_Icon
19
    dd     0x0 , 0x0               ; I_Param , I_Icon
20
 
20
 
21
;******************************************************************************
21
;******************************************************************************
22
 
22
 
23
 
23
 
24
include 'lang.inc'
24
include 'lang.inc'
25
include '..\..\..\macros.inc'
25
include '../../../macros.inc'
26
include 'ascl.inc'
26
include 'ascl.inc'
27
include 'ascgl.inc'
27
include 'ascgl.inc'
28
include 'ascml.inc'
28
include 'ascml.inc'
29
 
29
 
30
 
30
 
31
showmas:
31
showmas:
32
    cmp [edi+8],dword 0
32
    cmp [edi+8],dword 0
33
    je  noshow
33
    je  noshow
34
    cmp [edi+8],dword 1
34
    cmp [edi+8],dword 1
35
    jne no_gun
35
    jne no_gun
36
    mov eax,shoot
36
    mov eax,shoot
37
    jmp outp
37
    jmp outp
38
no_gun:
38
no_gun:
39
    push edi
39
    push edi
40
    random 3,ebx
40
    random 3,ebx
41
    pop edi
41
    pop edi
42
    cmp ebx,0
42
    cmp ebx,0
43
    jne no_star
43
    jne no_star
44
    mov eax,star
44
    mov eax,star
45
    jmp outp
45
    jmp outp
46
no_star:
46
no_star:
47
    cmp ebx,1
47
    cmp ebx,1
48
    jne no_star2
48
    jne no_star2
49
    mov eax,star2
49
    mov eax,star2
50
    jmp outp
50
    jmp outp
51
no_star2:
51
no_star2:
52
    mov eax,star3
52
    mov eax,star3
53
outp:
53
outp:
54
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
54
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
55
noshow:
55
noshow:
56
    ret
56
    ret
57
 
57
 
58
showobjmas:
58
showobjmas:
59
    cmp [edi+8],dword 0
59
    cmp [edi+8],dword 0
60
    je  noshow1
60
    je  noshow1
61
    cmp [edi+4],dword 380
61
    cmp [edi+4],dword 380
62
    jg  noshow1
62
    jg  noshow1
63
    cmp [edi+4],dword 0
63
    cmp [edi+4],dword 0
64
    jl  noshow1
64
    jl  noshow1
65
    cmp [edi+8],dword 1
65
    cmp [edi+8],dword 1
66
    jne no_warship1
66
    jne no_warship1
67
    mov eax,warship1
67
    mov eax,warship1
68
    jmp outws
68
    jmp outws
69
no_warship1:
69
no_warship1:
70
    cmp [edi+8],dword 2
70
    cmp [edi+8],dword 2
71
    jne no_warship2
71
    jne no_warship2
72
    mov eax,warship2
72
    mov eax,warship2
73
    jmp outws
73
    jmp outws
74
no_warship2:
74
no_warship2:
75
    cmp [edi+8],dword 3
75
    cmp [edi+8],dword 3
76
    jne no_meteor
76
    jne no_meteor
77
    mov eax,meteor
77
    mov eax,meteor
78
    jmp outws
78
    jmp outws
79
no_meteor:
79
no_meteor:
80
    cmp [edi+8],dword 4
80
    cmp [edi+8],dword 4
81
    jne no_box
81
    jne no_box
82
    mov eax,box
82
    mov eax,box
83
    jmp outws
83
    jmp outws
84
no_box:
84
no_box:
85
outws:
85
outws:
86
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
86
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
87
noshow1:
87
noshow1:
88
    ret
88
    ret
89
 
89
 
90
 
90
 
91
moveobjmas:
91
moveobjmas:
92
    cmp [edi+8],dword 0
92
    cmp [edi+8],dword 0
93
    je  no_ws
93
    je  no_ws
94
    mov eax,[edi+12]
94
    mov eax,[edi+12]
95
    add [edi],eax
95
    add [edi],eax
96
    mov eax,[edi+16]
96
    mov eax,[edi+16]
97
    add [edi+4],eax
97
    add [edi+4],eax
98
 
98
 
99
    cmp dword [edi],600
99
    cmp dword [edi],600
100
    jng xok1
100
    jng xok1
101
    sub dword [edi],20
101
    sub dword [edi],20
102
    neg dword [edi+12]
102
    neg dword [edi+12]
103
    jmp xok2
103
    jmp xok2
104
xok1:
104
xok1:
105
    cmp dword [edi],0
105
    cmp dword [edi],0
106
    jnl xok2
106
    jnl xok2
107
    add dword [edi],20
107
    add dword [edi],20
108
    neg dword [edi+12]
108
    neg dword [edi+12]
109
xok2:
109
xok2:
110
    cmp dword [edi+4],400
110
    cmp dword [edi+4],400
111
    jng yok
111
    jng yok
112
    mov dword [edi+8],0
112
    mov dword [edi+8],0
113
    ret
113
    ret
114
yok:
114
yok:
115
    cmp dword [edi+8],2  ;green ship
115
    cmp dword [edi+8],2  ;green ship
116
    jne no_grs
116
    jne no_grs
117
    cmp dword [edi+4],100
117
    cmp dword [edi+4],100
118
    jna no_grs
118
    jna no_grs
119
    cmp dword [edi+4],103
119
    cmp dword [edi+4],103
120
    jna grs
120
    jna grs
121
    cmp dword [edi+4],200
121
    cmp dword [edi+4],200
122
    jna no_grs
122
    jna no_grs
123
    cmp dword [edi+4],203
123
    cmp dword [edi+4],203
124
    jna  grs
124
    jna  grs
125
    cmp dword [edi+4],300
125
    cmp dword [edi+4],300
126
    jna no_grs
126
    jna no_grs
127
    cmp dword [edi+4],303
127
    cmp dword [edi+4],303
128
    ja  no_grs
128
    ja  no_grs
129
grs:
129
grs:
130
    neg dword [edi+12]
130
    neg dword [edi+12]
131
    mov [temp],edi
131
    mov [temp],edi
132
    findmas massive,findzero
132
    findmas massive,findzero
133
;in edi off to free element
133
;in edi off to free element
134
    jc  close_app
134
    jc  close_app
135
    mov esi,edi
135
    mov esi,edi
136
    mov edi,[temp]
136
    mov edi,[temp]
137
    mov eax,[edi]
137
    mov eax,[edi]
138
    mov [esi],eax
138
    mov [esi],eax
139
    mov eax,[edi+4]
139
    mov eax,[edi+4]
140
    mov [esi+4],eax
140
    mov [esi+4],eax
141
    mov [esi+8],dword 1
141
    mov [esi+8],dword 1
142
    mov [esi+12],dword 0
142
    mov [esi+12],dword 0
143
    mov [esi+16],dword 10
143
    mov [esi+16],dword 10
144
no_grs:
144
no_grs:
145
 
145
 
146
    cmp dword [edi+8],1  ;blue ship
146
    cmp dword [edi+8],1  ;blue ship
147
    jne no_bls
147
    jne no_bls
148
    cmp dword [edi+4],50
148
    cmp dword [edi+4],50
149
    jna no_bls
149
    jna no_bls
150
    cmp dword [edi+4],64
150
    cmp dword [edi+4],64
151
    jna bls
151
    jna bls
152
    cmp dword [edi+4],100
152
    cmp dword [edi+4],100
153
    jna no_bls
153
    jna no_bls
154
    cmp dword [edi+4],114
154
    cmp dword [edi+4],114
155
    jna bls
155
    jna bls
156
    cmp dword [edi+4],150
156
    cmp dword [edi+4],150
157
    jna no_bls
157
    jna no_bls
158
    cmp dword [edi+4],164
158
    cmp dword [edi+4],164
159
    ja  no_bls
159
    ja  no_bls
160
bls:
160
bls:
161
    mov [temp],edi
161
    mov [temp],edi
162
    findmas massive,findzero
162
    findmas massive,findzero
163
    jc  close_app
163
    jc  close_app
164
    mov esi,edi
164
    mov esi,edi
165
    mov edi,[temp]
165
    mov edi,[temp]
166
    mov eax,[edi]
166
    mov eax,[edi]
167
    mov [esi],eax
167
    mov [esi],eax
168
    mov eax,[edi+4]
168
    mov eax,[edi+4]
169
    mov [esi+4],eax
169
    mov [esi+4],eax
170
    mov [esi+8],dword 2
170
    mov [esi+8],dword 2
171
    mov [esi+12],dword 0
171
    mov [esi+12],dword 0
172
    mov [esi+16],dword 5
172
    mov [esi+16],dword 5
173
no_bls:
173
no_bls:
174
 
174
 
175
no_ws:
175
no_ws:
176
    ret
176
    ret
177
 
177
 
178
 
178
 
179
delfarshoot:
179
delfarshoot:
180
    cmp [edi+4],dword 40
180
    cmp [edi+4],dword 40
181
    jb  del
181
    jb  del
182
    cmp [edi+4],dword 400
182
    cmp [edi+4],dword 400
183
    ja  del
183
    ja  del
184
    cmp [edi],dword 40
184
    cmp [edi],dword 40
185
    jb  del
185
    jb  del
186
    cmp [edi],dword 600
186
    cmp [edi],dword 600
187
    ja  del
187
    ja  del
188
    jmp nodel
188
    jmp nodel
189
del:
189
del:
190
    mov [edi+8],dword 0
190
    mov [edi+8],dword 0
191
nodel:
191
nodel:
192
    ret
192
    ret
193
 
193
 
194
 
194
 
195
movemas:
195
movemas:
196
    cmp [edi+8],dword 0
196
    cmp [edi+8],dword 0
197
    jne no_freeel
197
    jne no_freeel
198
    ret
198
    ret
199
no_freeel:
199
no_freeel:
200
    mov eax,[edi+12]
200
    mov eax,[edi+12]
201
    add [edi],eax
201
    add [edi],eax
202
    mov eax,[edi+16]
202
    mov eax,[edi+16]
203
    add [edi+4],eax
203
    add [edi+4],eax
204
    ret
204
    ret
205
 
205
 
206
 
206
 
207
 
207
 
208
endshowmas:
208
endshowmas:
209
    cmp [edi+8],dword 0
209
    cmp [edi+8],dword 0
210
    je  noshowem
210
    je  noshowem
211
    mov eax,star2
211
    mov eax,star2
212
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
212
    aimgtoimg eax,dword [edi],dword [edi+4],canvas,0x0
213
noshowem:
213
noshowem:
214
    ret
214
    ret
215
 
215
 
216
 
216
 
217
 
217
 
218
endmovemas:
218
endmovemas:
219
    cmp [edi+8],dword 0
219
    cmp [edi+8],dword 0
220
    jne no_fr
220
    jne no_fr
221
    ret
221
    ret
222
no_fr:
222
no_fr:
223
    mov eax,[edi+12]
223
    mov eax,[edi+12]
224
    add [edi],eax
224
    add [edi],eax
225
    mov eax,[edi+16]
225
    mov eax,[edi+16]
226
    add [edi+4],eax
226
    add [edi+4],eax
227
    ret
227
    ret
228
 
228
 
229
 
229
 
230
findzero:
230
findzero:
231
    cmp [edi+8],dword 0
231
    cmp [edi+8],dword 0
232
    je  iz_zero
232
    je  iz_zero
233
    xor eax,eax
233
    xor eax,eax
234
    ret
234
    ret
235
iz_zero:
235
iz_zero:
236
    mov eax,1
236
    mov eax,1
237
    ret
237
    ret
238
 
238
 
239
compobr:
239
compobr:
240
    cmp [esi+8],dword 0
240
    cmp [esi+8],dword 0
241
    je  no_crsh
241
    je  no_crsh
242
    cmp [edi+8],dword 0
242
    cmp [edi+8],dword 0
243
    je  no_crsh
243
    je  no_crsh
244
    cmp [esi+16],dword 0
244
    cmp [esi+16],dword 0
245
    jg  no_crsh
245
    jg  no_crsh
246
 
246
 
247
    mov eax,[esi]
247
    mov eax,[esi]
248
    mov [temp],eax
248
    mov [temp],eax
249
    mov eax,[esi+4]
249
    mov eax,[esi+4]
250
    mov [temp2],eax
250
    mov [temp2],eax
251
    mov eax,[edi]
251
    mov eax,[edi]
252
    mov [temp3],eax
252
    mov [temp3],eax
253
    mov eax,[edi+4]
253
    mov eax,[edi+4]
254
    mov [temp4],eax
254
    mov [temp4],eax
255
 
255
 
256
    pushad
256
    pushad
257
    collimg imgsize,[temp],[temp2],imgsize,[temp3],[temp4],[otv]
257
    collimg imgsize,[temp],[temp2],imgsize,[temp3],[temp4],[otv]
258
    popad
258
    popad
259
    cmp [otv],dword 0
259
    cmp [otv],dword 0
260
    je  no_crsh
260
    je  no_crsh
261
 
261
 
262
    cmp [edi+8],dword 2
262
    cmp [edi+8],dword 2
263
    jne no_grship
263
    jne no_grship
264
    inc [gship]
264
    inc [gship]
265
    add [score],30
265
    add [score],30
266
    jmp setzero
266
    jmp setzero
267
no_grship:
267
no_grship:
268
    cmp [edi+8],dword 1
268
    cmp [edi+8],dword 1
269
    jne no_blship
269
    jne no_blship
270
    inc [bship]
270
    inc [bship]
271
    add [score],20
271
    add [score],20
272
    jmp setzero
272
    jmp setzero
273
no_blship:
273
no_blship:
274
    cmp [edi+8],dword 3
274
    cmp [edi+8],dword 3
275
    jne no_metr
275
    jne no_metr
276
    dec dword [edi+16]
276
    dec dword [edi+16]
277
    cmp dword [edi+16],0
277
    cmp dword [edi+16],0
278
    jne mok
278
    jne mok
279
    mov dword [edi+16],1
279
    mov dword [edi+16],1
280
mok:
280
mok:
281
    mov [esi+8],dword 0
281
    mov [esi+8],dword 0
282
    ret
282
    ret
283
no_metr:
283
no_metr:
284
 
284
 
285
setzero:
285
setzero:
286
    mov [esi+8],dword 0
286
    mov [esi+8],dword 0
287
    mov [edi+8],dword 0
287
    mov [edi+8],dword 0
288
no_crsh:
288
no_crsh:
289
    ret
289
    ret
290
 
290
 
291
shipobjtest:
291
shipobjtest:
292
    cmp [edi+8],dword 0
292
    cmp [edi+8],dword 0
293
    je  no_obj
293
    je  no_obj
294
    mov eax,[edi]
294
    mov eax,[edi]
295
    mov [temp3],eax
295
    mov [temp3],eax
296
    mov eax,[edi+4]
296
    mov eax,[edi+4]
297
    mov [temp4],eax
297
    mov [temp4],eax
298
    pushad
298
    pushad
299
    collimg imgsize,[shipx],[shipy],imgsize,[temp3],[temp4],[otv]
299
    collimg imgsize,[shipx],[shipy],imgsize,[temp3],[temp4],[otv]
300
    popad
300
    popad
301
    cmp [otv],dword 0
301
    cmp [otv],dword 0
302
    je  no_obj
302
    je  no_obj
303
    cmp [edi+8],dword 4  ;if box
303
    cmp [edi+8],dword 4  ;if box
304
    jne no_fbox
304
    jne no_fbox
305
    add [energy],5
305
    add [energy],5
306
    add [score],50
306
    add [score],50
307
    mov [edi+8],dword 0
307
    mov [edi+8],dword 0
308
    inc [boxget]
308
    inc [boxget]
309
    ret
309
    ret
310
no_fbox:
310
no_fbox:
311
    sub [energy],16
311
    sub [energy],16
312
    mov [edi+8],dword 0
312
    mov [edi+8],dword 0
313
no_obj:
313
no_obj:
314
    ret
314
    ret
315
 
315
 
316
shipguntest:
316
shipguntest:
317
    cmp [edi+8],dword 0
317
    cmp [edi+8],dword 0
318
    je  no_gobj
318
    je  no_gobj
319
    cmp [edi+16],dword 0
319
    cmp [edi+16],dword 0
320
    jl  no_gobj
320
    jl  no_gobj
321
    mov eax,[edi]
321
    mov eax,[edi]
322
    mov [temp3],eax
322
    mov [temp3],eax
323
    mov eax,[edi+4]
323
    mov eax,[edi+4]
324
    mov [temp4],eax
324
    mov [temp4],eax
325
    pushad
325
    pushad
326
    collimg imgsize,[shipx],[shipy],imgsize,[temp3],[temp4],[otv]
326
    collimg imgsize,[shipx],[shipy],imgsize,[temp3],[temp4],[otv]
327
    popad
327
    popad
328
    cmp [otv],dword 0
328
    cmp [otv],dword 0
329
    je  no_gobj
329
    je  no_gobj
330
    sub [energy],4
330
    sub [energy],4
331
    mov [edi+8],dword 0
331
    mov [edi+8],dword 0
332
no_gobj:
332
no_gobj:
333
    ret
333
    ret
334
 
334
 
335
 
335
 
336
START:                          ; start of execution
336
START:                          ; start of execution
337
 
337
 
338
massize = 400
338
massize = 400
339
elemsize = 20
339
elemsize = 20
340
 
340
 
341
    mov [massive],dword massize
341
    mov [massive],dword massize
342
    mov [massive+4],dword elemsize
342
    mov [massive+4],dword elemsize
343
 
343
 
344
omassize = 100
344
omassize = 100
345
oelemsize = 20
345
oelemsize = 20
346
 
346
 
347
    mov [objmas],dword omassize
347
    mov [objmas],dword omassize
348
    mov [objmas+4],dword oelemsize
348
    mov [objmas+4],dword oelemsize
349
 
349
 
350
 
350
 
351
    mov eax,66
351
    mov eax,66
352
    mov ebx,1
352
    mov ebx,1
353
    mov ecx,1
353
    mov ecx,1
354
    mcall
354
    mcall
355
 
355
 
356
    mov eax,26
356
    mov eax,26
357
    mov ebx,2
357
    mov ebx,2
358
    mov ecx,1
358
    mov ecx,1
359
    mov edx,keymap
359
    mov edx,keymap
360
    mcall
360
    mcall
361
 
361
 
362
startgame:
362
startgame:
363
    giftoimg gif_file_area2,canvas
363
    giftoimg gif_file_area2,canvas
364
    giftoimg gif_file_area,img_area
364
    giftoimg gif_file_area,img_area
365
 
365
 
366
    getimg img_area,0,0,32,32,ship
366
    getimg img_area,0,0,32,32,ship
367
    getimg img_area,32,0,32,32,shoot
367
    getimg img_area,32,0,32,32,shoot
368
    getimg img_area,64,0,32,32,warship1
368
    getimg img_area,64,0,32,32,warship1
369
    getimg img_area,96,0,32,32,warship2
369
    getimg img_area,96,0,32,32,warship2
370
    getimg img_area,128,0,32,32,meteor
370
    getimg img_area,128,0,32,32,meteor
371
    getimg img_area,160,0,32,32,star
371
    getimg img_area,160,0,32,32,star
372
    getimg img_area,192,0,32,32,star2
372
    getimg img_area,192,0,32,32,star2
373
    getimg img_area,224,0,32,32,star3
373
    getimg img_area,224,0,32,32,star3
374
    getimg img_area,0,32,32,32,box
374
    getimg img_area,0,32,32,32,box
375
 
375
 
376
 
376
 
377
 
377
 
378
main_menu:
378
main_menu:
379
    call draw_logowindow
379
    call draw_logowindow
380
 
380
 
381
stillm:
381
stillm:
382
    wtevent redm,keym,buttonm
382
    wtevent redm,keym,buttonm
383
    jmp stillm
383
    jmp stillm
384
redm:
384
redm:
385
    call draw_logowindow
385
    call draw_logowindow
386
    jmp stillm
386
    jmp stillm
387
keym:
387
keym:
388
    mov  eax,2
388
    mov  eax,2
389
    mcall
389
    mcall
390
    jmp  stillm
390
    jmp  stillm
391
buttonm:
391
buttonm:
392
    mov  eax,17                 ; get id
392
    mov  eax,17                 ; get id
393
    mcall
393
    mcall
394
    cmp  ah,1                   ; button id=1 ?
394
    cmp  ah,1                   ; button id=1 ?
395
    je   close_app
395
    je   close_app
396
    cmp  ah,2                   ; button id=1 ?
396
    cmp  ah,2                   ; button id=1 ?
397
    je   start_game
397
    je   start_game
398
    cmp  ah,3                   ; button id=1 ?
398
    cmp  ah,3                   ; button id=1 ?
399
    je   help
399
    je   help
400
    cmp  ah,4                   ; button id=1 ?
400
    cmp  ah,4                   ; button id=1 ?
401
    je   close_app
401
    je   close_app
402
    jmp  stillm
402
    jmp  stillm
403
 
403
 
404
draw_logowindow:
404
draw_logowindow:
405
    call draw_window
405
    call draw_window
-
 
406
    mcall 9,proc_info,-1
-
 
407
    test [proc_info+process_information.wnd_state], 0x04
-
 
408
    jz   @f
-
 
409
    ret
-
 
410
  @@:
406
    setimg 5,21,canvas
411
    setimg 5,21,canvas
407
    drawlbut 300,300,60,14,'START',2,0x990000,cl_Black
412
    drawlbut 300,300,60,14,'START',2,0x990000,cl_Black
408
    drawlbut 300,320,60,14,'HELP',3,0x990000,cl_Black
413
    drawlbut 300,320,60,14,'HELP',3,0x990000,cl_Black
409
    drawlbut 300,340,60,14,'EXIT',4,0x990000,cl_Black
414
    drawlbut 300,340,60,14,'EXIT',4,0x990000,cl_Black
410
    ret
415
    ret
411
 
416
 
412
;***********************
417
;***********************
413
; Draw help menu
418
; Draw help menu
414
;***********************
419
;***********************
415
 
420
 
416
help:
421
help:
417
    call draw_helpwindow
422
    call draw_helpwindow
418
 
423
 
419
stillh:
424
stillh:
420
    wtevent redh,keyh,buttonh
425
    wtevent redh,keyh,buttonh
421
    jmp stillh
426
    jmp stillh
422
redh:
427
redh:
423
    call draw_helpwindow
428
    call draw_helpwindow
424
    jmp stillh
429
    jmp stillh
425
keyh:
430
keyh:
426
    mov  eax,2
431
    mov  eax,2
427
    mcall
432
    mcall
428
    jmp  stillh
433
    jmp  stillh
429
buttonh:
434
buttonh:
430
    mov  eax,17                 ; get id
435
    mov  eax,17                 ; get id
431
    mcall
436
    mcall
432
    cmp  ah,1                   ; button id=1 ?
437
    cmp  ah,1                   ; button id=1 ?
433
    je   close_app
438
    je   close_app
434
    cmp  ah,2                   ; button id=1 ?
439
    cmp  ah,2                   ; button id=1 ?
435
    je   start_game
440
    je   start_game
436
    cmp  ah,3                   ; button id=1 ?
441
    cmp  ah,3                   ; button id=1 ?
437
    je   help
442
    je   help
438
    cmp  ah,4                   ; button id=1 ?
443
    cmp  ah,4                   ; button id=1 ?
439
    je   close_app
444
    je   close_app
440
    cmp  ah,5                   ; button id=1 ?
445
    cmp  ah,5                   ; button id=1 ?
441
    je   main_menu
446
    je   main_menu
442
    jmp  stillh
447
    jmp  stillh
443
 
448
 
444
draw_helpwindow:
449
draw_helpwindow:
445
    call draw_window
450
    call draw_window
-
 
451
    mcall 9,proc_info,-1
-
 
452
    test [proc_info+process_information.wnd_state], 0x04
-
 
453
    jnz  stillh
446
    setimg 5,21,canvas
454
    setimg 5,21,canvas
447
 
455
 
448
    drawfbox 40,50,580,380,cl_Grey
456
    drawfbox 40,50,580,380,cl_Grey
449
 
457
 
450
    mov ebp,4*7
458
    mov ebp,4*7
451
    mov ebx,180*65536+90
459
    mov ebx,180*65536+90
452
    mov edx,helptext
460
    mov edx,helptext
453
    mov esi,50
461
    mov esi,50
454
    mov ecx,cl_White
462
    mov ecx,cl_White
455
    dec ebp
463
    dec ebp
456
looht:
464
looht:
457
    mov eax,4
465
    mov eax,4
458
    mcall
466
    mcall
459
    add edx,esi
467
    add edx,esi
460
    add ebx,10
468
    add ebx,10
461
    dec ebp
469
    dec ebp
462
    jnz looht
470
    jnz looht
463
 
471
 
464
    setimg 90,90,ship
472
    setimg 90,90,ship
465
    setimg 90,130,shoot
473
    setimg 90,130,shoot
466
    setimg 90,170,star
474
    setimg 90,170,star
467
    setimg 90,210,warship1
475
    setimg 90,210,warship1
468
    setimg 90,250,warship2
476
    setimg 90,250,warship2
469
    setimg 90,290,meteor
477
    setimg 90,290,meteor
470
    setimg 90,330,box
478
    setimg 90,330,box
471
 
479
 
472
    drawlbut 500,400,80,14,'<
480
    drawlbut 500,400,80,14,'<
473
 
481
 
474
    jmp stillh
482
    jmp stillh
475
 
483
 
476
helptext:
484
helptext:
477
    db 'Phenix                                            '
485
    db 'Phenix                                            '
478
    db 'Controls: Num1 move left, Num3 move right         '
486
    db 'Controls: Num1 move left, Num3 move right         '
479
    db '          P-pause (use for screen shooting)       '
487
    db '          P-pause (use for screen shooting)       '
480
    db '                                                  '
488
    db '                                                  '
481
 
489
 
482
    db 'Lazer cannon                                      '
490
    db 'Lazer cannon                                      '
483
    db 'Press Num5 for shoot                              '
491
    db 'Press Num5 for shoot                              '
484
    db 'Core fast, speed fast, reload slow                '
492
    db 'Core fast, speed fast, reload slow                '
485
    db '                                                  '
493
    db '                                                  '
486
 
494
 
487
    db 'Plazma cannon                                     '
495
    db 'Plazma cannon                                     '
488
    db 'Press Num2 for Plazma Nuke and Num8 for shoot     '
496
    db 'Press Num2 for Plazma Nuke and Num8 for shoot     '
489
    db 'Core slow, speed medium, reload fast              '
497
    db 'Core slow, speed medium, reload fast              '
490
    db '                                                  '
498
    db '                                                  '
491
 
499
 
492
    db 'Blue warship                                      '
500
    db 'Blue warship                                      '
493
    db 'Speed fast                                        '
501
    db 'Speed fast                                        '
494
    db 'Attack method: plazma bomb                        '
502
    db 'Attack method: plazma bomb                        '
495
    db '                                                  '
503
    db '                                                  '
496
 
504
 
497
    db 'Green warship                                     '
505
    db 'Green warship                                     '
498
    db 'Speed slow                                        '
506
    db 'Speed slow                                        '
499
    db 'Attack method: laser shoot                        '
507
    db 'Attack method: laser shoot                        '
500
    db '                                                  '
508
    db '                                                  '
501
 
509
 
502
    db 'Meteor                                            '
510
    db 'Meteor                                            '
503
    db 'Dangeros object!                                  '
511
    db 'Dangeros object!                                  '
504
    db 'SuperSheld                                        '
512
    db 'SuperSheld                                        '
505
    db '                                                  '
513
    db '                                                  '
506
 
514
 
507
    db 'Fly Box                                           '
515
    db 'Fly Box                                           '
508
    db 'Sheld pack, sheld +5, score +30                   '
516
    db 'Sheld pack, sheld +5, score +30                   '
509
    db 'Get for sheld level up!                           '
517
    db 'Get for sheld level up!                           '
510
    db '                                                  '
518
    db '                                                  '
511
 
519
 
512
start_game:
520
start_game:
513
 
521
 
514
;    jmp end_gm
522
;    jmp end_gm
515
 
523
 
516
    mov [canvas],dword 640
524
    mov [canvas],dword 640
517
    mov [canvas+4],dword 440
525
    mov [canvas+4],dword 440
518
 
526
 
519
    call draw_window
527
    call draw_window
520
 
528
 
521
;Main loop wait for event with 10msec
529
;Main loop wait for event with 10msec
522
still:
530
still:
523
;    scevent red,key,button ;for full speed
531
;    scevent red,key,button ;for full speed
524
 
532
 
525
    timeevent 1,no_event,red,key,button
533
    timeevent 1,no_event,red,key,button
526
no_event:
534
no_event:
-
 
535
    mcall 9,proc_info,-1
-
 
536
    test [proc_info+process_information.wnd_state], 0x04
-
 
537
    jnz  still
527
    setimg 5,21,canvas
538
    setimg 5,21,canvas
528
 
539
 
529
    cmp [pause_on],0
540
    cmp [pause_on],0
530
    jne still
541
    jne still
531
 
542
 
532
    cmp [energy],0
543
    cmp [energy],0
533
    jl  game_over
544
    jl  game_over
534
 
545
 
535
    cmp [ctime],dword 0
546
    cmp [ctime],dword 0
536
    je  no_dct
547
    je  no_dct
537
    dec dword [ctime]
548
    dec dword [ctime]
538
no_dct:
549
no_dct:
539
 
550
 
540
    cmp [xtime],dword 0
551
    cmp [xtime],dword 0
541
    je  no_dxt
552
    je  no_dxt
542
    dec dword [xtime]
553
    dec dword [xtime]
543
no_dxt:
554
no_dxt:
544
 
555
 
545
 
556
 
546
;
557
;
547
;   Add to level new ships
558
;   Add to level new ships
548
;
559
;
549
    inc dword [pathtime]
560
    inc dword [pathtime]
550
    mov ebp,[levelpart]
561
    mov ebp,[levelpart]
551
    shl ebp,5
562
    shl ebp,5
552
    add ebp,levels
563
    add ebp,levels
553
    mov eax,[ebp]
564
    mov eax,[ebp]
554
    cmp [pathtime],eax ;500
565
    cmp [pathtime],eax ;500
555
    jne no_nextloc
566
    jne no_nextloc
556
 
567
 
557
randobjmasx:
568
randobjmasx:
558
    mov ebp,[levelpart]
569
    mov ebp,[levelpart]
559
    shl ebp,5
570
    shl ebp,5
560
    add ebp,levels
571
    add ebp,levels
561
 
572
 
562
    mov  ecx,[ebp+8]
573
    mov  ecx,[ebp+8]
563
    mov  [shiptype],2
574
    mov  [shiptype],2
564
    mov  [xmoving],9
575
    mov  [xmoving],9
565
    mov  [xaccel],4
576
    mov  [xaccel],4
566
    mov  [ymoving],3
577
    mov  [ymoving],3
567
    mov  [yaccel],2
578
    mov  [yaccel],2
568
    call add_ships
579
    call add_ships
569
 
580
 
570
    mov  ecx,[ebp+12]
581
    mov  ecx,[ebp+12]
571
    mov  [shiptype],1
582
    mov  [shiptype],1
572
    mov  [xmoving],3
583
    mov  [xmoving],3
573
    mov  [xaccel],1
584
    mov  [xaccel],1
574
    mov  [ymoving],3
585
    mov  [ymoving],3
575
    mov  [yaccel],6
586
    mov  [yaccel],6
576
    call add_ships
587
    call add_ships
577
 
588
 
578
    mov  ecx,[ebp+16]
589
    mov  ecx,[ebp+16]
579
    mov  [shiptype],3
590
    mov  [shiptype],3
580
    mov  [xmoving],5
591
    mov  [xmoving],5
581
    mov  [xaccel],2
592
    mov  [xaccel],2
582
    mov  [ymoving],5
593
    mov  [ymoving],5
583
    mov  [yaccel],2
594
    mov  [yaccel],2
584
    call add_ships
595
    call add_ships
585
 
596
 
586
    mov  ecx,[ebp+20]
597
    mov  ecx,[ebp+20]
587
    mov  [shiptype],4
598
    mov  [shiptype],4
588
    mov  [xmoving],4
599
    mov  [xmoving],4
589
    mov  [xaccel],1
600
    mov  [xaccel],1
590
    mov  [ymoving],4
601
    mov  [ymoving],4
591
    mov  [yaccel],1
602
    mov  [yaccel],1
592
    call add_ships
603
    call add_ships
593
 
604
 
594
    jmp newlocend
605
    jmp newlocend
595
 
606
 
596
shiptype dd 0
607
shiptype dd 0
597
xmoving  dd 0
608
xmoving  dd 0
598
ymoving  dd 0
609
ymoving  dd 0
599
xaccel   dd 0
610
xaccel   dd 0
600
yaccel   dd 0
611
yaccel   dd 0
601
 
612
 
602
add_ships:
613
add_ships:
603
looship:
614
looship:
604
    cmp ecx,0
615
    cmp ecx,0
605
    je  no_ships
616
    je  no_ships
606
    push ecx
617
    push ecx
607
    findmas objmas,findzero
618
    findmas objmas,findzero
608
;in edi off to free element
619
;in edi off to free element
609
    jc  close_app
620
    jc  close_app
610
    mov ebp,[shiptype]
621
    mov ebp,[shiptype]
611
    mov dword [edi+8],ebp ;2 ;green ship
622
    mov dword [edi+8],ebp ;2 ;green ship
612
; random x
623
; random x
613
    push edi
624
    push edi
614
    random 600,eax
625
    random 600,eax
615
    pop edi
626
    pop edi
616
    mov [edi],eax
627
    mov [edi],eax
617
; random y
628
; random y
618
    push edi
629
    push edi
619
    mov ebp,[levelpart]
630
    mov ebp,[levelpart]
620
    shl ebp,5
631
    shl ebp,5
621
    add ebp,levels
632
    add ebp,levels
622
    mov esi,[ebp+4] ;get max range
633
    mov esi,[ebp+4] ;get max range
623
    random esi,eax
634
    random esi,eax
624
    neg eax
635
    neg eax
625
    pop edi
636
    pop edi
626
    mov [edi+4],eax
637
    mov [edi+4],eax
627
; x moving
638
; x moving
628
    push edi         ;planers
639
    push edi         ;planers
629
    random [xmoving],eax
640
    random [xmoving],eax
630
    sub eax,[xaccel];4
641
    sub eax,[xaccel];4
631
    pop edi
642
    pop edi
632
    mov [edi+12],eax
643
    mov [edi+12],eax
633
; y moving
644
; y moving
634
    push edi
645
    push edi
635
    random [ymoving],eax     ;slow
646
    random [ymoving],eax     ;slow
636
    add eax,[yaccel] ;2
647
    add eax,[yaccel] ;2
637
    pop edi
648
    pop edi
638
    mov [edi+16],eax
649
    mov [edi+16],eax
639
    pop ecx
650
    pop ecx
640
    dec ecx
651
    dec ecx
641
    jnz looship
652
    jnz looship
642
no_ships:
653
no_ships:
643
    ret
654
    ret
644
 
655
 
645
 
656
 
646
levelpart dd 0
657
levelpart dd 0
647
levels:
658
levels:
648
;level1
659
;level1
649
    dd 1,800,0,0,5,8,0,0     ;one at start
660
    dd 1,800,0,0,5,8,0,0     ;one at start
650
    dd 500,2000,4,20,30,0,0,0
661
    dd 500,2000,4,20,30,0,0,0
651
    dd 500,2000,4,20,0,8,0,0
662
    dd 500,2000,4,20,0,8,0,0
652
    dd 500,2000,10,0,0,4,0,0
663
    dd 500,2000,10,0,0,4,0,0
653
    dd 500,4000,0,30,0,0,0,0
664
    dd 500,4000,0,30,0,0,0,0
654
    dd 400,400,0,0,10,0,0,0
665
    dd 400,400,0,0,10,0,0,0
655
    dd 400,400,0,0,10,0,0,0
666
    dd 400,400,0,0,10,0,0,0
656
    dd 0,0,0,0,0,0,0,0        ;end of level
667
    dd 0,0,0,0,0,0,0,0        ;end of level
657
;level2
668
;level2
658
    dd 1,16000,0,30,0,0,0,0     ;one at start
669
    dd 1,16000,0,30,0,0,0,0     ;one at start
659
    dd 200,8000,0,20,0,0,0,0
670
    dd 200,8000,0,20,0,0,0,0
660
    dd 200,2000,0,10,0,8,0,0
671
    dd 200,2000,0,10,0,8,0,0
661
    dd 200,4000,0,10,0,0,0,0
672
    dd 200,4000,0,10,0,0,0,0
662
    dd 0,0,0,0,0,0,0,0        ;end of level
673
    dd 0,0,0,0,0,0,0,0        ;end of level
663
;level3
674
;level3
664
    dd 1,4000,0,20,30,8,0,0     ;one at start
675
    dd 1,4000,0,20,30,8,0,0     ;one at start
665
    dd 400,4000,10,10,20,6,0,0
676
    dd 400,4000,10,10,20,6,0,0
666
    dd 400,4000,0,20,10,2,0,0
677
    dd 400,4000,0,20,10,2,0,0
667
    dd 400,4000,10,10,20,0,0,0
678
    dd 400,4000,10,10,20,0,0,0
668
    dd 0,-1,0,0,0,0,0,0        ;end of game
679
    dd 0,-1,0,0,0,0,0,0        ;end of game
669
 
680
 
670
 
681
 
671
newlocend:
682
newlocend:
672
    mov [pathtime],0
683
    mov [pathtime],0
673
    inc [levelpart]
684
    inc [levelpart]
674
    jmp no_nextloc
685
    jmp no_nextloc
675
 
686
 
676
endgame dd 0
687
endgame dd 0
677
objects dd 0
688
objects dd 0
678
endtest:
689
endtest:
679
    cmp dword [edi+8],0
690
    cmp dword [edi+8],0
680
    jne no_free
691
    jne no_free
681
    ret
692
    ret
682
no_free:
693
no_free:
683
    mov [endgame],0
694
    mov [endgame],0
684
    inc [objects]
695
    inc [objects]
685
    ret
696
    ret
686
 
697
 
687
 
698
 
688
no_nextloc:
699
no_nextloc:
689
    mov [objects],0
700
    mov [objects],0
690
    mov [endgame],1
701
    mov [endgame],1
691
    readmas objmas,endtest
702
    readmas objmas,endtest
692
    cmp [endgame],1
703
    cmp [endgame],1
693
    jne no_end_lev ;no_nextloc
704
    jne no_end_lev ;no_nextloc
694
 
705
 
695
    mov ebp,[levelpart]
706
    mov ebp,[levelpart]
696
    shl ebp,5
707
    shl ebp,5
697
    add ebp,levels
708
    add ebp,levels
698
    mov eax,[ebp+4]
709
    mov eax,[ebp+4]
699
    cmp eax,dword 0
710
    cmp eax,dword 0
700
    je  end_lev    ;end of level
711
    je  end_lev    ;end of level
701
    cmp eax,dword -1
712
    cmp eax,dword -1
702
    je  end_gm    ;end of game
713
    je  end_gm    ;end of game
703
 
714
 
704
no_end_lev:
715
no_end_lev:
705
 
716
 
706
    cmp [num5],dword 0
717
    cmp [num5],dword 0
707
    je  no_addsh
718
    je  no_addsh
708
    cmp [ctime],dword 0
719
    cmp [ctime],dword 0
709
    jne no_addsh
720
    jne no_addsh
710
    cmp [lazer],dword 0
721
    cmp [lazer],dword 0
711
    je  no_addsh
722
    je  no_addsh
712
    findmas massive,findzero
723
    findmas massive,findzero
713
;in edi off to free element
724
;in edi off to free element
714
    jc  close_app
725
    jc  close_app
715
    mov eax,[shipx]
726
    mov eax,[shipx]
716
    mov [edi],eax
727
    mov [edi],eax
717
    mov eax,[shipy]
728
    mov eax,[shipy]
718
    mov [edi+4],eax
729
    mov [edi+4],eax
719
    mov [edi+8],dword 1   ;show
730
    mov [edi+8],dword 1   ;show
720
    mov [edi+12],dword 0
731
    mov [edi+12],dword 0
721
    mov [edi+16],dword -12
732
    mov [edi+16],dword -12
722
    mov [ctime],dword 8   ;wait for cannon
733
    mov [ctime],dword 8   ;wait for cannon
723
    dec [lazer]
734
    dec [lazer]
724
no_addsh:
735
no_addsh:
725
 
736
 
726
    cmp [num8],dword 0
737
    cmp [num8],dword 0
727
    je  no_addplx
738
    je  no_addplx
728
    cmp [xtime],dword 256-16
739
    cmp [xtime],dword 256-16
729
    jae no_addplx
740
    jae no_addplx
730
    cmp [plazma],0
741
    cmp [plazma],0
731
    je  no_addplx
742
    je  no_addplx
732
    findmas massive,findzero
743
    findmas massive,findzero
733
;in edi off to free element
744
;in edi off to free element
734
    jc  close_app
745
    jc  close_app
735
    mov eax,[shipx]
746
    mov eax,[shipx]
736
    mov [edi],eax
747
    mov [edi],eax
737
    mov eax,[shipy]
748
    mov eax,[shipy]
738
    mov [edi+4],eax
749
    mov [edi+4],eax
739
    mov [edi+8],dword 2   ;show
750
    mov [edi+8],dword 2   ;show
740
    add [xtime],dword 8  ;wait for cannon
751
    add [xtime],dword 8  ;wait for cannon
741
    cmp [xtime],dword 256
752
    cmp [xtime],dword 256
742
    jna okx
753
    jna okx
743
    mov [xtime],256
754
    mov [xtime],256
744
okx:
755
okx:
745
    mov [edi+12],dword 0  ;wait for cannon
756
    mov [edi+12],dword 0  ;wait for cannon
746
    mov [edi+16],dword -8  ;wait for cannon
757
    mov [edi+16],dword -8  ;wait for cannon
747
    dec [plazma]
758
    dec [plazma]
748
no_addplx:
759
no_addplx:
749
 
760
 
750
 
761
 
751
 
762
 
752
    cmp [num2],dword 0
763
    cmp [num2],dword 0
753
    je  no_addsh2
764
    je  no_addsh2
754
    cmp [xtime],dword 0
765
    cmp [xtime],dword 0
755
    jne no_addsh2
766
    jne no_addsh2
756
    cmp [plazma],0
767
    cmp [plazma],0
757
    je  no_addsh2
768
    je  no_addsh2
758
    mov eax,[shipy]
769
    mov eax,[shipy]
759
    mov [temp3],eax
770
    mov [temp3],eax
760
    mov [temp2],dword 5
771
    mov [temp2],dword 5
761
loox2:
772
loox2:
762
    mov [temp],dword 10
773
    mov [temp],dword 10
763
loox:
774
loox:
764
    findmas massive,findzero
775
    findmas massive,findzero
765
;in edi off to free element
776
;in edi off to free element
766
    jc  close_app
777
    jc  close_app
767
    random 25,eax
778
    random 25,eax
768
    mov ebp,eax
779
    mov ebp,eax
769
    sub eax,12
780
    sub eax,12
770
    add eax,[shipx]
781
    add eax,[shipx]
771
    mov [edi],eax
782
    mov [edi],eax
772
    shr ebp,3
783
    shr ebp,3
773
    random ebp,eax
784
    random ebp,eax
774
    neg eax
785
    neg eax
775
    add eax,[temp3] ;[shipy]
786
    add eax,[temp3] ;[shipy]
776
    mov [edi+4],eax
787
    mov [edi+4],eax
777
    mov [edi+8],dword 2   ;show hstar
788
    mov [edi+8],dword 2   ;show hstar
778
    random 5,eax
789
    random 5,eax
779
    sub eax,2
790
    sub eax,2
780
    mov [edi+12],eax   ;show hstar
791
    mov [edi+12],eax   ;show hstar
781
    random 7,eax
792
    random 7,eax
782
    sub eax,8
793
    sub eax,8
783
    mov [edi+16],eax   ;show hstar
794
    mov [edi+16],eax   ;show hstar
784
    dec [temp]
795
    dec [temp]
785
    jnz loox
796
    jnz loox
786
    sub [temp3],30
797
    sub [temp3],30
787
    dec [temp2]
798
    dec [temp2]
788
    jnz loox2
799
    jnz loox2
789
    mov [xtime],dword 256  ;wait for cannon
800
    mov [xtime],dword 256  ;wait for cannon
790
    sub [plazma],50
801
    sub [plazma],50
791
no_addsh2:
802
no_addsh2:
792
 
803
 
793
 
804
 
794
    cmp [num1],dword 0
805
    cmp [num1],dword 0
795
    je  no_left
806
    je  no_left
796
    sub dword [shipx],6
807
    sub dword [shipx],6
797
no_left:
808
no_left:
798
 
809
 
799
    cmp [num3],dword 0
810
    cmp [num3],dword 0
800
    je  no_right
811
    je  no_right
801
    add dword [shipx],6
812
    add dword [shipx],6
802
no_right:
813
no_right:
803
 
814
 
804
;ship correct
815
;ship correct
805
    cmp [shipx],5
816
    cmp [shipx],5
806
    jnl xl_ok
817
    jnl xl_ok
807
    mov [shipx],5
818
    mov [shipx],5
808
xl_ok:
819
xl_ok:
809
    cmp [shipx],603
820
    cmp [shipx],603
810
    jng xr_ok
821
    jng xr_ok
811
    mov [shipx],603
822
    mov [shipx],603
812
xr_ok:
823
xr_ok:
813
 
824
 
814
 
825
 
815
;clear scrbuf
826
;clear scrbuf
816
    mov edi,canvas+8
827
    mov edi,canvas+8
817
    cld
828
    cld
818
    mov ecx,640*440*3/4
829
    mov ecx,640*440*3/4
819
    mov eax,0
830
    mov eax,0
820
    rep stosd
831
    rep stosd
821
 
832
 
822
    compmas objmas,massive,compobr
833
    compmas objmas,massive,compobr
823
 
834
 
824
    readmas objmas,shipobjtest
835
    readmas objmas,shipobjtest
825
    readmas massive,shipguntest
836
    readmas massive,shipguntest
826
 
837
 
827
    readmas objmas,showobjmas
838
    readmas objmas,showobjmas
828
    readmas objmas,moveobjmas
839
    readmas objmas,moveobjmas
829
 
840
 
830
    readmas massive,showmas
841
    readmas massive,showmas
831
    readmas massive,movemas
842
    readmas massive,movemas
832
    readmas massive,delfarshoot
843
    readmas massive,delfarshoot
833
;    findmas massive,findzero
844
;    findmas massive,findzero
834
;in edi off to free element
845
;in edi off to free element
835
;    jc  close_app
846
;    jc  close_app
836
 
847
 
837
    aimgtoimg ship,[shipx],[shipy],canvas,0x0
848
    aimgtoimg ship,[shipx],[shipy],canvas,0x0
838
 
849
 
839
    drawfbox 150,5,64,5,0x000000
850
    drawfbox 150,5,64,5,0x000000
840
    mov eax,[xtime]
851
    mov eax,[xtime]
841
    sub eax,256
852
    sub eax,256
842
    neg eax
853
    neg eax
843
    shr eax,2
854
    shr eax,2
844
    drawfbox 150,5,eax,5,0x0000ff
855
    drawfbox 150,5,eax,5,0x0000ff
845
 
856
 
846
    drawfbox 150,12,64,5,0x000000
857
    drawfbox 150,12,64,5,0x000000
847
    mov eax,[ctime]
858
    mov eax,[ctime]
848
    sub eax,8
859
    sub eax,8
849
    neg eax
860
    neg eax
850
    shl eax,3
861
    shl eax,3
851
    drawfbox 150,12,eax,5,0xffff00
862
    drawfbox 150,12,eax,5,0xffff00
852
 
863
 
853
    drawfbox 220,2,6*5+2 ,9,cl_Grey
864
    drawfbox 220,2,6*5+2 ,9,cl_Grey
854
    outcount [plazma],221,3,cl_Blue,5*65536
865
    outcount [plazma],221,3,cl_Blue,5*65536
855
    drawfbox 220,11,6*5+2 ,9,cl_Grey
866
    drawfbox 220,11,6*5+2 ,9,cl_Grey
856
    outcount [lazer],221,12,0xffff00,5*65536
867
    outcount [lazer],221,12,0xffff00,5*65536
857
 
868
 
858
 
869
 
859
    drawfbox 280,6,6*5+2 ,9,cl_Grey
870
    drawfbox 280,6,6*5+2 ,9,cl_Grey
860
    outcount [gship],281,7,cl_Green,5*65536
871
    outcount [gship],281,7,cl_Green,5*65536
861
    drawfbox 320,6,6*5+2 ,9,cl_Grey
872
    drawfbox 320,6,6*5+2 ,9,cl_Grey
862
    outcount [bship],321,7,cl_Blue,5*65536
873
    outcount [bship],321,7,cl_Blue,5*65536
863
    drawfbox 360,6,6*5+2 ,9,cl_Grey
874
    drawfbox 360,6,6*5+2 ,9,cl_Grey
864
    outcount [boxget],361,7,0xffaa00,5*65536
875
    outcount [boxget],361,7,0xffaa00,5*65536
865
 
876
 
866
    drawfbox 400,2,6*5+2 ,9,cl_Grey
877
    drawfbox 400,2,6*5+2 ,9,cl_Grey
867
    outcount [objects],401,2,0x00ff00,5*65536
878
    outcount [objects],401,2,0x00ff00,5*65536
868
    drawfbox 400,11,6*5+2 ,9,cl_Grey
879
    drawfbox 400,11,6*5+2 ,9,cl_Grey
869
    outcount [energy],401,12,0xff0000,5*65536
880
    outcount [energy],401,12,0xff0000,5*65536
870
 
881
 
871
    drawfbox 450,11,6*5+2 ,9,cl_Grey
882
    drawfbox 450,11,6*5+2 ,9,cl_Grey
872
    outcount [score],451,12,0xffff00,5*65536
883
    outcount [score],451,12,0xffff00,5*65536
873
 
884
 
874
 
885
 
875
    jmp  still
886
    jmp  still
876
 
887
 
877
  red:
888
  red:
878
    call draw_window
889
    call draw_window
879
    jmp still
890
    jmp still
880
 
891
 
881
  key:                          ; key
892
  key:                          ; key
882
    mov  eax,2
893
    mov  eax,2
883
    mcall                   ; read (eax=2)
894
    mcall                   ; read (eax=2)
884
 
895
 
885
    shr eax,8
896
    shr eax,8
886
    and eax,0xff
897
    and eax,0xff
887
    mov ah,al
898
    mov ah,al
888
 
899
 
889
    cmp ah,153
900
    cmp ah,153
890
    jne no_pause
901
    jne no_pause
891
    not [pause_on]
902
    not [pause_on]
892
    jmp still
903
    jmp still
893
no_pause:
904
no_pause:
894
 
905
 
895
 
906
 
896
    cmp ah,76
907
    cmp ah,76
897
    jne no_num5d
908
    jne no_num5d
898
    mov [num5],1
909
    mov [num5],1
899
    jmp still
910
    jmp still
900
no_num5d:
911
no_num5d:
901
    cmp ah,204
912
    cmp ah,204
902
    jne no_num5u
913
    jne no_num5u
903
    mov [num5],0
914
    mov [num5],0
904
    jmp still
915
    jmp still
905
no_num5u:
916
no_num5u:
906
 
917
 
907
    cmp ah,80
918
    cmp ah,80
908
    jne no_num2d
919
    jne no_num2d
909
    mov [num2],1
920
    mov [num2],1
910
    jmp still
921
    jmp still
911
no_num2d:
922
no_num2d:
912
    cmp ah,208
923
    cmp ah,208
913
    jne no_num2u
924
    jne no_num2u
914
    mov [num2],0
925
    mov [num2],0
915
    jmp still
926
    jmp still
916
no_num2u:
927
no_num2u:
917
 
928
 
918
    cmp ah,79 ;key_Space 85 exit
929
    cmp ah,79 ;key_Space 85 exit
919
    jne no_num1d
930
    jne no_num1d
920
    mov [num1],1
931
    mov [num1],1
921
    jmp still
932
    jmp still
922
no_num1d:
933
no_num1d:
923
    cmp ah,207 ;key_Space 85 exit
934
    cmp ah,207 ;key_Space 85 exit
924
    jne no_num1u
935
    jne no_num1u
925
    mov [num1],0
936
    mov [num1],0
926
    jmp still
937
    jmp still
927
no_num1u:
938
no_num1u:
928
 
939
 
929
    cmp ah,81 ;key_Space 85 exit
940
    cmp ah,81 ;key_Space 85 exit
930
    jne no_num3d
941
    jne no_num3d
931
    mov [num3],1
942
    mov [num3],1
932
    jmp still
943
    jmp still
933
no_num3d:
944
no_num3d:
934
    cmp ah,209 ;key_Space 85 exit
945
    cmp ah,209 ;key_Space 85 exit
935
    jne no_num3u
946
    jne no_num3u
936
    mov [num3],0
947
    mov [num3],0
937
    jmp still
948
    jmp still
938
no_num3u:
949
no_num3u:
939
 
950
 
940
    cmp ah,72  ;key_Space 85 exit
951
    cmp ah,72  ;key_Space 85 exit
941
    jne no_num8d
952
    jne no_num8d
942
    mov [num8],1
953
    mov [num8],1
943
    jmp still
954
    jmp still
944
no_num8d:
955
no_num8d:
945
    cmp ah,200 ;key_Space 85 exit
956
    cmp ah,200 ;key_Space 85 exit
946
    jne no_num8u
957
    jne no_num8u
947
    mov [num8],0
958
    mov [num8],0
948
    jmp still
959
    jmp still
949
no_num8u:
960
no_num8u:
950
 
961
 
951
    jmp  still                  ; not testing
962
    jmp  still                  ; not testing
952
 
963
 
953
  button:                       ; button
964
  button:                       ; button
954
    mov  eax,17                 ; get id
965
    mov  eax,17                 ; get id
955
    mcall
966
    mcall
956
    cmp  ah,1                   ; button id=1 ?
967
    cmp  ah,1                   ; button id=1 ?
957
    jne  noclose
968
    jne  noclose
958
close_app:
969
close_app:
959
    mov  eax,-1                 ; close this program
970
    mov  eax,-1                 ; close this program
960
    mcall
971
    mcall
961
  noclose:
972
  noclose:
962
    jmp  still
973
    jmp  still
963
 
974
 
964
draw_window:
975
draw_window:
965
    startwd
976
    startwd
966
    window 40,40,(640+9),(440+26),window_Skinned+0x00
977
    window 40,40,(640+9),(440+26),window_Skinned+0x00
967
    label  8,8,'ASCL DYNAMIC GAME',cl_White+font_Big
978
    label  8,8,'ASCL DYNAMIC GAME',cl_White+font_Big
968
;    setimg 5,22,img_area
979
;    setimg 5,22,img_area
969
    endwd
980
    endwd
970
    ret
981
    ret
971
 
982
 
972
;**********************
983
;**********************
973
;  Game Over process
984
;  Game Over process
974
;**********************
985
;**********************
975
 
986
 
976
game_over:
987
game_over:
977
;    close
988
;    close
978
    call draw_gowindow
989
    call draw_gowindow
979
stillgo:
990
stillgo:
980
    wtevent redgo,keygo,buttongo
991
    wtevent redgo,keygo,buttongo
981
    jmp stillgo
992
    jmp stillgo
982
redgo:
993
redgo:
983
    call draw_gowindow
994
    call draw_gowindow
984
    jmp stillgo
995
    jmp stillgo
985
keygo:
996
keygo:
986
    mov  eax,2
997
    mov  eax,2
987
    mcall
998
    mcall
988
    jmp  stillgo
999
    jmp  stillgo
989
buttongo:
1000
buttongo:
990
    mov  eax,17                 ; get id
1001
    mov  eax,17                 ; get id
991
    mcall
1002
    mcall
992
    cmp  ah,1
1003
    cmp  ah,1
993
    je   close_app
1004
    je   close_app
994
    cmp  ah,4
1005
    cmp  ah,4
995
    je   close_app
1006
    je   close_app
996
    cmp  ah,5
1007
    cmp  ah,5
997
    je   main_menu
1008
    je   main_menu
998
    cmp  ah,7
1009
    cmp  ah,7
999
    je   restart_lev
1010
    je   restart_lev
1000
    jmp  stillgo
1011
    jmp  stillgo
1001
 
1012
 
1002
restart_lev:
1013
restart_lev:
1003
    mov [pathtime],0
1014
    mov [pathtime],0
1004
 
1015
 
1005
prevpart:
1016
prevpart:
1006
    mov ebp,[levelpart]
1017
    mov ebp,[levelpart]
1007
    shl ebp,5
1018
    shl ebp,5
1008
    add ebp,levels
1019
    add ebp,levels
1009
    mov eax,[ebp]
1020
    mov eax,[ebp]
1010
    cmp eax,dword 1
1021
    cmp eax,dword 1
1011
    je  rest    ;end of level
1022
    je  rest    ;end of level
1012
    dec [levelpart]
1023
    dec [levelpart]
1013
    jmp prevpart
1024
    jmp prevpart
1014
 
1025
 
1015
 
1026
 
1016
rest:
1027
rest:
1017
;massives reset - clear massives
1028
;massives reset - clear massives
1018
    mov edi,massive+8
1029
    mov edi,massive+8
1019
    cld
1030
    cld
1020
    mov ecx,massize*elemsize/4
1031
    mov ecx,massize*elemsize/4
1021
    mov eax,0
1032
    mov eax,0
1022
    rep stosd
1033
    rep stosd
1023
 
1034
 
1024
    mov edi,objmas+8
1035
    mov edi,objmas+8
1025
    cld
1036
    cld
1026
    mov ecx,omassize*oelemsize/4
1037
    mov ecx,omassize*oelemsize/4
1027
    mov eax,0
1038
    mov eax,0
1028
    rep stosd
1039
    rep stosd
1029
 
1040
 
1030
;counters reset
1041
;counters reset
1031
    mov [boxget],0
1042
    mov [boxget],0
1032
    mov [gship],0
1043
    mov [gship],0
1033
    mov [bship],0
1044
    mov [bship],0
1034
 
1045
 
1035
;ship reset
1046
;ship reset
1036
    mov [energy],100
1047
    mov [energy],100
1037
    mov [shipx],300
1048
    mov [shipx],300
1038
    mov [shipy],400
1049
    mov [shipy],400
1039
    mov [lazer],1000
1050
    mov [lazer],1000
1040
    mov [plazma],500
1051
    mov [plazma],500
1041
 
1052
 
1042
 
1053
 
1043
; reset keyboard
1054
; reset keyboard
1044
    mov [num1],0
1055
    mov [num1],0
1045
    mov [num5],0
1056
    mov [num5],0
1046
    mov [num3],0
1057
    mov [num3],0
1047
    mov [num2],0
1058
    mov [num2],0
1048
    mov [num8],0
1059
    mov [num8],0
1049
    jmp start_game
1060
    jmp start_game
1050
 
1061
 
1051
draw_gowindow:
1062
draw_gowindow:
1052
    startwd
1063
    startwd
-
 
1064
    call draw_window
-
 
1065
    mcall 9,proc_info,-1
-
 
1066
    test [proc_info+process_information.wnd_state], 0x04
-
 
1067
    jz   @f
-
 
1068
    ret
-
 
1069
  @@:
1053
    drawfbox 170,160,300,120,cl_Grey
1070
    drawfbox 170,160,300,120,cl_Grey
1054
    drawlbut 180,260,80,14,'(X) EXIT',4,0x990000,cl_Black
1071
    drawlbut 180,260,80,14,'(X) EXIT',4,0x990000,cl_Black
1055
    drawlbut 280,260,80,14,'',5,0x990000,cl_Black
1072
    drawlbut 280,260,80,14,'',5,0x990000,cl_Black
1056
    drawlbut 380,260,80,14,'RESTART',7,0x990000,cl_Black
1073
    drawlbut 380,260,80,14,'RESTART',7,0x990000,cl_Black
1057
 
1074
 
1058
    label 280,200,'  GAME OVER  ',cl_Black
1075
    label 280,200,'  GAME OVER  ',cl_Black
1059
    endwd
1076
    endwd
1060
    ret
1077
    ret
1061
 
1078
 
1062
 
1079
 
1063
;**********************
1080
;**********************
1064
;  End level process
1081
;  End level process
1065
;**********************
1082
;**********************
1066
 
1083
 
1067
end_lev:
1084
end_lev:
1068
;    close
1085
;    close
1069
    call draw_scorewindow
1086
    call draw_scorewindow
1070
stilleg:
1087
stilleg:
1071
    wtevent redeg,keyeg,buttoneg
1088
    wtevent redeg,keyeg,buttoneg
1072
    jmp stilleg
1089
    jmp stilleg
1073
redeg:
1090
redeg:
1074
    call draw_scorewindow
1091
    call draw_scorewindow
1075
    jmp stilleg
1092
    jmp stilleg
1076
keyeg:
1093
keyeg:
1077
    mov  eax,2
1094
    mov  eax,2
1078
    mcall
1095
    mcall
1079
    jmp  stilleg
1096
    jmp  stilleg
1080
buttoneg:
1097
buttoneg:
1081
    mov  eax,17                 ; get id
1098
    mov  eax,17                 ; get id
1082
    mcall
1099
    mcall
1083
    cmp  ah,1
1100
    cmp  ah,1
1084
    je   close_app
1101
    je   close_app
1085
    cmp  ah,2
1102
    cmp  ah,2
1086
    je   next_lev
1103
    je   next_lev
1087
    cmp  ah,3
1104
    cmp  ah,3
1088
    je   help
1105
    je   help
1089
    cmp  ah,4
1106
    cmp  ah,4
1090
    je   close_app
1107
    je   close_app
1091
    cmp  ah,5
1108
    cmp  ah,5
1092
    je   main_menu
1109
    je   main_menu
1093
    jmp  stilleg
1110
    jmp  stilleg
1094
 
1111
 
1095
next_lev:
1112
next_lev:
1096
    mov [pathtime],0
1113
    mov [pathtime],0
1097
    inc [levelpart]
1114
    inc [levelpart]
1098
 
1115
 
1099
;ship reset
1116
;ship reset
1100
    mov [energy],100
1117
    mov [energy],100
1101
    mov [shipx],300
1118
    mov [shipx],300
1102
    mov [shipy],400
1119
    mov [shipy],400
1103
    mov [lazer],1000
1120
    mov [lazer],1000
1104
    mov [plazma],500
1121
    mov [plazma],500
1105
 
1122
 
1106
;counters reset
1123
;counters reset
1107
    mov [boxget],0
1124
    mov [boxget],0
1108
    mov [gship],0
1125
    mov [gship],0
1109
    mov [bship],0
1126
    mov [bship],0
1110
 
1127
 
1111
; reset keyboard
1128
; reset keyboard
1112
    mov [num1],0
1129
    mov [num1],0
1113
    mov [num5],0
1130
    mov [num5],0
1114
    mov [num3],0
1131
    mov [num3],0
1115
    mov [num2],0
1132
    mov [num2],0
1116
    mov [num8],0
1133
    mov [num8],0
1117
    jmp start_game
1134
    jmp start_game
1118
 
1135
 
1119
draw_scorewindow:
1136
draw_scorewindow:
1120
    call draw_window
1137
    call draw_window
-
 
1138
    mcall 9,proc_info,-1
-
 
1139
    test [proc_info+process_information.wnd_state], 0x04
-
 
1140
    jz   @f
-
 
1141
    ret
-
 
1142
  @@:
1121
    startwd
1143
    startwd
1122
    drawfbox 170,130,300,190,cl_Grey
1144
    drawfbox 170,130,300,190,cl_Grey
1123
    drawlbut 180,300,80,14,'(X) EXIT',4,0x990000,cl_Black
1145
    drawlbut 180,300,80,14,'(X) EXIT',4,0x990000,cl_Black
1124
    drawlbut 280,300,80,14,'',5,0x990000,cl_Black
1146
    drawlbut 280,300,80,14,'',5,0x990000,cl_Black
1125
    drawlbut 380,300,80,14,'NEXT >>',2,0x990000,cl_Black
1147
    drawlbut 380,300,80,14,'NEXT >>',2,0x990000,cl_Black
1126
 
1148
 
1127
    setimg 180,140,warship1
1149
    setimg 180,140,warship1
1128
    outcount [bship],241,151,cl_Blue,5*65536
1150
    outcount [bship],241,151,cl_Blue,5*65536
1129
 
1151
 
1130
    setimg 180,180,warship2
1152
    setimg 180,180,warship2
1131
    outcount [gship],241,191,cl_Green,5*65536
1153
    outcount [gship],241,191,cl_Green,5*65536
1132
 
1154
 
1133
    setimg 180,220,meteor
1155
    setimg 180,220,meteor
1134
    setimg 180,260,box
1156
    setimg 180,260,box
1135
    outcount [boxget],241,271,0xbbbb00,5*65536
1157
    outcount [boxget],241,271,0xbbbb00,5*65536
1136
    endwd
1158
    endwd
1137
    ret
1159
    ret
1138
 
1160
 
1139
 
1161
 
1140
;**********************
1162
;**********************
1141
;  End of game process
1163
;  End of game process
1142
;**********************
1164
;**********************
1143
 
1165
 
1144
end_gm:
1166
end_gm:
1145
    mov [pathtime],0
1167
    mov [pathtime],0
1146
    call draw_window
1168
    call draw_window
1147
    label 200 ,8,'YOU WIN PRESS ANY KEY TO EXIT',cl_White+font_Big
1169
    label 200 ,8,'YOU WIN PRESS ANY KEY TO EXIT',cl_White+font_Big
1148
 
1170
 
1149
stilleg2:
1171
stilleg2:
1150
;    scevent   redeg2,keyeg2,buttoneg2
1172
;    scevent   redeg2,keyeg2,buttoneg2
1151
    timeevent 1,no_event2,redeg2,keyeg2,buttoneg2
1173
    timeevent 1,no_event2,redeg2,keyeg2,buttoneg2
1152
 
1174
 
1153
no_event2:
1175
no_event2:
1154
    setimg 5,21,canvas
1176
    setimg 5,21,canvas
1155
 
1177
 
1156
;clear scrbuf
1178
;clear scrbuf
1157
    mov edi,canvas+8
1179
    mov edi,canvas+8
1158
    cld
1180
    cld
1159
    mov ecx,640*440*3/4
1181
    mov ecx,640*440*3/4
1160
    mov eax,0
1182
    mov eax,0
1161
    rep stosd
1183
    rep stosd
1162
 
1184
 
1163
    aimgtoimg ship,320,220,canvas,0x0
1185
    aimgtoimg ship,320,220,canvas,0x0
1164
 
1186
 
1165
    readmas massive,endshowmas
1187
    readmas massive,endshowmas
1166
    readmas massive,endmovemas
1188
    readmas massive,endmovemas
1167
    readmas massive,delfarshoot
1189
    readmas massive,delfarshoot
1168
;    findmas massive,findzero
1190
;    findmas massive,findzero
1169
;in edi off to free element
1191
;in edi off to free element
1170
;    jc  close_app
1192
;    jc  close_app
1171
 
1193
 
1172
    inc [pathtime]
1194
    inc [pathtime]
1173
    cmp [pathtime],30
1195
    cmp [pathtime],30
1174
    jne no_firework
1196
    jne no_firework
1175
    mov [pathtime],0
1197
    mov [pathtime],0
1176
    random 400,eax
1198
    random 400,eax
1177
    mov [temp3],eax
1199
    mov [temp3],eax
1178
    random 600,eax
1200
    random 600,eax
1179
    mov [temp2],eax
1201
    mov [temp2],eax
1180
    mov [temp],dword 8;10
1202
    mov [temp],dword 8;10
1181
xloox:
1203
xloox:
1182
    findmas massive,findzero
1204
    findmas massive,findzero
1183
;in edi off to free element
1205
;in edi off to free element
1184
    jc  close_app
1206
    jc  close_app
1185
 
1207
 
1186
    mov eax,[temp2] ;[shipx]
1208
    mov eax,[temp2] ;[shipx]
1187
    mov [edi],eax
1209
    mov [edi],eax
1188
    mov eax,[temp3] ;[shipy]
1210
    mov eax,[temp3] ;[shipy]
1189
    mov [edi+4],eax
1211
    mov [edi+4],eax
1190
    mov [edi+8],dword 2   ;show hstar
1212
    mov [edi+8],dword 2   ;show hstar
1191
rerand:
1213
rerand:
1192
    random 5,eax
1214
    random 5,eax
1193
    sub eax,2
1215
    sub eax,2
1194
    cmp eax,0
1216
    cmp eax,0
1195
    je  rerand
1217
    je  rerand
1196
    mov [edi+12],eax   ;show hstar
1218
    mov [edi+12],eax   ;show hstar
1197
rerand2:
1219
rerand2:
1198
    random 7,eax
1220
    random 7,eax
1199
    sub eax,3
1221
    sub eax,3
1200
    cmp eax,0
1222
    cmp eax,0
1201
    je  rerand2
1223
    je  rerand2
1202
    mov [edi+16],eax   ;show hstar
1224
    mov [edi+16],eax   ;show hstar
1203
    dec [temp]
1225
    dec [temp]
1204
    jnz xloox
1226
    jnz xloox
1205
no_firework:
1227
no_firework:
1206
    jmp stilleg2
1228
    jmp stilleg2
1207
 
1229
 
1208
redeg2:
1230
redeg2:
1209
    jmp end_gm ;stilleg2
1231
    jmp end_gm ;stilleg2
1210
keyeg2:
1232
keyeg2:
1211
    mov  eax,2
1233
    mov  eax,2
1212
    mcall
1234
    mcall
1213
    jmp  main_menu
1235
    jmp  main_menu
1214
buttoneg2:
1236
buttoneg2:
1215
    mov  eax,17                 ; get id
1237
    mov  eax,17                 ; get id
1216
    mcall
1238
    mcall
1217
    jmp  stilleg2
1239
    jmp  stilleg2
1218
 
1240
 
1219
 
1241
 
1220
 
1242
 
1221
 
1243
 
1222
 
1244
 
1223
 
1245
 
1224
; DATA AREA
1246
; DATA AREA
1225
IM_END:
1247
IM_END:
1226
;global
1248
;global
1227
pause_on dd 0
1249
pause_on dd 0
1228
 
1250
 
1229
;massive
1251
;massive
1230
shipx dd 300
1252
shipx dd 300
1231
shipy dd 400
1253
shipy dd 400
1232
 
1254
 
1233
;guns
1255
;guns
1234
lazer  dd 1000
1256
lazer  dd 1000
1235
plazma dd 500
1257
plazma dd 500
1236
 
1258
 
1237
;keys
1259
;keys
1238
num1 dd 0
1260
num1 dd 0
1239
num5 dd 0
1261
num5 dd 0
1240
num3 dd 0
1262
num3 dd 0
1241
num2 dd 0
1263
num2 dd 0
1242
num8 dd 0
1264
num8 dd 0
1243
 
1265
 
1244
;enemy countres
1266
;enemy countres
1245
gship  dd 0
1267
gship  dd 0
1246
bship  dd 0
1268
bship  dd 0
1247
boxget dd 0
1269
boxget dd 0
1248
 
1270
 
1249
energy dd 100
1271
energy dd 100
1250
score  dd 0
1272
score  dd 0
1251
 
1273
 
1252
;delay for cannon
1274
;delay for cannon
1253
ctime dd 0
1275
ctime dd 0
1254
;delay for nuke gun
1276
;delay for nuke gun
1255
xtime dd 0
1277
xtime dd 0
1256
;path time
1278
;path time
1257
pathtime dd 0
1279
pathtime dd 0
1258
;
1280
;
1259
temp  dd 0
1281
temp  dd 0
1260
temp2 dd 0
1282
temp2 dd 0
1261
temp3 dd 0
1283
temp3 dd 0
1262
temp4 dd 0
1284
temp4 dd 0
1263
otv dd 0
1285
otv dd 0
1264
 
1286
 
1265
;for collimg
1287
;for collimg
1266
imgsize:
1288
imgsize:
1267
 dd 32
1289
 dd 32
1268
 dd 32
1290
 dd 32
1269
 
1291
 
1270
;massive:
1292
;massive:
1271
;dd 400  ;elements num
1293
;dd 400  ;elements num
1272
;dd 20  ;size of element in bytes
1294
;dd 20  ;size of element in bytes
1273
;rb 400*20
1295
;rb 400*20
1274
 
1296
 
1275
keymap:
1297
keymap:
1276
rb 1000
1298
rb 1000
1277
 
1299
 
1278
;gif_file_area ~21500
1300
;gif_file_area ~21500
1279
gif_file_area2:
1301
gif_file_area2:
1280
file 'phenix.gif'
1302
file 'phenix.gif'
1281
gif_file_area:
1303
gif_file_area:
1282
file 'star2.gif';include gif file
1304
file 'star2.gif';include gif file
1283
img_area:
1305
img_area:
1284
rb 256*64*3+8
1306
rb 256*64*3+8
1285
ship:
1307
ship:
1286
rb 32*32*3+8
1308
rb 32*32*3+8
1287
shoot:
1309
shoot:
1288
rb 32*32*3+8
1310
rb 32*32*3+8
1289
warship1:
1311
warship1:
1290
rb 32*32*3+8
1312
rb 32*32*3+8
1291
warship2:
1313
warship2:
1292
rb 32*32*3+8
1314
rb 32*32*3+8
1293
meteor:
1315
meteor:
1294
rb 32*32*3+8
1316
rb 32*32*3+8
1295
star:
1317
star:
1296
rb 32*32*3+8
1318
rb 32*32*3+8
1297
star2:
1319
star2:
1298
rb 32*32*3+8
1320
rb 32*32*3+8
1299
star3:
1321
star3:
1300
rb 32*32*3+8
1322
rb 32*32*3+8
1301
box:
1323
box:
1302
rb 32*32*3+8
1324
rb 32*32*3+8
1303
 
1325
 
1304
IncludeUGlobals
1326
IncludeUGlobals
1305
 
1327
 
1306
massive:
1328
massive:
1307
rd massize  ;elements num
1329
rd massize  ;elements num
1308
rd elemsize  ;size of element in bytes
1330
rd elemsize  ;size of element in bytes
1309
rb massize*elemsize
1331
rb massize*elemsize
1310
 
1332
 
1311
objmas:
1333
objmas:
1312
rd omassize  ;elements num
1334
rd omassize  ;elements num
1313
rd oelemsize  ;size of element in bytes
1335
rd oelemsize  ;size of element in bytes
1314
rb omassize*oelemsize
1336
rb omassize*oelemsize
1315
 
1337
 
1316
canvas:
1338
canvas:
1317
canvas_x:
1339
canvas_x:
1318
 rd 1
1340
 rd 1
1319
canvas_y:
1341
canvas_y:
1320
 rd 1
1342
 rd 1
1321
rb (640*440*3)+2000
1343
rb (640*440*3)+2000
-
 
1344
 
-
 
1345
proc_info:
-
 
1346
rb 1024
1322
I_END:
1347
I_END:
1323
 
1348
 
1324
>
1349
>
1325
 
1350
 
1326
>
1351
>