These are IQ's codes in use .
/* Rom decrypt codes */
static void save_dec_p(void)
{
FILE* PROM = fopen("xxx_p_bin", "wb");
if (PROM) {
fwrite(memory_region(REGION_CPU1), 1, memory_region_length(REGION_CPU1), PROM);
fclose(PROM);
}
}
static void save_dec_s(void)
{
FILE* SROM = fopen("xxx_s_bin", "wb");
if (SROM) {
fwrite(memory_region(REGION_GFX1), 1, memory_region_length(REGION_GFX1), SROM);
fclose(SROM);
}
}
static void save_dec_vs(void)
{
FILE* V1ROM = fopen("xxx_v1d.bin", "wb");
if (V1ROM) {
fwrite(memory_region(REGION_SOUND1), 1, 0x800000, V1ROM);
fclose(V1ROM);
}
FILE* V2ROM = fopen("xxx_v2d.bin", "wb");
if (V2ROM) {
fwrite(memory_region(REGION_SOUND1)+0x800000, 1, 0x800000, V2ROM);
fclose(V2ROM);
}
}