Code: Select all
<!-- Space Guerrilla -->
<mamecheat version="1">
<cheat desc="no hit (test)">
<comment>causes gfx bug when you fail to destroy bomb/some enemies</comment>
<script state="on">
<action>maincpu.mb@1102 = 00</action> <!-- enmey -->
<action>maincpu.mb@177b = c3</action> <!-- bomb -->
<action>maincpu.mb@1b51 = c3</action> <!-- bullet -->
</script>
<script state="off">
<action>maincpu.mb@1102 = 24</action>
<action>maincpu.mb@177b = d2</action>
<action>maincpu.mb@1b51 = da</action>
</script>
</cheat>
<cheat desc="auto fire">
<script state="on">
<action>maincpu.mw@0154 = 3180</action>
<action>maincpu.md@3180 = 00c9a01a</action>
<!--
3180 | 1a : ld a,(de)
3181 | a0 : and b
3182 | c9 : ret
-->
</script>
<script state="off">
<action>maincpu.mw@0154 = 07e5</action>
<action>maincpu.md@3180 = 00000000</action>
</script>
</cheat>
<cheat desc="player 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@053e = 3190</action>
<action>maincpu.mw@05e2 = 3190</action>
<action>maincpu.mq@3190 = 10c1093ecdc50006</action>
<action>maincpu.mq@3198 = 000000000000c9f9</action>
<!--
3190 | 06 xx : ld b,$xx
3192 | c5 : push bc
3193 | cd 3e 09 : call $093E
3196 | c1 : pop bc
3197 | 10 f9 : djnz $3192
3199 | c9 : ret
-->
</script>
<script state="change">
<action>maincpu.mb@3191 = param</action>
</script>
<script state="off">
<action>maincpu.mw@053e = 093e</action>
<action>maincpu.mw@05e2 = 093e</action>
<action>maincpu.mq@3190 = 0000000000000000</action>
<action>maincpu.mq@3198 = 0000000000000000</action>
</script>
</cheat>
<cheat desc="bullet speed">
<parameter>
<item value="0x01">01 (slow)</item>
<item value="0x04">02 </item>
<item value="0x08">03 </item>
<item value="0x0c">04 </item>
<item value="0x10">05 (fast)</item>
</parameter>
<script state="change">
<action>maincpu.mb@1802 = param</action> <!-- speed -->
<action>maincpu.mb@1e25 = 05 + param</action> <!-- collision range -->
<action>maincpu.mb@1e28 = b + param</action> <!-- collision range -->
</script>
<script state="off">
<action>maincpu.mb@1802 = 05</action>
<action>maincpu.mb@1e25 = 05</action>
<action>maincpu.mb@1e28 = b</action>
</script>
</cheat>
</mamecheat>