aboutsummaryrefslogtreecommitdiff
path: root/nes
diff options
context:
space:
mode:
Diffstat (limited to 'nes')
-rw-r--r--nes/bus.go12
-rw-r--r--nes/nes.go6
2 files changed, 9 insertions, 9 deletions
diff --git a/nes/bus.go b/nes/bus.go
index 480d178..d9fd521 100644
--- a/nes/bus.go
+++ b/nes/bus.go
@@ -13,9 +13,9 @@ func (n *Console) Read(addr uint16) uint8 {
func (n *Console) Write(addr uint16, v uint8) {
switch {
- case addr < 0x2000:
- n.RAM[addr&0x7FF] = v
- case addr >= 0x4020:
- n.Cart.Mapper.CPUWrite(addr, v)
- }
-} \ No newline at end of file
+ case addr < 0x2000:
+ n.RAM[addr&0x7FF] = v
+ case addr >= 0x4020:
+ n.Cart.Mapper.CPUWrite(addr, v)
+ }
+}
diff --git a/nes/nes.go b/nes/nes.go
index c4d09a0..0f2a754 100644
--- a/nes/nes.go
+++ b/nes/nes.go
@@ -6,9 +6,9 @@ import (
)
type Console struct {
- CPU *cpu.CPU
+ CPU *cpu.CPU
Cart *cart.Cartridge
- RAM [0x800]uint8
+ RAM [0x800]uint8
// PPU, APU, controllers once they exist
cycles uint64
}
@@ -31,4 +31,4 @@ func (n *Console) StepFrame() {
for done := 0; done < cyclesPerFrame; {
done += n.Step()
}
-} \ No newline at end of file
+}