Page 1 of 1

[kingball]+ King & Balloon

Posted: Sat Sep 23, 2023 12:09 pm
by jman
kingball.xml

Code: Select all

<!-- King & Balloon (US) -->
<mamecheat version="1">

    <cheat desc="no hit">
        <script state="on">
            <action>maincpu.mb@11ec = c9</action>
            <action>maincpu.mb@1204 = c9</action>
        </script>
        <script state="off">
            <action>maincpu.mb@11ec = d0</action>
            <action>maincpu.mb@1204 = d8</action>
        </script>
    </cheat>

    <cheat desc="no hit - king">
        <script state="on">
            <action>maincpu.mb@0cdb = c9</action>
        </script>
        <script state="off">
            <action>maincpu.mb@0cdb = d0</action>
        </script>
    </cheat>

    <cheat desc="auto fire">
        <script state="on">
            <action>maincpu.mw@059e = 00fe</action>
        </script>
        <script state="off">
            <action>maincpu.mw@059e = 0cd6</action>
        </script>
    </cheat>

    <cheat desc="player speed">
        <parameter min="0x01" max="0x05" step="0x01" />
        <script state="on">
            <action>maincpu.mw@013d =             2800</action>
            <action>maincpu.mq@2800 = 10c10472cdc50506</action>
            <action>maincpu.mq@2808 = 000000000000c9f9</action>
            <!--
            2800 | 06 xx    : ld   b,$xx
            2802 | c5       : push bc
            2803 | cd 72 04 : call $0472
            2806 | c1       : pop  bc
            2807 | 10 f9    : djnz $2802
            2809 | c9       : ret
            -->
        </script>
        <script state="change">
            <action>maincpu.mb@2801 = param</action>
        </script>
        <script state="off">
            <action>maincpu.mw@013d =             0472</action>
            <action>maincpu.mq@2800 = 0000000000000000</action>
            <action>maincpu.mq@2808 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="bullet speed">
        <parameter>
            <item value="0x01">01 (slow)</item>
            <item value="0x05">02       </item>
            <item value="0x08">03       </item>
            <item value="0x0c">04       </item>
            <item value="0x10">05 (fast)</item>
        </parameter>
        <script state="on">
            <action>maincpu.md@05b5 =         3a2810cd</action>
            <action>maincpu.mq@2810 = 0000c9f026292929</action>
            <!--
            2810 | 29    : add hl,hl
            2811 | 29    : add hl,hl
            2812 | 29    : add hl,hl
            2813 | 26 xx : ld  h,$xx
            2815 | C9    : ret
            -->
        </script>
        <script state="change">
            <action>maincpu.mb@2814 = -param</action>
        </script>
        <script state="off">
            <action>maincpu.md@05b5 =         3a292929</action>
            <action>maincpu.mq@2810 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="no wait next level">
        <script state="on">
            <action>maincpu.mb@18c5 = 08</action>
        </script>
        <script state="off">
            <action>maincpu.mb@18c5 = b4</action>
        </script>
    </cheat>

    <cheat desc="skip ram/rom check">
        <script state="on">
            <action>maincpu.mw@0005 = 24e5</action>
        </script>
        <script state="off">
            <action>maincpu.mw@0005 = 1322</action>
        </script>
    </cheat>

</mamecheat>
kingballj.xml

Code: Select all

<!-- King & Balloon (Japan) -->
<mamecheat version="1">

    <cheat desc="no hit">
        <script state="on">
            <action>maincpu.mb@11ec = c9</action>
            <action>maincpu.mb@1204 = c9</action>
        </script>
        <script state="off">
            <action>maincpu.mb@11ec = d0</action>
            <action>maincpu.mb@1204 = d8</action>
        </script>
    </cheat>

    <cheat desc="no hit - king">
        <script state="on">
            <action>maincpu.mb@0cdb = c9</action>
        </script>
        <script state="off">
            <action>maincpu.mb@0cdb = d0</action>
        </script>
    </cheat>

    <cheat desc="auto fire">
        <script state="on">
            <action>maincpu.mw@059e = 00fe</action>
        </script>
        <script state="off">
            <action>maincpu.mw@059e = 0cd6</action>
        </script>
    </cheat>

    <cheat desc="player speed">
        <parameter min="0x01" max="0x05" step="0x01" />
        <script state="on">
            <action>maincpu.mw@013d =             2800</action>
            <action>maincpu.mq@2800 = 10c10472cdc50506</action>
            <action>maincpu.mq@2808 = 000000000000c9f9</action>
            <!--
            2800 | 06 xx    : ld   b,$xx
            2802 | c5       : push bc
            2803 | cd 72 04 : call $0472
            2806 | c1       : pop  bc
            2807 | 10 f9    : djnz $2802
            2809 | c9       : ret
            -->
        </script>
        <script state="change">
            <action>maincpu.mb@2801 = param</action>
        </script>
        <script state="off">
            <action>maincpu.mw@013d =             0472</action>
            <action>maincpu.mq@2800 = 0000000000000000</action>
            <action>maincpu.mq@2808 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="bullet speed">
        <parameter>
            <item value="0x01">01 (slow)</item>
            <item value="0x05">02       </item>
            <item value="0x08">03       </item>
            <item value="0x0c">04       </item>
            <item value="0x10">05 (fast)</item>
        </parameter>
        <script state="on">
            <action>maincpu.md@05b5 =         3a2810cd</action>
            <action>maincpu.mq@2810 = 0000c9f026292929</action>
            <!--
            2810 | 29    : add hl,hl
            2811 | 29    : add hl,hl
            2812 | 29    : add hl,hl
            2813 | 26 xx : ld  h,$xx
            2815 | c9    : ret
            -->
        </script>
        <script state="change">
            <action>maincpu.mb@2814 = -param</action>
        </script>
        <script state="off">
            <action>maincpu.md@05b5 =         3a292929</action>
            <action>maincpu.mq@2810 = 0000000000000000</action>
        </script>
    </cheat>

    <cheat desc="no wait next level">
        <script state="on">
            <action>maincpu.mb@18c5 = 08</action>
        </script>
        <script state="off">
            <action>maincpu.mb@18c5 = b4</action>
        </script>
    </cheat>

    <cheat desc="skip ram/rom check">
        <script state="on">
            <action>maincpu.mw@0005 = 24e5</action>
        </script>
        <script state="off">
            <action>maincpu.mw@0005 = 1322</action>
        </script>
    </cheat>

</mamecheat>