[tmnt2pj] Teenage Mutant Ninja Turtles

This forum is for posting M.A.M.E. Work In Progress "Arcade"cheats that are not quite ready for the prime time. If the cheats are buggy or the cheat descriptions are non-standard then please post them here. Help maybe given but there are no guarantees and they will only be added to the cheat file when the cheat file maintainer is happy with them.
Post Reply
jman
Posts: 843
Joined: Tue Dec 01, 2020 1:24 pm

[tmnt2pj] Teenage Mutant Ninja Turtles

Post by jman »

Code: Select all

<cheat desc="no hit">
    <script state="on">
        <action>maincpu.mq@47afc = 4eb9000004006700</action>
        <action>maincpu.mq@00400 = 0c28001300066704</action>
        <action>maincpu.mq@00408 = 74004e7508110001</action>
        <action>maincpu.mq@00410 = 4e75000000000000</action>
        <!--
        00400 | 0c28 0013 0006 : cmpi.b #$13,($6,A0)
        00406 | 6704           : beq    $40c
        00408 | 7400           : moveq  #$0,D2
        0040a | 4e75           : rts
        0040c | 0811 0001      : btst   #$1,(A1)
        00410 | 4e75           : rts
        -->
    </script>
    <script state="off">
        <action>maincpu.mq@47afc = 0829000100006700</action>
        <action>maincpu.mq@00400 = 0000000000000000</action>
        <action>maincpu.mq@00408 = 0000000000000000</action>
        <action>maincpu.mq@00410 = 0000000000000000</action>
    </script>
</cheat>

<cheat desc="auto fire">
    <script state="on">
        <action>maincpu.mq@1ab1c = 4eb9000004400810</action>
        <action>maincpu.mq@00440 = 45f90006003c1012</action>
        <action>maincpu.mq@00448 = 02000020d4fc0010</action>
        <action>maincpu.mq@00450 = 81124e7500000000</action>
        <!--
        00440 | 45f9 0006 003c : lea    $6003c.l,A2
        00446 | 1012           : move.b (A2),D0
        00448 | 0200 0020      : andi.b #$20,D0
        0044c | d4fc 0010      : adda.w #$10,A2
        00450 | 8112           : or.b   D0,(A2)
        00452 | 4e75           : rts
        -->
    </script>
    <script state="off">
        <action>maincpu.mq@1ab1c = 45f90006004c0810</action>
        <action>maincpu.mq@00440 = 0000000000000000</action>
        <action>maincpu.mq@00448 = 0000000000000000</action>
        <action>maincpu.mq@00450 = 0000000000000000</action>
    </script>
</cheat>

<cheat desc="attack speed up">
    <script state="on">
        <action>maincpu.md@478c8 =         4eb80420</action>
        <action>maincpu.mq@00420 = b1fc00062140640c</action>
        <action>maincpu.mq@00428 = 0c28000300046604</action>
        <action>maincpu.mq@00430 = 70004e7553280033</action>
        <action>maincpu.mq@00438 = 4e75000000000000</action>
        <!--
        00420 | b1fc 0006 2140 : cmpa.l #$62140,A0
        00426 | 640c           : bcs    $434
        00428 | 0c28 0003 0004 : cmpi.b #$3,($4,A0)
        0042e | 6604           : bne    $434
        00430 | 7000           : moveq  #$0,D0
        00432 | 4e75           : rts
        00434 | 5328 0033      : subq.b #1,($33,A0)
        00438 | 4e75           : rts
        -->
    </script>
    <script state="off">
        <action>maincpu.md@478c8 =         53280033</action>
        <action>maincpu.mq@00420 = 0000000000000000</action>
        <action>maincpu.mq@00428 = 0000000000000000</action>
        <action>maincpu.mq@00430 = 0000000000000000</action>
        <action>maincpu.mq@00438 = 0000000000000000</action>
    </script>
</cheat>

<cheat desc="skip rom check">
    <script state="on">
        <action>maincpu.mb@0151f = 48</action>
    </script>
    <script state="off">
        <action>maincpu.mb@0151f = 26</action>
    </script>
</cheat>
I hope that "no hit" code will take care of problem for pizza. "auto fire" will work for player 1 only.
jman
Posts: 843
Joined: Tue Dec 01, 2020 1:24 pm

[tmnt2pj] Teenage Mutant Ninja Turtles (update)

Post by jman »

Code: Select all

<cheat desc="auto fire">
    <script state="on">
        <action>maincpu.md@1ab22 =         4eb80420</action>
        <action>maincpu.mq@00420 = 102afff002000020</action>
        <action>maincpu.mq@00428 = 8112081000004e75</action>
        <!--
        0420 | 102a fff0 : move.b (-$10,A2),D0
        0424 | 0200 0020 : andi.b #$20,D0
        0428 | 8112      : or.b   D0,(A2)
        042a | 0810 0000 : btst   #$0,(A0)
        042e | 4e75      : rts
        -->
    </script>
    <script state="off">
        <action>maincpu.md@1ab22 =         08100000</action>
        <action>maincpu.mq@00420 = 0000000000000000</action>
        <action>maincpu.mq@00428 = 0000000000000000</action>
    </script>
</cheat>
"auto fire" : fix "player 2 doesn't have auto fire" problem. reallocate address.

Code: Select all

<cheat desc="attack speed up">
    <script state="on">
        <action>maincpu.md@478c8 =         4eb80430</action>
        <action>maincpu.mq@00430 = b1fc00062140640c</action>
        <action>maincpu.mq@00438 = 0c28000300046604</action>
        <action>maincpu.mq@00440 = 70004e7553280033</action>
        <action>maincpu.mq@00448 = 4e75000000000000</action>
        <!--
        0430 | b1fc 0006 2140 : cmpa.l #$62140,A0
        0436 | 640c           : bcs    $444
        0438 | 0c28 0003 0004 : cmpi.b #$3,($4,A0)
        043e | 6604           : bne    $444
        0440 | 7000           : moveq  #$0,D0
        0442 | 4e75           : rts
        0444 | 5328 0033      : subq.b #1,($33,A0)
        0448 | 4e75           : rts
        -->
    </script>
    <script state="off">
        <action>maincpu.md@478c8 =         53280033</action>
        <action>maincpu.mq@00430 = 0000000000000000</action>
        <action>maincpu.mq@00438 = 0000000000000000</action>
        <action>maincpu.mq@00440 = 0000000000000000</action>
        <action>maincpu.mq@00448 = 0000000000000000</action>
    </script>
</cheat>
"attack speed up" : reallocate address.

Code: Select all

<cheat desc="sound test mode">
    <comment>set &quot;skip ram/rom check&quot; then reset the game (F3)</comment>
    <script state="on">
        <action>maincpu.md@13cc =         00000450</action>
        <action>maincpu.mq@0450 = 4eb810ee41f90006</action>
        <action>maincpu.mq@0458 = 0020120010280014</action>
        <action>maincpu.mq@0460 = b20067f60c000001</action>
        <action>maincpu.mq@0468 = 660253100c000002</action>
        <action>maincpu.mq@0470 = 660252100c000008</action>
        <action>maincpu.mq@0478 = 6604041000100c00</action>
        <action>maincpu.mq@0480 = 0004660406100010</action>
        <action>maincpu.mq@0488 = 0c00001066041e10</action>
        <action>maincpu.mq@0490 = 60080c0000206608</action>
        <action>maincpu.mq@0498 = 42074eb900009518</action>
        <action>maincpu.mq@04a0 = 60b8000000000000</action>
        <!--
        0450 | 4eb8 10ee      : jsr    $10ee.w     // erase cross-hatch
        0454 | 41f9 0006 0020 : lea    $60020.l,A0 // sound code address
        045a | 1200           : move.b D0,D1
        045c | 1028 0014      : move.b ($14,A0),D0 // read input
        0460 | b200           : cmp.b  D0,D1
        0462 | 67f6           : beq    $45a
        0464 | 0c00 0001      : cmpi.b #$1,D0
        0468 | 6602           : bne    $46c
        046a | 5310           : subq.b #1,(A0)     // decrease code -01
        046c | 0c00 0002      : cmpi.b #$2,D0
        0470 | 6602           : bne    $474
        0472 | 5210           : addq.b #1,(A0)     // increase code +01
        0474 | 0c00 0008      : cmpi.b #$8,D0
        0478 | 6604           : bne    $47e
        047a | 0410 0010      : subi.b #$10,(A0)   // decrease code -10
        047e | 0c00 0004      : cmpi.b #$4,D0
        0482 | 6604           : bne    $488
        0484 | 0610 0010      : addi.b #$10,(A0)   // increase code +10
        0488 | 0c00 0010      : cmpi.b #$10,D0
        048c | 6604           : bne    $492
        048e | 1e10           : move.b (A0),D7     // play sound
        0490 | 6008           : bra    $49a
        0492 | 0c00 0020      : cmpi.b #$20,D0
        0496 | 6608           : bne    $4a0
        0498 | 4207           : clr.b  D7          // stop sound
        049a | 4eb9 0000 9518 : jsr    $9518.l     // send sound code
        04a0 | 60b8           : bra    $45a
        -->
    </script>
    <script state="run">
        <output format="----- teenage mutant ninja turtles sound test mode -----" line="10" align="center" />
        <output format="left : decrease code -01"                                 line="11" align="center" />
        <output format="right : increase code +01"                                line="12" align="center" />
        <output format="down : decrease code -10"                                 line="13" align="center" />
        <output format="up : increase code +10"                                   line="14" align="center" />
        <output format="button 1 : play sound"                                    line="15" align="center" />
        <output format="button 2 : stop sound"                                    line="16" align="center" />
        <output format="----------------------------"                             line="17" align="center" />
        <output format="&lt;&lt; sound code %2.2X &gt;&gt;"                       line="19" align="center"  >
            <argument>maincpu.pb@60020</argument>
        </output>
    </script>
    <script state="off">
        <action>maincpu.md@13cc =         000205a4</action>
        <action>maincpu.mq@0450 = 0000000000000000</action>
        <action>maincpu.mq@0458 = 0000000000000000</action>
        <action>maincpu.mq@0460 = 0000000000000000</action>
        <action>maincpu.mq@0468 = 0000000000000000</action>
        <action>maincpu.mq@0470 = 0000000000000000</action>
        <action>maincpu.mq@0478 = 0000000000000000</action>
        <action>maincpu.mq@0480 = 0000000000000000</action>
        <action>maincpu.mq@0488 = 0000000000000000</action>
        <action>maincpu.mq@0490 = 0000000000000000</action>
        <action>maincpu.mq@0498 = 0000000000000000</action>
        <action>maincpu.mq@04a0 = 0000000000000000</action>
    </script>
</cheat>
"sound test mode" : add new.

Code: Select all

<cheat desc="skip ram/rom check">
    <script state="on">
        <action>maincpu.mw@1072 = 1074</action> <!-- ram/rom check -->
        <action>maincpu.mw@11a6 = 600a</action> <!-- cross-hatch -->
    </script>
    <script state="off">
        <action>maincpu.mw@1072 = 149a</action>
        <action>maincpu.mw@11a6 = 66fc</action>
    </script>
</cheat>
"skip rom check" : add ram and cross-hatch skip. rename to "skip ram/rom check".
Post Reply