[rshark] R-Shark

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

[rshark] R-Shark

Post by jman »

Code: Select all

<cheat desc="no hit">
    <script state="on">
        <action>maincpu.mb@c485 = 02</action> <!-- enemy -->
        <action>maincpu.mb@c5f9 = 02</action> <!-- bullet -->
    </script>
    <script state="off">
        <action>maincpu.mb@c485 = 08</action>
        <action>maincpu.mb@c5f9 = 14</action>
    </script>
</cheat>

<cheat desc="auto fire">
    <script state="on">
        <action>maincpu.mw@9198 = 0002</action> <!-- "1" : missile -->
        <action>maincpu.mw@93e4 = 4e71</action> <!-- "2" -->
        <action>maincpu.mw@95b4 = 0002</action> <!-- "1" : main shot -->
        <action>maincpu.mw@9bba = 0002</action> <!-- "3" -->
    </script>
    <script state="off">
        <action>maincpu.mw@9198 = 21e8</action>
        <action>maincpu.mw@93e4 = 67d8</action>
        <action>maincpu.mw@95b4 = 1dcc</action>
        <action>maincpu.mw@9bba = 17c6</action>
    </script>
</cheat>

<cheat desc="player speed">
    <parameter min="0x01" max="0x08" step="0x01" />
    <script state="on">
        <action>maincpu.md@bc00 = 7a004e71</action> <!-- right -->
        <action>maincpu.md@bc48 = 7a004e71</action> <!-- left -->
        <action>maincpu.md@bc92 = 7a004e71</action> <!-- down -->
        <action>maincpu.md@bcb4 = 7a004e71</action> <!-- up -->
    </script>
    <script state="change">
        <action>maincpu.mb@bc01 = param</action>
        <action>maincpu.mb@bc49 = param</action>
        <action>maincpu.mb@bc93 = param</action>
        <action>maincpu.mb@bcb5 = param</action>
    </script>
    <script state="off">
        <action>maincpu.md@bc00 = 1a2c0009</action>
        <action>maincpu.md@bc48 = 1a2c0009</action>
        <action>maincpu.md@bc92 = 1a2c0008</action>
        <action>maincpu.md@bcb4 = 1a2c0008</action>
    </script>
</cheat>

<cheat desc="bullet speed - type 1">
    <parameter>
        <item value="0x08">01 (slow)</item>
        <item value="0x10">02       </item>
        <item value="0x18">03       </item>
        <item value="0x20">04       </item>
        <item value="0x28">05 (fast)</item>
    </parameter>
    <script state="change">
        <action>maincpu.mb@a2d5 = param</action>
    </script>
    <script state="off">
        <action>maincpu.mb@a2d5 = 10</action>
    </script>
</cheat>

<cheat desc="bullet speed - type 2">
    <parameter>
        <item value="0x08">01 (slow)</item>
        <item value="0x10">02       </item>
        <item value="0x18">03       </item>
        <item value="0x20">04       </item>
        <item value="0x28">05 (fast)</item>
    </parameter>
    <script state="change">
        <action>maincpu.mb@a225 = param</action>
    </script>
    <script state="off">
        <action>maincpu.mb@a225 = 10</action>
    </script>
</cheat>

<cheat desc="bullet speed - type 3">
    <parameter>
        <item value="0x04">01 (slow)</item>
        <item value="0x08">02       </item>
        <item value="0x0c">03       </item>
        <item value="0x10">04       </item>
        <item value="0x14">05 (fast)</item>
    </parameter>
    <script state="on">
        <action>maincpu.md@a36a = 103c0000</action>
        <action>maincpu.md@a37a = 103c0000</action>
    </script>
    <script state="change">
        <action>maincpu.mb@a36d = param</action>
        <action>maincpu.mb@a37d = param</action>
    </script>
    <script state="off">
        <action>maincpu.md@a36a = 102a0008</action>
        <action>maincpu.md@a37a = 102a0008</action>
    </script>
</cheat>

<cheat desc="sound test mode">
    <comment>reset the game (F3) to enter sound test mode</comment>
    <script state="on">
        <action>maincpu.mq@0082e = 4ef90003b9007208</action>
        <action>maincpu.mq@3b900 = 41f9003401001401</action>
        <action>maincpu.mq@3b908 = 1239003c0005b401</action>
        <action>maincpu.mq@3b910 = 67f40c0100fd6602</action>
        <action>maincpu.mq@3b918 = 53100c0100fe6602</action>
        <action>maincpu.mq@3b920 = 52100c0100fb6604</action>
        <action>maincpu.mq@3b928 = 041000100c0100f7</action>
        <action>maincpu.mq@3b930 = 6604061000100c01</action>
        <action>maincpu.mq@3b938 = 00ef660410106008</action>
        <action>maincpu.mq@3b940 = 0c0100df66084200</action>
        <action>maincpu.mq@3b948 = 13c0003c001360b6</action>
        <!--
        3b900 | 41f9 0034 0100 : lea    $340100.l,A0 // sound code address
        3b906 | 1401           : move.b D1,D2
        3b908 | 1239 003c 0005 : move.b $3c0005.l,D1 // read input
        3b90e | b401           : cmp.b  D1,D2
        3b910 | 67f4           : beq    $3b906
        3b912 | 0c01 00fd      : cmpi.b #-$3,D1
        3b916 | 6602           : bne    $3b91a
        3b918 | 5310           : subq.b #1,(A0)      // decrease code -01
        3b91a | 0c01 00fe      : cmpi.b #-$2,D1
        3b91e | 6602           : bne    $3b922
        3b920 | 5210           : addq.b #1,(A0)      // increase code +01
        3b922 | 0c01 00fb      : cmpi.b #-$5,D1
        3b926 | 6604           : bne    $3b92c
        3b928 | 0410 0010      : subi.b #$10,(A0)    // decrease code -10
        3b92c | 0c01 00f7      : cmpi.b #-$9,D1
        3b930 | 6604           : bne    $3b936
        3b932 | 0610 0010      : addi.b #$10,(A0)    // increase code +10
        3b936 | 0c01 00ef      : cmpi.b #-$11,D1
        3b93a | 6604           : bne    $3b940
        3b93c | 1010           : move.b (A0),D0      // play sound
        3b93e | 6008           : bra    $3b948
        3b940 | 0c01 00df      : cmpi.b #-$21,D1
        3b944 | 6608           : bne    $3b94e
        3b946 | 4200           : clr.b  D0           // stop sound
        3b948 | 13c0 003c 0013 : move.b D0,$3c0013.l // send sound code
        3b94e | 60b6           : bra    $3b906
        -->
    </script>
    <script state="run">
        <output format="----- r-shark 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="up : increase code +10"              line="13" align="center" />
        <output format="down : decrease 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@40100</argument>
        </output>
    </script>
    <script state="off">
        <action>maincpu.mq@0082e = 41f9003400807208</action>
        <action>maincpu.mq@3b900 = ffffffffffffffff</action>
        <action>maincpu.mq@3b908 = ffffffffffffffff</action>
        <action>maincpu.mq@3b910 = ffffffffffffffff</action>
        <action>maincpu.mq@3b918 = ffffffffffffffff</action>
        <action>maincpu.mq@3b920 = ffffffffffffffff</action>
        <action>maincpu.mq@3b928 = ffffffffffffffff</action>
        <action>maincpu.mq@3b930 = ffffffffffffffff</action>
        <action>maincpu.mq@3b938 = ffffffffffffffff</action>
        <action>maincpu.mq@3b940 = ffffffffffffffff</action>
        <action>maincpu.mq@3b948 = ffffffffffffffff</action>
    </script>
</cheat>
Post Reply