[ad2083] A. D. 2083

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: 1315
Joined: Tue Dec 01, 2020 1:24 pm
Been thanked: 9 times

[ad2083] A. D. 2083

Post by jman »

ad2083.xml

Code: Select all

<!-- A. D. 2083 -->
<mamecheat version="1">

    <cheat desc="no hit">
        <script state="on">
            <action>maincpu.mb@CE07 = C9</action> <!-- enemy -->
            <action>maincpu.mb@CE6C = C9</action> <!-- rocket -->
            <action>maincpu.mb@D796 = C9</action> <!-- radiation tower -->
            <action>maincpu.mb@D7DC = C9</action> <!-- bullet (radiation tower) -->
        </script>
        <script state="off">
            <action>maincpu.mb@CE07 = D0</action>
            <action>maincpu.mb@CE6C = D0</action>
            <action>maincpu.mb@D796 = D8</action>
            <action>maincpu.mb@D7DC = D0</action>
        </script>
    </cheat>

    <cheat desc="rapid fire">
        <script state="on">
            <action>maincpu.mb@A6CF = 00</action>
        </script>
        <script state="off">
            <action>maincpu.mb@A6CF = 13</action>
        </script>
    </cheat>

    <cheat desc="energy speed">
        <parameter>
            <item value="0x3200FF3E">01 (slow)</item>
            <item value="0x3200803E">02       </item>
            <item value="0x3200403E">03       </item>
            <item value="0x3200203E">04       </item>
            <item value="0x3200013E">05 (fast)</item>
        </parameter>
        <script state="change">
            <action>maincpu.md@34D4 = param</action>
        </script>
        <script state="off">
            <action>maincpu.md@34D4 = 32E707E6</action>
        </script>
    </cheat>

    <cheat desc="rocket speed">
        <parameter>
            <item value="0x01">01 (slow)</item>
            <item value="0x02">02       </item>
            <item value="0x04">03       </item>
            <item value="0x06">04       </item>
            <item value="0x08">05 (fast)</item>
        </parameter>
        <script state="on">
            <action>maincpu.mw@B248 = 4780</action>
        </script>
        <script state="run">
            <action>maincpu.pq@4780 = 003E02207E1ACBDD</action>
            <action>maincpu.pq@4788 = 0000000000B27EC3</action>
            <action>maincpu.pb@4787 = param           </action>
            <!--
            4780 | DD CB 1A 7E : bit  7,(ix+$1a)
            4784 | 20 02       : jr   nz,$4788
            4786 | 3E xx       : ld   a,$xx
            4788 | C3 7E B2    : jp   $B27E
            -->
        </script>
        <script state="off">
            <action>maincpu.mw@B248 = B27E            </action>
            <action>maincpu.pq@4780 = 0000000000000000</action>
            <action>maincpu.pq@4788 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="sound test mode">
        <!-- you can't stop samples (0x20 - 0x29) by sound stop button -->
        <!-- no sound response after you play code 0x3E or later -->
        <comment>reset the game (F3) to enter sound test mode</comment>
        <script state="on">
            <action>maincpu.mq@18DB = 77BE80003A400121</action>
            <action>maincpu.mq@18E3 = FE35012020FE2BC8</action>
            <action>maincpu.mq@18EB = 042004FE34012010</action>
            <action>maincpu.mq@18F3 = 052001FE0618F03E</action>
            <action>maincpu.mq@18FB = 2008FEC97786103E</action>
            <action>maincpu.mq@1903 = AFC002FE04187E03</action>
            <action>maincpu.mq@190B = FFFFFFFFC9DA6CCD</action>
            <!--
            18DB | 21 01 40 : ld   hl,$4001  // temporary input address
            18DE | 3A 00 80 : ld   a,($8000) // read input
            18E1 | BE       : cp   (hl)
            18E2 | 77       : ld   (hl),a
            18E3 | C8       : ret  z
            18E4 | 2B       : dec  hl        // sound code address ($4000)
            18E5 | FE 20    : cp   $20
            18E7 | 20 01    : jr   nz,$18EA
            18E9 | 35       : dec  (hl)      // decrease code -01
            18EA | FE 10    : cp   $10
            18EC | 20 01    : jr   nz,$18EF
            18EE | 34       : inc  (hl)      // increase code +01
            18EF | FE 04    : cp   $04
            18F1 | 20 04    : jr   nz,$18F7
            18F3 | 3E F0    : ld   a,$F0     // decrease code -10
            18F5 | 18 06    : jr   $18FD
            18F7 | FE 01    : cp   $01
            18F9 | 20 05    : jr   nz,$1900
            18FB | 3E 10    : ld   a,$10     // increase code +10
            18FD | 86       : add  a,(hl)
            18FE | 77       : ld   (hl),a
            18FF | C9       : ret
            1900 | FE 08    : cp   $08
            1902 | 20 03    : jr   nz,$1907
            1904 | 7E       : ld   a,(hl)    // play sound
            1905 | 18 04    : jr   $190B
            1907 | FE 02    : cp   $02
            1909 | C0       : ret  nz
            190A | AF       : xor  a         // stop sound
            190B | CD 6C DA : call $DA6C     // send sound code
            190E | C9       : ret
            -->
        </script>
        <script state="run">
            <output format="----- 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 %02X &gt;&gt;" line="19" align="center"  >
                <argument>maincpu.pb@4000</argument>
            </output>
        </script>
        <script state="off">
            <action>maincpu.mq@18DB = 3240B232400632AF</action>
            <action>maincpu.mq@18E3 = 202140AF323C4702</action>
            <action>maincpu.mq@18EB = 1023230036200640</action>
            <action>maincpu.mq@18F3 = 06406111406021FA</action>
            <action>maincpu.mq@18FB = 21B0ED00363F0E00</action>
            <action>maincpu.mq@1903 = 001001413011BE20</action>
            <action>maincpu.mq@190B = 32411E32003EB0ED</action>
        </script>
    </cheat>

    <cheat desc="quick boot">
        <script state="on">
            <action>maincpu.mw@CF07 = 1A18</action>
        </script>
        <script state="off">
            <action>maincpu.mw@CF07 = DF16</action>
        </script>
    </cheat>

</mamecheat>
"sound test mode" : You can't stop samples (0x20 - 0x29) by sound stop button. No sound response after you play code 0x3E or later.
jman

my wip cheat database back-up (06/01/2025 ver.)
https://u3.getuploader.com/...../download/58
downloadpass : jman2020
Post Reply