Page 1 of 1

[springer] Springer

Posted: Sat May 21, 2022 12:48 pm
by jman

Code: Select all

<cheat desc="no hit">
    <script state="on">
        <!-- objects -->
        <action>maincpu.mw@2a5c =             5000</action>
        <action>maincpu.mq@5000 = 2043fec83bfe7ddd</action>
        <action>maincpu.mq@5008 = fd10206602cbdd16</action>
        <action>maincpu.mq@5010 = 01502321c5e5037e</action>
        <action>maincpu.mq@5018 = cdc0e1c1b1ed000b</action>
        <action>maincpu.mq@5020 = 400c0b0100c90069</action>
        <action>maincpu.mq@5028 = 0000a09080706050</action>
        <!--
        5000 | dd 7d       : ld   a,ixl
        5002 | fe 3b       : cp   $3B
        5004 | c8          : ret  z
        5005 | fe 43       : cp   $43
        5007 | 20 16       : jr   nz,$501F
        5009 | dd cb 02 66 : bit  4,(ix+$02)
        500d | 20 10       : jr   nz,$501F
        500f | fd 7e 03    : ld   a,(iy+$03)
        5012 | e5          : push hl
        5013 | c5          : push bc
        5014 | 21 23 50    : ld   hl,$5023
        5017 | 01 0b 00    : ld   bc,$000B
        501a | ed b1       : cpir
        501c | c1          : pop  bc
        501d | e1          : pop  hl
        501e | c0          : ret  nz
        501f | cd 69 00    : call $0069
        5022 | c9          : ret
        5023 - 502d        : item/lift table
        -->
        <!-- jump -->
        <action>maincpu.mw@2523 = 2525</action>
        <!-- fall down -->
        <action>maincpu.mw@2701 = 2703</action>
    </script>
    <script state="off">
        <action>maincpu.mw@2a5c =             0069</action>
        <action>maincpu.mq@5000 = 0000000000000000</action>
        <action>maincpu.mq@5008 = 0000000000000000</action>
        <action>maincpu.mq@5010 = 0000000000000000</action>
        <action>maincpu.mq@5018 = 0000000000000000</action>
        <action>maincpu.mq@5020 = 0000000000000000</action>
        <action>maincpu.mq@5028 = 0000000000000000</action>
        <action>maincpu.mw@2523 =             25b7</action>
        <action>maincpu.mw@2701 =             25b7</action>
    </script>
</cheat>

<cheat desc="auto fire">
    <script state="on">
        <action>maincpu.mb@266c = 00</action>
    </script>
    <script state="off">
        <action>maincpu.mb@266c = c8</action>
    </script>
</cheat>

<cheat desc="attack speed up">
    <script state="on">
        <action>maincpu.mb@267a = 02</action>
    </script>
    <script state="off">
        <action>maincpu.mb@267a = 0a</action>
    </script>
</cheat>

<cheat desc="sound test mode">
    <comment>set ram/rom check skip then reset the game (F3)</comment>
    <script state="on">
        <action>maincpu.md@0705 =         50105010</action>
        <action>maincpu.mq@5010 = 3a4fb8003a810121</action>
        <action>maincpu.mq@5018 = 2b1b2877beb1a800</action>
        <action>maincpu.mq@5020 = 2080fe35012040fe</action>
        <action>maincpu.mq@5028 = 187e032010fe3401</action>
        <action>maincpu.mq@5030 = cdf23e052001fe06</action>
        <action>maincpu.mq@5038 = 3e800432013e0188</action>
        <action>maincpu.mq@5040 = 00079cc3801e32ff</action>
        <!--
        5010 | 21 01 81 : ld   hl,$8101  // sound code address
        5013 | 3a 00 b8 : ld   a,($B800) // read button input
        5016 | 4f       : ld   c,a
        5017 | 3a 00 a8 : ld   a,($A800) // read stick input
        501a | b1       : or   c
        501b | be       : cp   (hl)
        501c | 77       : ld   (hl),a
        501d | 28 1b    : jr   z,$503A
        501f | 2b       : dec  hl
        5020 | fe 40    : cp   $40
        5022 | 20 01    : jr   nz,$5025
        5024 | 35       : dec  (hl)      // decrease code
        5025 | fe 80    : cp   $80
        5027 | 20 01    : jr   nz,$502A
        5029 | 34       : inc  (hl)      // increase code
        502a | fe 10    : cp   $10
        502c | 20 03    : jr   nz,$5031
        502e | 7e       : ld   a,(hl)    // play sound
        502f | 18 06    : jr   $5037
        5031 | fe 01    : cp   $01
        5033 | 20 05    : jr   nz,$503A
        5035 | 3e f2    : ld   a,$F2     // stop sound
        5037 | cd 88 01 : call $0188
        503a | 3e 01    : ld   a,$01
        503c | 32 04 80 : ld   ($8004),a // enable sound
        503f | 3e ff    : ld   a,$FF
        5041 | 32 1e 80 : ld   ($801E),a // prevent from resetting the game
        5044 | c3 9c 07 : jp   $079C
        -->
    </script>
    <script state="run">
        <output format="----- springer sound test mode -----" line="10" align="center" />
        <output format="left : decrease code"                 line="11" align="center" />
        <output format="right : increase code"                line="12" align="center" />
        <output format="button 1 : play sound"                line="13" align="center" />
        <output format="up : stop sound"                      line="14" align="center" />
        <output format="----------------------------"         line="15" align="center" />
        <output format="&lt;&lt; sound code %2.2X &gt;&gt;"   line="17" align="center">
            <argument>maincpu.pb@8100</argument>
        </output>
    </script>
    <script state="off">
        <action>maincpu.md@0705 =         070909ca</action>
        <action>maincpu.mq@5010 = 0000000000000000</action>
        <action>maincpu.mq@5018 = 0000000000000000</action>
        <action>maincpu.mq@5020 = 0000000000000000</action>
        <action>maincpu.mq@5028 = 0000000000000000</action>
        <action>maincpu.mq@5030 = 0000000000000000</action>
        <action>maincpu.mq@5038 = 0000000000000000</action>
        <action>maincpu.mq@5040 = 0000000000000000</action>
    </script>
</cheat>

<cheat desc="skip ram/rom check">
    <script state="on">
        <action>maincpu.mw@0005 = 05dc</action>
    </script>
    <script state="off">
        <action>maincpu.mw@0005 = 4a25</action>
    </script>
</cheat>

[springer] Springer

Posted: Fri Dec 22, 2023 10:55 am
by jman

Code: Select all

<!-- Springer -->
<mamecheat version="1">

    <cheat desc="no hit">
        <script state="on">
            <!-- objects -->
            <action>maincpu.mw@2A5C = 5000            </action>
            <action>maincpu.mq@5000 = 2043FEC83BFE7DDD</action>
            <action>maincpu.mq@5008 = FD10206602CBDD16</action>
            <action>maincpu.mq@5010 = 01502321C5E5037E</action>
            <action>maincpu.mq@5018 = CDC0E1C1B1ED000B</action>
            <action>maincpu.mq@5020 = 400C0B0100C90069</action>
            <action>maincpu.mq@5028 = 0000A09080706050</action>
            <!--
            5000 | DD 7D       : ld   a,ixl
            5002 | FE 3B       : cp   $3B
            5004 | C8          : ret  z
            5005 | FE 43       : cp   $43
            5007 | 20 16       : jr   nz,$501F
            5009 | DD CB 02 66 : bit  4,(ix+$02)
            500D | 20 10       : jr   nz,$501F
            500F | FD 7E 03    : ld   a,(iy+$03)
            5012 | E5          : push hl
            5013 | C5          : push bc
            5014 | 21 23 50    : ld   hl,$5023
            5017 | 01 0B 00    : ld   bc,$000B
            501A | ED B1       : cpir
            501C | C1          : pop  bc
            501D | E1          : pop  hl
            501E | C0          : ret  nz
            501F | CD 69 00    : call $0069
            5022 | C9          : ret
            5023 - 502D        : item/lift table
            -->
            <!-- jump -->
            <action>maincpu.mw@2523 = 2525</action>
            <!-- fall down -->
            <action>maincpu.mw@2701 = 2703</action>
        </script>
        <script state="off">
            <action>maincpu.mw@2A5C = 0069            </action>
            <action>maincpu.mq@5000 = 0000000000000000</action>
            <action>maincpu.mq@5008 = 0000000000000000</action>
            <action>maincpu.mq@5010 = 0000000000000000</action>
            <action>maincpu.mq@5018 = 0000000000000000</action>
            <action>maincpu.mq@5020 = 0000000000000000</action>
            <action>maincpu.mq@5028 = 0000000000000000</action>
            <action>maincpu.mw@2523 = 25B7            </action>
            <action>maincpu.mw@2701 = 25B7            </action>
        </script>
    </cheat>

    <cheat desc="auto fire">
        <script state="on">
            <action>maincpu.mb@266C = 00</action>
        </script>
        <script state="off">
            <action>maincpu.mb@266C = C8</action>
        </script>
    </cheat>

    <cheat desc="attack speed up">
        <script state="on">
            <action>maincpu.mb@267A = 02</action>
        </script>
        <script state="off">
            <action>maincpu.mb@267A = 0A</action>
        </script>
    </cheat>

    <cheat desc="game speed up">
        <script state="on">
            <action>maincpu.mb@0676 = 00</action>
        </script>
        <script state="off">
            <action>maincpu.mb@0676 = 2C</action>
        </script>
    </cheat>

    <cheat desc="timer speed">
        <parameter>
            <item value="0xff">01 (slow)</item>
            <item value="0x7f">02       </item>
            <item value="0x3f">03       </item>
            <item value="0x1f">04       </item>
            <item value="0x01">05 (fast)</item>
        </parameter>
        <script state="on">
            <action>maincpu.mb@328A = 00</action>
        </script>
        <script state="change">
            <action>maincpu.mb@320F = param</action>
        </script>
        <script state="off">
            <action>maincpu.mb@328A = C8</action>
            <action>maincpu.mb@320F = 0F</action>
        </script>
    </cheat>

    <cheat desc="sound test mode">
        <comment>set &quot;skip ram/rom check&quot; then reset the game (F3)</comment>
        <script state="on">
            <action>maincpu.mw@00FB = 00FD            </action> <!-- enable sound in vblank -->
            <action>maincpu.mb@052A = C9              </action> <!-- disable reset -->
            <action>maincpu.md@0705 = 50105010        </action>
            <action>maincpu.mq@5010 = 14E6B8003A810121</action>
            <action>maincpu.mq@5018 = 2877BEB0A8003A47</action>
            <action>maincpu.mq@5020 = FE35012040FE2B2D</action>
            <action>maincpu.mq@5028 = 042002FE34012080</action>
            <action>maincpu.mq@5030 = 062001FE0618F03E</action>
            <action>maincpu.mq@5038 = 10FE10187786103E</action>
            <action>maincpu.mq@5040 = 2004FE06187E0320</action>
            <action>maincpu.mq@5048 = 9CC30188CDF23E05</action>
            <action>maincpu.mq@5050 = 0000000000000007</action>
            <!--
            5010 | 21 01 81 : ld   hl,$8101  // temporary input address
            5013 | 3A 00 B8 : ld   a,($B800) // read buttons
            5016 | E6 14    : and  $14
            5018 | 47       : ld   b,a
            5019 | 3A 00 A8 : ld   a,($A800) // read other inputs
            501C | B0       : or   b
            501D | BE       : cp   (hl)
            501E | 77       : ld   (hl),a
            501F | 28 2D    : jr   z,$504E
            5021 | 2B       : dec  hl        // sound code address ($8100)
            5022 | FE 40    : cp   $40
            5024 | 20 01    : jr   nz,$5027
            5026 | 35       : dec  (hl)      // decrease code -01
            5027 | FE 80    : cp   $80
            5029 | 20 01    : jr   nz,$502C
            502B | 34       : inc  (hl)      // increase code +01
            502C | FE 02    : cp   $02
            502E | 20 04    : jr   nz,$5034
            5030 | 3E F0    : ld   a,$F0     // decrease code -10
            5032 | 18 06    : jr   $503A
            5034 | FE 01    : cp   $01
            5036 | 20 06    : jr   nz,$503E
            5038 | 3E 10    : ld   a,$10     // increase code +10
            503A | 86       : add  a,(hl)
            503B | 77       : ld   (hl),a
            503C | 18 10    : jr   $504E
            503E | FE 10    : cp   $10
            5040 | 20 03    : jr   nz,$5045
            5042 | 7E       : ld   a,(hl)    // play sound
            5043 | 18 06    : jr   $504B
            5045 | FE 04    : cp   $04
            5047 | 20 05    : jr   nz,$504E
            5049 | 3E F2    : ld   a,$F2     // stop sound
            504B | CD 88 01 : call $0188     // send sound code
            504E | C3 9C 07 : jp   $079C
            -->
        </script>
        <script state="run">
            <output format="----- springer 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="P1 start : 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@8100</argument>
            </output>
        </script>
        <script state="off">
            <action>maincpu.mw@00FB = 0179            </action>
            <action>maincpu.mb@052A = 21              </action>
            <action>maincpu.md@0705 = 070909CA        </action>
            <action>maincpu.mq@5010 = 0000000000000000</action>
            <action>maincpu.mq@5018 = 0000000000000000</action>
            <action>maincpu.mq@5020 = 0000000000000000</action>
            <action>maincpu.mq@5028 = 0000000000000000</action>
            <action>maincpu.mq@5030 = 0000000000000000</action>
            <action>maincpu.mq@5038 = 0000000000000000</action>
            <action>maincpu.mq@5040 = 0000000000000000</action>
            <action>maincpu.mq@5048 = 0000000000000000</action>
            <action>maincpu.mq@5050 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="skip ram/rom check">
        <script state="on">
            <action>maincpu.mw@0005 = 05dc</action>
        </script>
        <script state="off">
            <action>maincpu.mw@0005 = 4a25</action>
        </script>
    </cheat>

</mamecheat>
  • "timer speed", "game speed up" : Added new.
  • "sound test mode" : Rewritten routine. Added up/down key to select code ±10. Changed sound stop button from up to start.