|Bugfixes and patches to JSW48|
POKE 59900,255or the arrow can be fixed with
POKE 59901,82and can be applied to the JSW48 code with Attic.hex.
POKE 33797,135:POKE 33800,202will do this.
Original code: Changed to: 8404 36 86 LD (HL),&86 8404 36 87 LD (HL),&87 8406 2B DEC HL 8406 2B DEC HL 8407 36 9F LD (HL),&9F 8407 36 CA LD (HL),&CAThis can be applied to the JSW48 code with NoPass.hex or with NoPass2.hex which releases more code space.
This releases the following code space:
|Address||Previous use||New use|
|&9B00-&9BFF||sprite and screen data||becomes room 91|
|&9E00-&9EFF||password data||becomes room 94|
Original code: Changed to: 9651 16 9D LD D,&9D 9651 16 9D LD D,&9D 9653 3A 20 84 LD A,(HERE) 9653 3A ED 80 LD A,(WILLYSP) 9656 FE 1D CP &1D 9656 A7 AND A 9658 20 06 JR NZ,&9660 9657 F2 60 96 JP P,L9660 965A 16 B6 LD D,&B6 965A 57 LD D,A 965B 00 NOPThis can be done by using the following:
POKE 38484,237:POKE 38485,128:POKE 38486,167 POKE 38487,242:POKE 38488,96:POKE 38489,150 POKE 38490,87:POKE 38491,0and with the WillySP.hex patch file. If this patch is used, then WILLYSP must be set in The Nightmare Room to ensure that the flying pig is used, with
Two changes can be made here. The code can check for wall at head height when moving leftwards, so eliminating the quirk, or walls at head height can be ignored when moving rightwards, so making the quirk work in both directions.
Ignore walls in both directions
POKE 37032,0 will remove the check for walls when moving
rightwards. It can be applied with WallL.hex.
Original code: Changed to: 90A7 BE CP (HL) 90A7 BE CP (HL) 90A8 C8 RET Z 90A8 00 NOP
Check for walls in both directions
The quirk can be eliminated by checking for a wall block when moving left:
Original code: Changed to: 9035 22 D3 85 LD (POSITION),HL 9035 3A B2 80 LD A,(WALL) 9038 78 LD A,B 9038 BE CP (HL) 9039 32 CF 85 LD (YPOSN),A 9039 C8 RET Z 903C 3E 03 LD A,&03 903A 22 D3 85 LD (POSITION),HL 903E 32 D2 85 LD (FRAME),A 903D 3E 03 LD A,&03 9041 C9 RET 903F C3 AE 90 JP &90AEThis can be done by using the following:
POKE 36917,58:POKE 36918,178:POKE 36919,128 POKE 36920,190:POKE 36921,200:POKE 36922,34 POKE 36923,211:POKE 36924,133:POKE 36925,62 POKE 36926,3:POKE 36927,195:POKE 36928,174 POKE 36929,144This can be applied using the WallR.hex patch file.