| Previous | 199869 Revisions | Next |
| r19422 Sunday 9th December, 2012 at 05:10:30 UTC by Robbbert |
|---|
| Fixed sf2mdta, inproved sf2mdt [Barry Harris] - removed hack for row scroll table address in sf2mdt (bootleg layer render code doesn't use table, and the game isn't writing the address anywhere, hence the presence of the hack) - aligned scroll 2 layer in sf2mdt - boosted interleave when writing sound command to fix the issue of voice's being dropped - decoded graphics in sf2mdta correctly - hooked up sf2mdta reads and writes the same as sf2mdt with different a layer write layout - hooked up sf2mdta work ram |
| [src/mame/drivers] | fcrash.c |
| [src/mame/includes] | cps1.h |
| r19421 | r19422 | |
|---|---|---|
| 64 | 64 | { |
| 65 | 65 | state->soundlatch_byte_w(space, 0, data >> 8); |
| 66 | 66 | state->m_audiocpu->set_input_line(0, HOLD_LINE); |
| 67 | machine().scheduler().boost_interleave(attotime::zero, attotime::from_usec(50)); /* boost the interleave or some voices get dropped */ | |
| 67 | 68 | } |
| 68 | 69 | } |
| 69 | 70 | |
| r19421 | r19422 | |
| 120 | 121 | state->m_sample_buffer2 = data; |
| 121 | 122 | } |
| 122 | 123 | |
| 124 | /* not verified */ | |
| 125 | #define CPS1_ROWSCROLL_OFFS (0x20/2) /* base of row scroll offsets in other RAM */ | |
| 123 | 126 | |
| 124 | 127 | WRITE16_MEMBER(cps_state::kodb_layer_w) |
| 125 | 128 | { |
| r19421 | r19422 | |
| 140 | 143 | { |
| 141 | 144 | cps_state *state = space.machine().driver_data<cps_state>(); |
| 142 | 145 | |
| 143 | /* layer enable and scroll registers are written here - passing them to m_cps_b_regs and m_cps_a_regs for now for drawing routines */ | |
| 146 | /* layer enable and scroll registers are written here - passing them to m_cps_b_regs and m_cps_a_regs for now for drawing routines | |
| 147 | the scroll layers aren't buttery smooth, due to the lack of using the row scroll address tables in the rendering code, this is also | |
| 148 | supported by the fact that the game doesn't write the table address anywhere */ | |
| 149 | ||
| 144 | 150 | if (offset == 0x0086) |
| 145 | 151 | state->m_cps_a_regs[0x14 / 2] = data + 0xffce; /* scroll 3x */ |
| 146 | 152 | else |
| r19421 | r19422 | |
| 148 | 154 | state->m_cps_a_regs[0x16 / 2] = data; /* scroll 3y */ |
| 149 | 155 | else |
| 150 | 156 | if (offset == 0x0088) |
| 151 | state->m_cps_a_regs[0x10 / 2] = data + 0xffc | |
| 157 | state->m_cps_a_regs[0x10 / 2] = data + 0xffce; /* scroll 2x */ | |
| 152 | 158 | else |
| 153 | 159 | if (offset == 0x0089) |
| 154 | 160 | state->m_cps_a_regs[0x0c / 2] = data + 0xffca; /* scroll 1x */ |
| 155 | 161 | else |
| 156 | 162 | if (offset == 0x008a) { |
| 157 | 163 | state->m_cps_a_regs[0x12 / 2] = data; /* scroll 2y */ |
| 158 | state->m_cps_a_regs[0x20 / 2] = data; /* row scroll start */ | |
| 159 | state->m_cps_a_regs[0x08 / 2] = m_bootleg_work_ram[0x802e / 2]; /* pretty gross hack?, but the row scroll table address isn't written anywhere else */ | |
| 164 | state->m_cps_a_regs[CPS1_ROWSCROLL_OFFS] = data; /* row scroll start */ | |
| 160 | 165 | } else |
| 161 | 166 | if (offset == 0x008b) |
| 162 | 167 | state->m_cps_a_regs[0x0e / 2] = data; /* scroll 1y */ |
| r19421 | r19422 | |
| 165 | 170 | state->m_cps_b_regs[m_layer_enable_reg / 2] = data; |
| 166 | 171 | } |
| 167 | 172 | |
| 173 | WRITE16_MEMBER(cps_state::sf2mdta_layer_w) | |
| 174 | { | |
| 175 | cps_state *state = space.machine().driver_data<cps_state>(); | |
| 176 | ||
| 177 | /* layer enable and scroll registers are written here - passing them to m_cps_b_regs and m_cps_a_regs for now for drawing routines | |
| 178 | the scroll layers aren't buttery smooth, due to the lack of using the row scroll address tables in the rendering code, this is also | |
| 179 | supported by the fact that the game doesn't write the table address anywhere */ | |
| 180 | ||
| 181 | if (offset == 0x0086) | |
| 182 | state->m_cps_a_regs[0x0c / 2] = data + 0xffbe; /* scroll 1x */ | |
| 183 | else | |
| 184 | if (offset == 0x0087) | |
| 185 | state->m_cps_a_regs[0x0e / 2] = data; /* scroll 1y */ | |
| 186 | else | |
| 187 | if (offset == 0x0088) | |
| 188 | state->m_cps_a_regs[0x14 / 2] = data + 0xffce; /* scroll 3x */ | |
| 189 | else | |
| 190 | if (offset == 0x0089) { | |
| 191 | state->m_cps_a_regs[0x12 / 2] = data; /* scroll 2y */ | |
| 192 | state->m_cps_a_regs[CPS1_ROWSCROLL_OFFS] = data; /* row scroll start */ | |
| 193 | } else | |
| 194 | if (offset == 0x008a) | |
| 195 | state->m_cps_a_regs[0x10 / 2] = data + 0xffce; /* scroll 2x */ | |
| 196 | else | |
| 197 | if (offset == 0x008b) | |
| 198 | state->m_cps_a_regs[0x16 / 2] = data; /* scroll 3y */ | |
| 199 | else | |
| 200 | if (offset == 0x00a6) | |
| 201 | state->m_cps_b_regs[m_layer_enable_reg / 2] = data; | |
| 202 | } | |
| 168 | 203 | |
| 169 | /* not verified */ | |
| 170 | #define CPS1_ROWSCROLL_OFFS (0x20/2) /* base of row scroll offsets in other RAM */ | |
| 171 | 204 | |
| 172 | 205 | static void fcrash_update_transmasks( running_machine &machine ) |
| 173 | 206 | { |
| r19421 | r19422 | |
| 928 | 961 | m_layer_scroll3x_offset = 0; |
| 929 | 962 | m_sprite_base = 0x1000; |
| 930 | 963 | m_sprite_list_end_marker = 0x8000; |
| 931 | m_sprite_x_offset = | |
| 964 | m_sprite_x_offset = 2; | |
| 932 | 965 | |
| 933 | 966 | save_item(NAME(m_sample_buffer1)); |
| 934 | 967 | save_item(NAME(m_sample_buffer2)); |
| r19421 | r19422 | |
| 1296 | 1329 | ROM_LOAD16_BYTE( "4.mdta", 0x100001, 0x20000, CRC(bd98ff15) SHA1(ed902d949b0b5c5beaaea78a4b418ffa6db9e1df) ) |
| 1297 | 1330 | |
| 1298 | 1331 | ROM_REGION( 0x600000, "gfx", 0 ) |
| 1299 | ROMX_LOAD( "pf4 sh058.ic89", 0x000000, 0x80000, BAD_DUMP CRC(40fdf624) SHA1(cb928602744bf36e6851527f00d90da29de751e6), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1300 | ROM_CONTINUE( 0x000002, 0x80000) | |
| 1301 | ROMX_LOAD( "pf7 sh072.ic92", 0x000004, 0x80000, CRC(fb78022e) SHA1(b8974387056dd52db96b01cc4648edc814398c7e), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1302 | ROM_CONTINUE( 0x000006, 0x80000) | |
| 1303 | ROMX_LOAD( "pf5 sh036.ic90", 0x200000, 0x80000, CRC(0a6be48b) SHA1(b7e72c94d4e3eb4a6bba6608d9b9a093c8901ad9), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1304 | ROM_CONTINUE( 0x200002, 0x80000) | |
| 1305 | ROMX_LOAD( "pf8 sh074.ic93", 0x200004, 0x80000, CRC(6258c7cf) SHA1(4cd7519245c0aa816934a43e6743160f715d7dc2), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1306 | ROM_CONTINUE( 0x200006, 0x80000) | |
| 1307 | ROMX_LOAD( "pf6 sh070.ic88", 0x400000, 0x80000, CRC(9b5b09d7) SHA1(698a6aab41e495bd0c37a19aee16a84f04d15797), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1308 | ROM_CONTINUE( 0x400002, 0x80000) | |
| 1309 | ROMX_LOAD( "pf9 sh001.ic91", 0x400004, 0x80000, CRC(9f25090e) SHA1(12ff0431ef6550db446985c8914ac7d78eec6b6d), ROM_GROUPWORD | ROM_SKIP(6) ) | |
| 1310 | ROM_CONTINUE( 0x400006, 0x80000) | |
| 1332 | ROMX_LOAD( "pf4 sh058.ic89", 0x000000, 0x100000, BAD_DUMP CRC(40fdf624) SHA1(cb928602744bf36e6851527f00d90da29de751e6), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1333 | ROMX_LOAD( "pf7 sh072.ic92", 0x000002, 0x100000, CRC(fb78022e) SHA1(b8974387056dd52db96b01cc4648edc814398c7e), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1334 | ROMX_LOAD( "pf5 sh036.ic90", 0x200000, 0x100000, CRC(0a6be48b) SHA1(b7e72c94d4e3eb4a6bba6608d9b9a093c8901ad9), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1335 | ROMX_LOAD( "pf8 sh074.ic93", 0x200002, 0x100000, CRC(6258c7cf) SHA1(4cd7519245c0aa816934a43e6743160f715d7dc2), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1336 | ROMX_LOAD( "pf6 sh070.ic88", 0x400000, 0x100000, CRC(9b5b09d7) SHA1(698a6aab41e495bd0c37a19aee16a84f04d15797), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1337 | ROMX_LOAD( "pf9 sh001.ic91", 0x400002, 0x100000, CRC(9f25090e) SHA1(12ff0431ef6550db446985c8914ac7d78eec6b6d), ROM_GROUPWORD | ROM_SKIP(2) ) | |
| 1311 | 1338 | |
| 1312 | 1339 | ROM_REGION( 0x30000, "soundcpu", 0 ) /* Sound program + samples */ |
| 1313 | 1340 | ROM_LOAD( "1.ic28", 0x00000, 0x20000, CRC(d5bee9cc) SHA1(e638cb5ce7a22c18b60296a7defe8b03418da56c) ) |
| r19421 | r19422 | |
| 1406 | 1433 | |
| 1407 | 1434 | /* bootleg sprite ram */ |
| 1408 | 1435 | m_bootleg_sprite_ram = (UINT16*)machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0x700000, 0x703fff); |
| 1409 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0x704000, 0x707fff, m_bootleg_sprite_ram); /* both of these need to be mapped */ | |
| 1436 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0x704000, 0x707fff, m_bootleg_sprite_ram); /* both of these need to be mapped - see the "Magic Delta Turbo" text on the title screen */ | |
| 1410 | 1437 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_write_handler(0x70c106, 0x70c107, write16_delegate(FUNC(cps_state::cawingbl_soundlatch_w),this)); |
| 1411 | 1438 | |
| 1412 | m_bootleg_work_ram = (UINT16*)machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0xff0000, 0xffffff); | |
| 1439 | machine().device("maincpu")->memory().space(AS_PROGRAM).unmap_write(0x800030, 0x800031); /* coin lockout doesn't work (unmap it) */ | |
| 1440 | ||
| 1441 | DRIVER_INIT_CALL(cps1); | |
| 1442 | } | |
| 1443 | ||
| 1444 | DRIVER_INIT_MEMBER(cps_state, sf2mdta) | |
| 1445 | { | |
| 1446 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_read_handler(0x70c018, 0x70c01f, read16_delegate(FUNC(cps_state::cps1_dsw_r),this)); | |
| 1447 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_write_handler(0x708000, 0x708fff, write16_delegate(FUNC(cps_state::sf2mdta_layer_w),this)); | |
| 1448 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_read_port(0x70c000, 0x70c001, "IN1"); | |
| 1449 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_read_port(0x70c008, 0x70c009, "IN2"); | |
| 1413 | 1450 | |
| 1451 | /* bootleg sprite ram */ | |
| 1452 | m_bootleg_sprite_ram = (UINT16*)machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0x700000, 0x703fff); | |
| 1453 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0x704000, 0x707fff, m_bootleg_sprite_ram); /* both of these need to be mapped - see the "Magic Delta Turbo" text on the title screen */ | |
| 1454 | machine().device("maincpu")->memory().space(AS_PROGRAM).install_write_handler(0x70c106, 0x70c107, write16_delegate(FUNC(cps_state::cawingbl_soundlatch_w),this)); | |
| 1455 | ||
| 1456 | m_bootleg_work_ram = (UINT16*)machine().device("maincpu")->memory().space(AS_PROGRAM).install_ram(0xfc0000, 0xfcffff); /* this has moved */ | |
| 1457 | ||
| 1414 | 1458 | machine().device("maincpu")->memory().space(AS_PROGRAM).unmap_write(0x800030, 0x800031); /* coin lockout doesn't work (unmap it) */ |
| 1415 | 1459 | |
| 1416 | 1460 | DRIVER_INIT_CALL(cps1); |
| r19421 | r19422 | |
| 1421 | 1465 | GAME( 1991, kodb, kod, kodb, kodb, cps_state, kodb, ROT0, "bootleg (Playmark)", "The King of Dragons (bootleg)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE ) // 910731 "ETC" |
| 1422 | 1466 | GAME( 1990, cawingbl, cawing, cawingbl, cawingbl, cps_state, cawingbl, ROT0, "bootleg", "Carrier Air Wing (bootleg with 2xYM2203 + 2xMSM205 set 1)", GAME_SUPPORTS_SAVE ) |
| 1423 | 1467 | GAME( 1990, cawingb2, cawing, cawingbl, cawingbl, cps_state, cawingbl, ROT0, "bootleg", "Carrier Air Wing (bootleg with 2xYM2203 + 2xMSM205 set 2)", GAME_SUPPORTS_SAVE ) |
| 1424 | GAME( 1992, sf2mdt, sf2ce, sf2mdt, sf2mdt, cps_state, sf2mdt, ROT0, "bootleg", "Street Fighter II': Magic Delta Turbo (bootleg, set 1)", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE ) // 920313 - based on (heavily modified) World version | |
| 1425 | GAME( 1992, sf2mdta, sf2ce, sf2mdt, sf2mdt, cps_state, sf2mdt, ROT0, "bootleg", "Street Fighter II': Magic Delta Turbo (bootleg, set 2)", GAME_NOT_WORKING | GAME_NO_SOUND | GAME_SUPPORTS_SAVE ) // 920313 - based on World version | |
| 1468 | GAME( 1992, sf2mdt, sf2ce, sf2mdt, sf2mdt, cps_state, sf2mdt, ROT0, "bootleg", "Street Fighter II': Magic Delta Turbo (bootleg, set 1)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE ) // 920313 - based on (heavily modified) World version | |
| 1469 | GAME( 1992, sf2mdta, sf2ce, sf2mdt, sf2mdt, cps_state, sf2mdta, ROT0, "bootleg", "Street Fighter II': Magic Delta Turbo (bootleg, set 2)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE ) // 920313 - based on World version | |
| 1426 | 1470 | GAME( 199?, sgyxz, wof, sgyxz, fcrash, cps_state, cps1, ROT0, "bootleg (All-In Electronic)", "Warriors of Fate ('sgyxz' bootleg)", GAME_NOT_WORKING | GAME_NO_SOUND ) |
| r19421 | r19422 | |
|---|---|---|
| 170 | 170 | DECLARE_READ16_MEMBER(qsound_sharedram2_r); |
| 171 | 171 | DECLARE_WRITE16_MEMBER(qsound_sharedram2_w); |
| 172 | 172 | DECLARE_WRITE8_MEMBER(qsound_banksw_w); |
| 173 | DECLARE_READ16_MEMBER(sf2mdt_r); | |
| 174 | 173 | DECLARE_READ16_MEMBER(sf2rb_prot_r); |
| 175 | 174 | DECLARE_READ16_MEMBER(sf2rb2_prot_r); |
| 176 | 175 | DECLARE_READ16_MEMBER(cps1_dsw_r); |
| r19421 | r19422 | |
| 198 | 197 | DECLARE_DRIVER_INIT(pang3); |
| 199 | 198 | DECLARE_DRIVER_INIT(sf2ee); |
| 200 | 199 | DECLARE_DRIVER_INIT(cps1); |
| 201 | DECLARE_DRIVER_INIT(sf2mdt); | |
| 202 | 200 | DECLARE_DRIVER_INIT(dino); |
| 203 | 201 | DECLARE_DRIVER_INIT(punisher); |
| 204 | 202 | DECLARE_DRIVER_INIT(wof); |
| r19421 | r19422 | |
| 231 | 229 | /* fcrash handlers */ |
| 232 | 230 | DECLARE_DRIVER_INIT(kodb); |
| 233 | 231 | DECLARE_DRIVER_INIT(cawingbl); |
| 232 | DECLARE_DRIVER_INIT(sf2mdt); | |
| 233 | DECLARE_DRIVER_INIT(sf2mdta); | |
| 234 | 234 | DECLARE_MACHINE_START(fcrash); |
| 235 | 235 | DECLARE_MACHINE_RESET(fcrash); |
| 236 | 236 | DECLARE_MACHINE_START(kodb); |
| r19421 | r19422 | |
| 239 | 239 | DECLARE_WRITE16_MEMBER(kodb_layer_w); |
| 240 | 240 | DECLARE_WRITE16_MEMBER(cawingbl_soundlatch_w); |
| 241 | 241 | DECLARE_WRITE16_MEMBER(sf2mdt_layer_w); |
| 242 | DECLARE_WRITE16_MEMBER(sf2mdta_layer_w); | |
| 242 | 243 | UINT32 screen_update_fcrash(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); |
| 243 | 244 | }; |
| 244 | 245 |
| Previous | 199869 Revisions | Next |