Mercurial > repos > blastem
comparison romdb.c @ 1470:1e3e0205640f
Add support for writeable ROM and an entry for Game no Kanzume Otokuyou using that support as it expects the cart area to be writable
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Sat, 14 Oct 2017 05:03:38 -0700 |
parents | 14a2834d010c |
children | 8f3b6a64b658 |
comparison
equal
deleted
inserted
replaced
1469:723f6381cffa | 1470:1e3e0205640f |
---|---|
557 memmap_chunk *map = state->info->map + state->index; | 557 memmap_chunk *map = state->info->map + state->index; |
558 map->start = start; | 558 map->start = start; |
559 map->end = end + 1; | 559 map->end = end + 1; |
560 if (!strcmp(dtype, "ROM")) { | 560 if (!strcmp(dtype, "ROM")) { |
561 map->buffer = state->rom + offset; | 561 map->buffer = state->rom + offset; |
562 map->flags = MMAP_READ; | |
563 map->mask = calc_mask(state->rom_size - offset, start, end); | 562 map->mask = calc_mask(state->rom_size - offset, start, end); |
563 if (strcmp(tern_find_ptr_default(node, "writeable", "no"), "yes")) { | |
564 map->flags = MMAP_READ; | |
565 } else { | |
566 map->flags = MMAP_READ | MMAP_WRITE | MMAP_CODE; | |
567 } | |
564 } else if (!strcmp(dtype, "LOCK-ON")) { | 568 } else if (!strcmp(dtype, "LOCK-ON")) { |
565 rom_info lock_info; | 569 rom_info lock_info; |
566 if (state->lock_on) { | 570 if (state->lock_on) { |
567 lock_info = configure_rom(state->rom_db, state->lock_on, state->lock_on_size, NULL, 0, NULL, 0); | 571 lock_info = configure_rom(state->rom_db, state->lock_on, state->lock_on_size, NULL, 0, NULL, 0); |
568 } else if (state->rom_size > start) { | 572 } else if (state->rom_size > start) { |