wok-tiny diff bootris/stuff/tetranglix.asm @ rev 183
linux: fix bundle.S
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Sep 26 17:09:38 2023 +0000 (8 months ago) |
parents | bbb34fe4904d |
children | 61c76233911e |
line diff
1.1 --- a/bootris/stuff/tetranglix.asm Sun Sep 24 17:53:05 2023 +0000 1.2 +++ b/bootris/stuff/tetranglix.asm Tue Sep 26 17:09:38 2023 +0000 1.3 @@ -39,6 +39,9 @@ 1.4 ; Clear direction flag. 1.5 cld 1.6 1.7 + ; Allow interrupts 1.8 + sti 1.9 + 1.10 ; Clear BSS 1.11 mov di, BSS 1.12 mov cx, di ;at least BSS_SIZE 1.13 @@ -190,7 +193,7 @@ 1.14 mov si, OFFSET 1.15 1.16 ; For some reason this doesn't work with BootOS over VirtualBox 5.1.22 1.17 - %if 0 1.18 + %ifdef READ_PIT 1.19 mov bx, [0x046C] 1.20 inc bx 1.21 inc bx ; Wait for 2 PIT ticks. 1.22 @@ -227,7 +230,11 @@ 1.23 in al,(0x40) 1.24 1.25 ; Only 7 tetraminos, index as 1-7. 1.26 + %ifdef READ_PIT 1.27 and ax, 7 1.28 + %else 1.29 + and al, 7 ; ah = 0 1.30 + %endif 1.31 je .choose_tetramino 1.32 1.33 ; Get the address of the tetramino (in bitmap format). 1.34 @@ -410,7 +417,7 @@ 1.35 1.36 .game_over: ; Game Over 1.37 xor ax, ax 1.38 - int 0x16 ; wait for and key 1.39 + int 0x16 ; wait for a key 1.40 dec ah 1.41 jmp exit_game_over 1.42