[lresort] Last Resort

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

[lresort] Last Resort

Post by jman »

Code: Select all

<cheat desc="no hit">
    <script state="on">
        <action>maincpu.rb@14fd = 02</action> <!-- background -->
        <action>maincpu.rb@a603 = a0</action> <!-- P1 objects -->
        <action>maincpu.rb@a639 = 6a</action> <!-- P2 objects -->
    </script>
    <script state="off">
        <action>maincpu.rb@14fd = 0a</action>
        <action>maincpu.rb@a603 = 44</action>
        <action>maincpu.rb@a639 = 0e</action>
    </script>
</cheat>

<cheat desc="auto fire">
    <script state="on">
        <action>maincpu.rb@16ef = 34</action> <!-- P1 main shot -->
        <action>maincpu.rb@16ff = 35</action> <!-- P2 main shot -->
        <action>maincpu.rb@982b = 34</action> <!-- P1 sub unit -->
        <action>maincpu.rb@983d = 35</action> <!-- P2 sub unit -->
    </script>
    <script state="off">
        <action>maincpu.rb@16ef = 36</action>
        <action>maincpu.rb@16ff = 37</action>
        <action>maincpu.rb@982b = 36</action>
        <action>maincpu.rb@983d = 37</action>
    </script>
</cheat>

<cheat desc="player speed">
    <parameter>
        <item value="0x00008000">01 (slow)</item>
        <item value="0x00020000">02       </item>
        <item value="0x00038000">03       </item>
        <item value="0x00050000">04       </item>
        <item value="0x00068000">05 (fast)</item>
    </parameter>
    <script state="on">
        <action>maincpu.rq@01302 = 4eb90001d9001940</action>
        <action>maincpu.rq@1d900 = 243c000000002602</action>
        <action>maincpu.rq@1d908 = 4e75ffffffffffff</action>
        <!--
        1d900 | 243c xxxx xxxx : move.l #$xxxx,D2
        1d906 | 2602           : move.l D2,D3
        1d908 | 4e75           : rts
        -->
    </script>
    <script state="change">
        <action>maincpu.rd@1d902 = param</action>
    </script>
    <script state="off">
        <action>maincpu.rq@01302 = 2430200026021940</action>
        <action>maincpu.rq@1d900 = ffffffffffffffff</action>
        <action>maincpu.rq@1d908 = ffffffffffffffff</action>
    </script>
</cheat>

<cheat desc="bullet speed - main shot">
    <parameter>
        <item value="0x00060000">01 (slow)</item>
        <item value="0x000c0000">02       </item>
        <item value="0x00120000">03       </item>
        <item value="0x00180000">04       </item>
        <item value="0x001e0000">05 (fast)</item>
    </parameter>
    <script state="change">
        <action>maincpu.rd@196e = param</action>
    </script>
    <script state="off">
        <action>maincpu.rd@196e = 000c0000</action>
    </script>
</cheat>
I omit "skip ram/rom check" because it has already posted here.
jman
Posts: 843
Joined: Tue Dec 01, 2020 1:24 pm

[lresort] Last Resort (update)

Post by jman »

Code: Select all

<cheat desc="sound test mode">
    <!-- don't play code 0x01, 0x03, and 0x10 because of no sound response -->
    <!-- valid bank number seems to be 0x00 and 0x08 -->
    <comment>reset the game (F3) to enter sound test mode</comment>
    <script state="on">
        <action>maincpu.rd@08478 =         0000bf1e</action> <!-- enable sound code check in interrupt -->
        <action>maincpu.rd@02574 =         0001d910</action>
        <action>maincpu.rq@1d910 = 204d43e80001247c</action>
        <action>maincpu.rq@1d918 = 0000bede14011239</action>
        <action>maincpu.rq@1d920 = 00300000b40167f4</action>
        <action>maincpu.rq@1d928 = 0c0100fb66025310</action>
        <action>maincpu.rq@1d930 = 0c0100f766025210</action>
        <action>maincpu.rq@1d938 = 0c0100fd66040410</action>
        <action>maincpu.rq@1d940 = 00100c0100fe6604</action>
        <action>maincpu.rq@1d948 = 061000100c0100bb</action>
        <action>maincpu.rq@1d950 = 660253110c0100b7</action>
        <action>maincpu.rq@1d958 = 660252110211000f</action>
        <action>maincpu.rq@1d960 = 0c0100ef66104240</action>
        <action>maincpu.rq@1d968 = 1011670606000010</action>
        <action>maincpu.rq@1d970 = e14880104e920c01</action>
        <action>maincpu.rq@1d978 = 00df6612303c0001</action>
        <action>maincpu.rq@1d980 = 4e92303c00034e92</action>
        <action>maincpu.rq@1d988 = 303c00074e92608c</action>
        <!--
        1d910 | 204d           : movea.l A5,A0        // $108000 : sound code address
        1d912 | 43e8 0001      : lea     ($1,A0),A1   // $108001 : bank number address
        1d916 | 247c 0000 bede : movea.l #$bede,A2
        1d91c | 1401           : move.b  D1,D2
        1d91e | 1239 0030 0000 : move.b  $300000.l,D1 // read input
        1d924 | b401           : cmp.b   D1,D2
        1d926 | 67f4           : beq     $1d91c
        1d928 | 0c01 00fb      : cmpi.b  #-$5,D1
        1d92c | 6602           : bne     $1d930
        1d92e | 5310           : subq.b  #1,(A0)      // decrease code -01
        1d930 | 0c01 00f7      : cmpi.b  #-$9,D1
        1d934 | 6602           : bne     $1d938
        1d936 | 5210           : addq.b  #1,(A0)      // increase code +01
        1d938 | 0c01 00fd      : cmpi.b  #-$3,D1
        1d93c | 6604           : bne     $1d942
        1d93e | 0410 0010      : subi.b  #$10,(A0)    // decrease code -10
        1d942 | 0c01 00fe      : cmpi.b  #-$2,D1
        1d946 | 6604           : bne     $1d94c
        1d948 | 0610 0010      : addi.b  #$10,(A0)    // increase code +10
        1d94c | 0c01 00bb      : cmpi.b  #-$45,D1
        1d950 | 6602           : bne     $1d954
        1d952 | 5311           : subq.b  #1,(A1)      // decrease bank -01
        1d954 | 0c01 00b7      : cmpi.b  #-$49,D1
        1d958 | 6602           : bne     $1d95c
        1d95a | 5211           : addq.b  #1,(A1)      // increase bank +01
        1d95c | 0211 000f      : andi.b  #$f,(A1)
        1d960 | 0c01 00ef      : cmpi.b  #-$11,D1
        1d964 | 6610           : bne     $1d976
        1d966 | 4240           : clr.w   D0           // play sound
        1d968 | 1011           : move.b  (A1),D0
        1d96a | 6706           : beq     $1d972
        1d96c | 0600 0010      : addi.b  #$10,D0
        1d970 | e148           : lsl.w   #8,D0
        1d972 | 8010           : or.b    (A0),D0
        1d974 | 4e92           : jsr     (A2)
        1d976 | 0c01 00df      : cmpi.b  #-$21,D1
        1d97a | 6612           : bne     $1d98e
        1d97c | 303c 0001      : move.w  #$1,D0       // stop sound
        1d980 | 4e92           : jsr     (A2)
        1d982 | 303c 0003      : move.w  #$3,D0
        1d986 | 4e92           : jsr     (A2)
        1d988 | 303c 0007      : move.w  #$7,D0
        1d98c | 4e92           : jsr     (A2)
        1d98e | 608c           : bra     $1d91c
        -->
    </script>
    <script state="run">
        <output format="----- last resort 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 3 + left : decrease bank -01"     line="15" align="center" />
        <output format="button 3 + right : increase bank +01"    line="16" align="center" />
        <output format="button 1 : play sound"                   line="17" align="center" />
        <output format="button 2 : stop sound"                   line="18" align="center" />
        <output format="----------------------------"            line="19" align="center" />
        <output format="&lt;&lt; bank %2.2X &gt;&gt;"            line="21" align="center"  >
            <argument>maincpu.pb@108001</argument>
        </output>
        <output format="&lt;&lt; sound code %2.2X &gt;&gt;"      line="23" align="center"  >
            <argument>maincpu.pb@108000</argument>
        </output>
    </script>
    <script state="off">
        <action>maincpu.rd@08478 =         00c0044a</action>
        <action>maincpu.rd@02574 =         0000bf1e</action>
        <action>maincpu.rq@1d910 = ffffffffffffffff</action>
        <action>maincpu.rq@1d918 = ffffffffffffffff</action>
        <action>maincpu.rq@1d920 = ffffffffffffffff</action>
        <action>maincpu.rq@1d928 = ffffffffffffffff</action>
        <action>maincpu.rq@1d930 = ffffffffffffffff</action>
        <action>maincpu.rq@1d938 = ffffffffffffffff</action>
        <action>maincpu.rq@1d940 = ffffffffffffffff</action>
        <action>maincpu.rq@1d948 = ffffffffffffffff</action>
        <action>maincpu.rq@1d950 = ffffffffffffffff</action>
        <action>maincpu.rq@1d958 = ffffffffffffffff</action>
        <action>maincpu.rq@1d960 = ffffffffffffffff</action>
        <action>maincpu.rq@1d968 = ffffffffffffffff</action>
        <action>maincpu.rq@1d970 = ffffffffffffffff</action>
        <action>maincpu.rq@1d978 = ffffffffffffffff</action>
        <action>maincpu.rq@1d980 = ffffffffffffffff</action>
        <action>maincpu.rq@1d988 = ffffffffffffffff</action>
    </script>
</cheat>
"sound test mode" : add new.
Post Reply