mirror of
https://github.com/colby-swandale/waterfoul
synced 2024-12-26 21:58:54 +01:00
fixed incorrect behavior of mbc1 ram access
gameboy will simply not write to memory if memory is not enabled.
This commit is contained in:
parent
e729181763
commit
4ccb749957
1 changed files with 1 additions and 1 deletions
|
@ -55,7 +55,7 @@ module Waterfoul
|
|||
when 0x6000...0x8000
|
||||
@mode = v & 0x1
|
||||
when 0xA000...0xC000
|
||||
fail 'trying to write invalid ram' unless @ram_enabled
|
||||
return unless @ram_enabled
|
||||
addr = i - 0xA000
|
||||
if @mode == 0
|
||||
@ram[addr] = v
|
||||
|
|
Loading…
Reference in a new issue