1719Close
VasiliyFamiliyaOn the 2019-03-10 at 02:29pm
0331C8: 1039 0010 FD96 move.b $10fd96.l, D0 ; P1_CURRENT value moving to D0 0331CE: 0240 000F andi.w #$f, D0 ; D0 first 4 bits (active joystick directions) check 0331D2: 41FA 0020 lea ($20,PC) ; ($331f4), A0 0331D6: 4E71 nop 0331D8: 7200 moveq #$0, D1 ; D1=0 0331DA: 1230 0000 move.b (A0,D0.w), D1 ; D1=[$331f4]+D0 (why to zeroize D1 before it?) 0331DE: 6B00 0012 bmi $331f2 ; end of suroutine if result of [$331f4]+D0 moving to D1 is negative 0331E2: D241 add.w D1, D1 0331E4: D241 add.w D1, D1 ; else ([$331f4]+D0)*4 (why so strange way to do it has been selected?) 0331E6: 41FA 001C lea ($1c,PC) ; ($33204), A0 0331EA: 4E71 nop 0331EC: 2070 1000 movea.l (A0,D1.w), A0 ; A0=[$33204]+(([$331f4]+D0)*4) 0331F0: 4E90 jsr (A0) ; goto [$33204]+(([$331f4]+(P1_CURRENT value&#$f))*4) address 0331F2: 4E75 rts