That'll get you a .S file with all the ASM. Inside look for lis and ori commands, like the ones I posted above. Once you've worked out what to change them to, create a new .S file with contents like this:
Code:lis r31,-32768 ;0x8000 ori r31,r31,5892 ;0x1704
Then compile this smaller .S file with this command:
powerpc-eabi-as -mregnames -be example.S
This will generate a file "a.out", we just want the binary code, so after the above run:
powerpc-eabi-objcopy -O binary a.out a.bin
a.bin will (in the above example) now be an 8 byte file containing the two commands above. Open with a hex editor, copy these 8 bytes and overwrite the original 8 bytes in Loader.bin.
Repeat for each lis & ori pair.
100: 93 c1 00 58 stw r30,88(r1)
104: 93 a1 00 54 stw r29,84(r1)
108: 38 c0 00 31 li r6,49
10c: 3c a0 80 76 lis r5,-32650
110: 60 a5 8d 50 ori r5,r5,36176
114: 80 65 00 00 lwz r3,0(r5)
118: 54 63 04 3e clrlwi r3,r3,16
11c: 2c 03 6d e1 cmpwi r3,28129
120: 41 82 00 44 beq- 0x164
124: 2c 03 6c a1 cmpwi r3,27809
128: 41 82 00 48 beq- 0x170
12c: 2c 03 6a b1 cmpwi r3,27313
130: 41 82 00 4c beq- 0x17c
134: 2c 03 00 14 cmpwi r3,20
138: 40 82 03 30 bne- 0x468
# wit dump pool/nsmb/main.dol --long
....
Delta between file offset and virtual address:
unused : off(beg) .. off(end) : size : delta : section
----------------------------------------------------------------------
: 80004000 .. 800066c0 : 26c0 : 80003f00 : text #0
: 800066c0 .. 80006720 : 60 : 7fd1c9a0 : data #0
: 80006720 .. 80006780 : 60 : 7fd1c9a0 : data #1
: 80006780 .. 802edce0 : 2e7560 : 80003fc0 : text #1
: 802edce0 .. 802edfc0 : 2e0 : 80003f00 : data #2
: 802edfc0 .. 802edfe0 : 20 : 80003f00 : data #3
: 802edfe0 .. 802fe6a0 : 106c0 : 80003f00 : data #4
: 802fe6a0 .. 80351980 : 532e0 : 80003f00 : data #5
d6000 : 80427980 .. 80429ea0 : 2520 : 800d9f00 : data #6
14c0 : 8042b360 .. 8042fec0 : 4b60 : 800db3c0 : data #7
# wit dolpat nsmb/main.dol -d nsmb/res.dol nsmb/NewerSMBW.xml
+Patched: [D4] addr 802f148c+07, offset 2ed58c: 77 69 69 6d 6a 32 64 -> 4e 65 72 53 4d 42 57
-Original differ: [D4] addr 802f118c+07, offset 2ed28c: 00 00 00 00 80 31 65
-Original differ: [D4] addr 802f0fac+07, offset 2ed0ac: 00 00 00 2a 00 00 00
+Patched: [D5] addr 80328478+04, offset 324578: 80 15 bc 60 -> 80 00 18 00
-Original differ: [D5] addr 80328130+04, offset 324230: 80 15 a5 b0
-Original differ: [D5] addr 80327e98+04, offset 323f98: 72 75 5f 30
+Patched: [T1] addr 800e4a84+04, offset e0ac4: 3c 60 01 20 -> 3c 60 01 40
-Original differ: [T1] addr 800e4994+04, offset e09d4: 80 84 00 4c
-Original differ: [T1] addr 800e4914+04, offset e0954: 00 00 00 00
+Patched: [T1] addr 800b64ec+04, offset b252c: 3c 80 00 30 -> 3c 80 00 32
-Original differ: [T1] addr 800b649c+04, offset b24dc: 4e 80 00 20
-Original differ: [T1] addr 800b641c+04, offset b245c: 83 e3 00 08
+Patched: [T1] addr 801b0204+04, offset 1ac244: 54 00 ff fe -> 38 00 00 00
-Original differ: [T1] addr 801b00c4+04, offset 1ac104: 39 46 00 12
-Original differ: [T1] addr 801afed4+04, offset 1abf14: 83 a1 00 44
+Patched: [T1] addr 8015d850+04, offset 159890: 38 60 00 00 -> 4e 80 00 20
-Original differ: [T1] addr 8015d710+04, offset 159750: 40 82 00 40
-Original differ: [T1] addr 8015d520+04, offset 159560: 81 9e 00 74
+Patched: [T1] addr 800e4e84+04, offset e0ec4: 38 63 33 0c -> 38 60 00 00
-Original differ: [T1] addr 800e4d70+04, offset e0db0: 90 7f 00 4c
-Original differ: [T1] addr 800e4cf0+04, offset e0d30: 41 82 00 1c
!Can't patch: Range outside dol: addr 80001800+968
* Save patched DOL to: nsmb/res.dol
Well, according to GBAtemp's rules, it should be not allowed here to discuss how to bypass ap measures of programs.Is there something illegal about patching the ISO to use the Newer Super Mario Bros. hack to be read on USB loaders? I'm just wondering why people are so hush-hush about it.
As long as you ripped the ISO from your own disc, it's legal. People being "hush-hush" is probably because chances are most people wanting to patch the ISO have not done so, and don't own a disc copy. The Newer team made the decision not to create an ISO patch as well as the Riivolution patch for (at least partly) that reason.Is there something illegal about patching the ISO to use the Newer Super Mario Bros. hack to be read on USB loaders? I'm just wondering why people are so hush-hush about it.
Well, according to GBAtemp's rules, it should be not allowed here to discuss how to bypass ap measures of programs.
That looks like a 32/64 bit error. I tested it on linux/64 bit, and you'r using the Cygwin version? (cygwin is 32 bit system).
it should be not allowed here to discuss how to bypass ap measures of programs.
As long as you ripped the ISO from your own disc, it's legal. People being "hush-hush" is probably because chances are most people wanting to patch the ISO have not done so, and don't own a disc copy. The Newer team made the decision not to create an ISO patch as well as the Riivolution patch for (at least partly) that reason.
But patching the ISO isn't bypassing the AP measures of any program. That's already been done when the ISO was ripped. Newer itself doesn't have any AP, and you're not bypassing Riivolution's "AP" either. (I say "AP" because as I understand it, it is mostly a case of not implementing backup loading features, rather than explicitly blocking them. I think they blocked a couple of modchips, so that's why I say "mostly").
EDIT: Of course, if you're going to get really technical about that rule, it could be argued that any software with the ability to rip or play backups of games should be disallowed, but that'd discount about 90% of the discussions on the site.
It was an 32/64 bit issue. Bad programmer!That looks like a 32/64 bit error. I tested it on linux/64 bit, and you'r using the Cygwin version? (cygwin is 32 bit system).
It was an 32/64 bit issue. Bad programmer!
A bug fix update is online now.