script "P1 Infinite Lives" \
 "comm:F6 at the end of game"  
run:
    poke $10C005 $05
script "P1 Infinite Energy"  
run:
    poke $10C014 $28
script "P1 Infinite Bombs"  
run:
    poke $10C021 $02
script "P1 Infinite Power"  
run:
    poke $10C08A $30
    poke $10C08B $00
script "P1 Get an Instant LV1 Attack Now!"  
on:
    poke $10C088 $10
script "P1 Get an Instant LV2 Attack Now!"  
on:
    poke $10C088 $20
script "P1 Get an Instant Boss Attack Now!"  
on:
    poke $10C088 $30
script "P1 Select Character" \
 "comm:Free player selection - enable/change it on the VS screen or the character select screen" \
 "0x01/Loadran"\
 "0x02/Macky + Pentell"\
 "0x03/Arthur Schmidt"\
 "0x04/Yan Yanyung"\
 "0x05/Griffon"\
 "0x06/Really Till"\
 "0x07/Tinker + Linker"\
 "0x08/Nanja Monja"\
 "0x09/Kim"\
 "0x10/Sprites"\
 "0x11/Dark Ran"\
 "0x12/Mevious"\
 "0x13/Memory" 
run:
    if (param==$01)
      poke $10A681 $00
      poke $10C007 $00
    endif
    if (param==$02)
      poke $10A681 $01
      poke $10C007 $01
    endif
    if (param==$03)
      poke $10A681 $02
      poke $10C007 $02
    endif
    if (param==$04)
      poke $10A681 $03
      poke $10C007 $03
    endif
    if (param==$05)
      poke $10A681 $04
      poke $10C007 $04
    endif
    if (param==$06)
      poke $10A681 $05
      poke $10C007 $05
    endif
    if (param==$07)
      poke $10A681 $06
      poke $10C007 $06
    endif
    if (param==$08)
      poke $10A681 $07
      poke $10C007 $07
    endif
    if (param==$09)
      poke $10A681 $08
      poke $10C007 $08
    endif
    if (param==$10)
      poke $10A681 $09
      poke $10C007 $09
    endif
    if (param==$11)
      poke $10A681 $0A
      poke $10C007 $0A
    endif
    if (param==$12)
      poke $10A681 $B
      poke $10C007 $B
    endif
    if (param==$13)
      poke $10A681 $0C
      poke $10C007 $0C
    endif
script " "  
script "P2 Infinite Lives" \
 "comm:F6 at the end of game"  
run:
    poke $10D005 $05
script "P2 Infinite Energy"  
run:
    poke $10D014 $28
script "P2 Infinite Bombs"  
run:
    poke $10D021 $02
script "P2 Infinite Power"  
run:
    poke $10D08A $30
    poke $10D08B $00
script "P2 Get an Instant LV1 Attack Now!"  
on:
    poke $10D088 $10
script "P2 Get an Instant LV2 Attack Now!"  
on:
    poke $10D088 $20
script "P2 Get an Instant Boss Attack Now!"  
on:
    poke $10D088 $30
script "P2 Select Character" \
 "comm:Free player selection - enable/change it on the VS screen or the character select screen" \
 "0x01/Loadran"\
 "0x02/Macky + Pentell"\
 "0x03/Arthur Schmidt"\
 "0x04/Yan Yanyung"\
 "0x05/Griffon"\
 "0x06/Really Till"\
 "0x07/Tinker + Linker"\
 "0x08/Nanja Monja"\
 "0x09/Kim"\
 "0x10/Sprites"\
 "0x11/Dark Ran"\
 "0x12/Mevious"\
 "0x13/Memory" 
run:
    if (param==$01)
      poke $10A6C1 $00
      poke $10D007 $00
    endif
    if (param==$02)
      poke $10A6C1 $01
      poke $10D007 $01
    endif
    if (param==$03)
      poke $10A6C1 $02
      poke $10D007 $02
    endif
    if (param==$04)
      poke $10A6C1 $03
      poke $10D007 $03
    endif
    if (param==$05)
      poke $10A6C1 $04
      poke $10D007 $04
    endif
    if (param==$06)
      poke $10A6C1 $05
      poke $10D007 $05
    endif
    if (param==$07)
      poke $10A6C1 $06
      poke $10D007 $06
    endif
    if (param==$08)
      poke $10A6C1 $07
      poke $10D007 $07
    endif
    if (param==$09)
      poke $10A6C1 $08
      poke $10D007 $08
    endif
    if (param==$10)
      poke $10A6C1 $09
      poke $10D007 $09
    endif
    if (param==$11)
      poke $10A6C1 $0A
      poke $10D007 $0A
    endif
    if (param==$12)
      poke $10A6C1 $B
      poke $10D007 $B
    endif
    if (param==$13)
      poke $10A6C1 $0C
      poke $10D007 $0C
    endif
script " "  
script "Select Cartridge/NeoGeo Type" \
 "comm:Use in conjunction with the 'Skip RAM/ROM Checks' cheat for the best effect, then enable it and reset. The Home (NEOGEO) setting may open up other aspects of the game or it may even make the game unplayable." \
 "0x80/Arcade (MVS)"\
 "0x00/Home (NEOGEO)" 
run:
    poke $10FD82 param
script "Skip RAM/ROM Checks" \
 "comm:Also allows a quicker start-up without the green screens."  
on:
    temp0=lpeek($C1315C)
    temp1=lpeek($C1314E)
    temp2=lpeek($C131E8)
    temp3=lpeek($C13184)
    temp4=lpeek($C1212E)
    temp5=lpeek($C134FA)
    temp6=dpeek($C14C38)
    temp7=dpeek($C14C3E)
run:
    if (lpeek($C1315C)==$51CFFFF2)
      lpoke $C1315C $6000EB08
    endif
    if (lpeek($C1314E)==$51CFFFF2)
      lpoke $C1314E $6000EB16
    endif
    if (lpeek($C131E8)==$51CFFFF2)
      lpoke $C131E8 $6000EA52
    endif
    if (lpeek($C13184)==$51CFFFF2)
      lpoke $C13184 $6000EAB6
    endif
    if (lpeek($C1212E)==$51CFFFF2)
      lpoke $C1212E $6000EB36
    endif
    if (lpeek($C134FA)==$51CFFFF2)
      lpoke $C134FA $6000E892
    endif
    if (dpeek($C14C38)==$6418)
      dpoke $C14C38 $4E71
    endif
    if (dpeek($C14C3E)==$CEC4)
      dpoke $C14C3E $CEDC
    endif
off:
    lpoke $C1315C temp0
    lpoke $C1314E temp1
    lpoke $C131E8 temp2
    lpoke $C13184 temp3
    lpoke $C1212E temp4
    lpoke $C134FA temp5
    dpoke $C14C38 temp6
    dpoke $C14C3E temp7
script "Infinite Credits" \
 "comm:Alternatively just set Free Play to ON in the Dip Switches menu"  
run:
    poke $D00034 $99
script "Mute All Music" \
 "comm:Fully mutes all music, including BIOS music"  
on:
    if peek($0109)==$03
      temp0=$04AC
    endif
    if peek($0109)==$05
      temp0=$D2A4
    endif
    if peek($0109)==$09
      temp0=$CEBD
    endif
    if peek($0109)==$12
      temp0=$04AC
    endif
    if peek($0109)==$17
      temp0=$04AC
    endif
    if peek($0109)==$22
      temp0=$CEC0
    endif
    if peek($0109)==$24
      temp0=$04C2
    endif
    if peek($0109)==$37
      temp0=$03ED
    endif
    if peek($0109)==$38
      temp0=$03ED
    endif
    if peek($0109)==$50
      temp0=$03ED
    endif
    if peek($0109)==$53
      temp0=$03FE
    endif
    if peek($0109)==$54
      temp0=$03ED
    endif
    if peek($0109)==$57
      temp0=$040D
    endif
    if peek($0109)==$64
      temp0=$0408
    endif
    if peek($0109)==$74
      temp0=$0408
    endif
    if peek($0109)==$90
      temp0=$04AC
    endif
run:
    cpu audio
    if peek(temp0)==$32
      poke temp0 $C9
    endif
    cpu main
off:
    cpu audio
    if peek(temp0)==$C9
      poke temp0 $32
    endif
    cpu main
