Code: Select all
<cheat desc="no hit">
<script state="on">
<action>maincpu.mb@2a73 = c9</action> <!-- water -->
<action>maincpu.mb@2fae = 18</action> <!-- battery -->
<action>maincpu.mb@45fa = c3</action> <!-- enemy -->
<action>maincpu.mb@6ba4 = c3</action> <!-- bullet -->
<action>maincpu.mb@6db8 = c3</action> <!-- missile -->
<action>maincpu.mb@6fc9 = c9</action> <!-- bomb -->
<action>maincpu.mb@70f9 = c3</action> <!-- mini missile -->
<action>maincpu.mb@7247 = c9</action> <!-- laser -->
</script>
<script state="off">
<action>maincpu.mb@2a73 = c0</action>
<action>maincpu.mb@2fae = 30</action>
<action>maincpu.mb@45fa = da</action>
<action>maincpu.mb@6ba4 = da</action>
<action>maincpu.mb@6db8 = da</action>
<action>maincpu.mb@6fc9 = c0</action>
<action>maincpu.mb@70f9 = da</action>
<action>maincpu.mb@7247 = d8</action>
</script>
</cheat>
<cheat desc="walk through wall">
<script state="on">
<action>maincpu.mb@24d9 = c3</action> <!-- up -->
<action>maincpu.mb@251b = c3</action> <!-- upper-left -->
<action>maincpu.mb@258c = c3</action> <!-- upper-right -->
<action>maincpu.mb@2600 = c3</action> <!-- down -->
<action>maincpu.mb@2642 = c3</action> <!-- lower-left -->
<action>maincpu.mb@26b4 = c3</action> <!-- lower-right -->
<action>maincpu.mb@272c = c3</action> <!-- left -->
<action>maincpu.mb@276a = c3</action> <!-- right -->
</script>
<script state="off">
<action>maincpu.mb@24d9 = ca</action>
<action>maincpu.mb@251b = ca</action>
<action>maincpu.mb@258c = ca</action>
<action>maincpu.mb@2600 = ca</action>
<action>maincpu.mb@2642 = ca</action>
<action>maincpu.mb@26b4 = ca</action>
<action>maincpu.mb@272c = ca</action>
<action>maincpu.mb@276a = ca</action>
</script>
</cheat>
<cheat desc="player speed">
<parameter min="0x01" max="0x05" step="0x01" />
<script state="on">
<action>maincpu.md@0281b = c9b8a0cd</action> <!-- down -->
<action>maincpu.md@02830 = c9b8a7cd</action> <!-- up -->
<action>maincpu.md@02840 = c9b8aecd</action> <!-- left -->
<action>maincpu.md@02847 = c9b8b5cd</action> <!-- right -->
<action>maincpu.mq@138a0 = cbc95700d67ac8cb</action>
<action>maincpu.mq@138a8 = e0cbc95700c67ac8</action>
<action>maincpu.mq@138b0 = 7bc0cbc95f00d67b</action>
<action>maincpu.mq@138b8 = ffffffffc95f00c6</action>
<!--
b8a0 | cb c8 : set 1,b // down
b8a2 | 7a : ld a,d
b8a3 | d6 xx : sub $xx
b8a5 | 57 : ld d,a
b8a6 | c9 : ret
b8a7 | cb c8 : set 1,b // up
b8a9 | 7a : ld a,d
b8aa | c6 xx : add a,$xx
b8ac | 57 : ld d,a
b8ad | c9 : ret
b8ae | cb e0 : set 4,b // left
b8b0 | 7b : ld a,e
b8b1 | d6 xx : sub $xx
b8b3 | 5f : ld e,a
b8b4 | c9 : ret
b8b5 | cb c0 : set 0,b // right
b8b7 | 7b : ld a,e
b8b8 | c6 xx : add a,$xx
b8ba | 5f : ld e,a
b8bb | c9 : ret
-->
</script>
<script state="change">
<action>maincpu.mb@138a4 = param</action>
<action>maincpu.mb@138ab = param</action>
<action>maincpu.mb@138b2 = param</action>
<action>maincpu.mb@138b9 = param</action>
</script>
<script state="off">
<action>maincpu.md@0281b = c915c8cb</action>
<action>maincpu.md@02830 = c914c8cb</action>
<action>maincpu.md@02840 = c91de0cb</action>
<action>maincpu.md@02847 = c91cc0cb</action>
<action>maincpu.mq@138a0 = ffffffffffffffff</action>
<action>maincpu.mq@138a8 = ffffffffffffffff</action>
<action>maincpu.mq@138b0 = ffffffffffffffff</action>
<action>maincpu.mq@138b8 = ffffffffffffffff</action>
</script>
</cheat>
<cheat desc="fast bomb">
<script state="on">
<action>maincpu.md@01fb0 = 18a73021</action>
<action>maincpu.md@01fc7 = ddb890cd</action>
<action>maincpu.mq@13890 = c9675fc67cf4db2a</action>
<!--
b890 | 2a db f4 : ld hl,($f4db)
b893 | 7c : ld a,h
b894 | c6 5f : add a,$5f
b896 | 67 : ld h,a
b897 | c9 : ret
-->
</script>
<script state="off">
<action>maincpu.md@01fb0 = 28a70021</action>
<action>maincpu.md@01fc7 = ddf4db2a</action>
<action>maincpu.mq@13890 = ffffffffffffffff</action>
</script>
</cheat>
<cheat desc="sound test mode">
<comment>reset the game (F3) to enter sound test mode</comment>
<script state="on">
<action>maincpu.mw@00439 = b8c0</action>
<action>maincpu.mq@138c0 = 3ad5b8c311e10021</action>
<action>maincpu.mq@138c8 = 20fdfec847b8c001</action>
<action>maincpu.mq@138d0 = fe340120fefe3501</action>
<action>maincpu.mq@138d8 = dffe04187e0320ef</action>
<action>maincpu.mq@138e0 = ffffc9c20032afc0</action>
<!--
b8c0 | 21 00 e1 : ld hl,$e100
b8c3 | 11 c3 b8 : ld de,$b8c3
b8c6 | d5 : push de
b8c7 | 3a 01 c0 : ld a,($c001) // read input
b8ca | b8 : cp b
b8cb | 47 : ld b,a
b8cc | c8 : ret z
b8cd | fe fd : cp $fd
b8cf | 20 01 : jr nz,$b8d2
b8d1 | 35 : dec (hl) // decrease code
b8d2 | fe fe : cp $fe
b8d4 | 20 01 : jr nz,$b8d7
b8d6 | 34 : inc (hl) // increase code
b8d7 | fe ef : cp $ef
b8d9 | 20 03 : jr nz,$b8de
b8db | 7e : ld a,(hl) // play sound
b8dc | 18 04 : jr $b8e2
b8de | fe df : cp $df
b8e0 | c0 : ret nz
b8e1 | af : xor a // stop sound
b8e2 | 32 00 c2 : ld ($c200),a // send sound code
b8e5 | c9 : ret
-->
</script>
<script state="run">
<output format="----- valtric 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="button 2 : stop sound" line="14" align="center" />
<output format="----------------------------" line="15" align="center" />
<output format="<< sound code %2.2X >>" line="17" align="center">
<argument>maincpu.pb@e100</argument>
</output>
</script>
<script state="off">
<action>maincpu.mw@00439 = 3546</action>
<action>maincpu.mq@138c0 = ffffffffffffffff</action>
<action>maincpu.mq@138c8 = ffffffffffffffff</action>
<action>maincpu.mq@138d0 = ffffffffffffffff</action>
<action>maincpu.mq@138d8 = ffffffffffffffff</action>
<action>maincpu.mq@138e0 = ffffffffffffffff</action>
</script>
</cheat>
<cheat desc="skip in-game rom check">
<script state="on">
<action>maincpu.mw@05d2 = f518</action>
</script>
<script state="off">
<action>maincpu.mw@05d2 = aa7e</action>
</script>
</cheat>