Subversion Repositories Kolibri OS

Rev

Rev 1806 | Rev 3013 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1806 Rev 2075
Line 283... Line 283...
283
    jbe  .ex
283
    jbe  .ex
284
    and  [levnum],0
284
    and  [levnum],0
285
  .ex:
285
  .ex:
286
    pop  eax
286
    pop  eax
287
    ret
287
    ret
288
 
-
 
-
 
288
;---------------------------------------------------------------------
289
;   *********************************************
289
;   *********************************************
290
;   *******  WINDOW DEFINITIONS AND DRAW ********
290
;   *******  WINDOW DEFINITIONS AND DRAW ********
291
;   *********************************************
291
;   *********************************************
292
draw_window:
292
draw_window:
293
    pusha
293
    pusha
Line 298... Line 298...
298
    add   ebx,50 shl 16+XFOFS*2+20
298
    add   ebx,50 shl 16+XFOFS*2+20
299
    mov   ecx,[fy]
299
    mov   ecx,[fy]
300
    imul  ecx,[Ces]
300
    imul  ecx,[Ces]
301
    add   ecx,10 shl 16+YFOFS+30
301
    add   ecx,10 shl 16+YFOFS+30
302
    mcall 0,,,WNDCOLOR
302
    mcall 0,,,WNDCOLOR
-
 
303
    
303
    mov   esi,edx
304
	push	edx
-
 
305
	mcall	4,<8,8>,0x10ffffff,header,header.size
-
 
306
	pop	esi
304
    and   esi,0xffffff
307
	and	esi,0xffffff
305
    mcall 9,prc_info,-1
308
	mcall	9,prc_info,-1
306
    mov   ebx,[esp]
-
 
307
    pop   ebx
309
	pop	ebx
-
 
310
    
-
 
311
	mov	eax,[prc_info+70] ;status of window
-
 
312
	test	eax,100b
-
 
313
	jne	.end
-
 
314
    
308
    add   ebx,XFOFS shl 16+XFOFS*2
315
    add   ebx,XFOFS shl 16+XFOFS*2
Line 309... Line 316...
309
 
316
 
Line 310... Line 317...
310
    mcall 8,,<25,12>,2
317
    mcall 8,,<25,12>,2
311
 
318
 
312
    mcall 8,,<40,12>,3
319
    mcall 8,,<40,12>,3
313
    add   ebx,14 shl 16
320
    add   ebx,14 shl 16
314
    inc   edx
-
 
-
 
321
    inc   edx
315
    mcall
322
    mcall
316
    mcall 4,<8,8>,0x10ffffff,header,header.size
323
 
317
    mov   ecx,ebp
324
    mov   ecx,ebp
318
    mov   edx,game_names+4
325
    mov   edx,game_names+4
319
    call  get_mstr
326
    call  get_mstr
Line 323... Line 330...
323
    shl   esi,16
330
    shl   esi,16
324
    lea   edx,[ebx+esi]
331
    lea   edx,[ebx+esi]
325
    mcall 47,0x020001,levnum,,0x8000
332
    mcall 47,0x020001,levnum,,0x8000
Line 326... Line 333...
326
 
333
 
-
 
334
    mcall 4,,0x108000,next_msg,3
327
    mcall 4,,0x108000,next_msg,3
335
.end:
328
    mcall 12,2
336
    mcall 12,2
329
    popa
337
    popa
330
    ret
-
 
-
 
338
    ret
331
 
339
;---------------------------------------------------------------------
332
unpack_level:
340
unpack_level:
333
    mov   ecx,[cell_count]
341
    mov   ecx,[cell_count]
334
    mov   edi,field
342
    mov   edi,field
335
  .lp:
343
  .lp:
Line 338... Line 346...
338
    shl   ax,4
346
    shl   ax,4
339
    shr   al,4
347
    shr   al,4
340
    stosw
348
    stosw
341
    loop  .lp
349
    loop  .lp
342
    ret
350
    ret
343
 
-
 
-
 
351
;---------------------------------------------------------------------
344
get_xy:
352
get_xy:
345
; eax-coord
353
; eax-coord
346
; out: [lx]-[x+2][CS-4],[ly]-[y+2][CS-4]
354
; out: [lx]-[x+2][CS-4],[ly]-[y+2][CS-4]
347
    pusha
355
    pusha
348
    xor   edx,edx
356
    xor   edx,edx