A flight down a tunnel of light for DOS, in under 256 bytes. Every pixel asks the x87 for an angle and a depth.
63 - fog is 63 xor fog: -4 bytes
Browse filesFor 0 to 63 the two are equal, and xor cl, 63 is one instruction where neg and add were two. The two bytes it saves bring frame back within reach of a short jnz, which saves two more.
failing
1 step in 1 ms
1 file changed
+1−2
@@ -77,8 +77,7 @@ pixel:
7777 cmp cx, 63
7878 jbe .near
7979 mov cl, 63
80−.near: neg cl
81− add cl, 63
80+.near: xor cl, 63 ; 63 - fog
8281
8382 mov ax, [u]
8483 add ax, bp ; spin