diff --git a/BizHawk.Emulation.Common/Interfaces/IEmulator.cs b/BizHawk.Emulation.Common/Interfaces/IEmulator.cs
index 80bb782845..9b67c6dfaa 100644
--- a/BizHawk.Emulation.Common/Interfaces/IEmulator.cs
+++ b/BizHawk.Emulation.Common/Interfaces/IEmulator.cs
@@ -25,10 +25,11 @@ namespace BizHawk.Emulation.Common
ControllerDefinition ControllerDefinition { get; }
///
- /// Provides controller instance information to the core, such as what buttons are currently pressed
- /// Note that the client is responsible for setting this property and updating its state
+ /// Sets the controller instance that the core will use for input.
+ /// Tee provided by the client must provide the buttons specified the buttons
+ /// defined by the provided by the core
///
- IController Controller { get; set; }
+ IController Controller { set; }
///
/// Runs the emulator core for 1 frame
diff --git a/BizHawk.Emulation.Cores/Calculator/TI83.IEmulator.cs b/BizHawk.Emulation.Cores/Calculator/TI83.IEmulator.cs
index 3db6ff3bfe..758c324e63 100644
--- a/BizHawk.Emulation.Cores/Calculator/TI83.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Calculator/TI83.IEmulator.cs
@@ -11,7 +11,7 @@ namespace BizHawk.Emulation.Cores.Calculators
get { return TI83Controller; }
}
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public void FrameAdvance(bool render, bool rendersound)
{
diff --git a/BizHawk.Emulation.Cores/Computers/AppleII/AppleII.IEmulator.cs b/BizHawk.Emulation.Cores/Computers/AppleII/AppleII.IEmulator.cs
index 49065b12b2..ba98f582fb 100644
--- a/BizHawk.Emulation.Cores/Computers/AppleII/AppleII.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Computers/AppleII/AppleII.IEmulator.cs
@@ -8,7 +8,7 @@ namespace BizHawk.Emulation.Cores.Computers.AppleII
public ControllerDefinition ControllerDefinition => AppleIIController;
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public int Frame { get; private set; }
diff --git a/BizHawk.Emulation.Cores/Computers/Commodore64/C64.cs b/BizHawk.Emulation.Cores/Computers/Commodore64/C64.cs
index 3bb1b4f7f6..766b00e627 100644
--- a/BizHawk.Emulation.Cores/Computers/Commodore64/C64.cs
+++ b/BizHawk.Emulation.Cores/Computers/Commodore64/C64.cs
@@ -142,7 +142,7 @@ namespace BizHawk.Emulation.Cores.Computers.Commodore64
[SaveState.DoNotSave]
public ControllerDefinition ControllerDefinition { get { return C64ControllerDefinition; } }
[SaveState.DoNotSave]
- public IController Controller { get { return _board.Controller; } set { _board.Controller = value; } }
+ public IController Controller { private get { return _board.Controller; } set { _board.Controller = value; } }
[SaveState.DoNotSave]
public IEmulatorServiceProvider ServiceProvider { get; private set; }
diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/2600/Atari2600.cs b/BizHawk.Emulation.Cores/Consoles/Atari/2600/Atari2600.cs
index 9ad5c67b1a..a80cc735a7 100644
--- a/BizHawk.Emulation.Cores/Consoles/Atari/2600/Atari2600.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Atari/2600/Atari2600.cs
@@ -75,7 +75,7 @@ namespace BizHawk.Emulation.Cores.Atari.Atari2600
public ControllerDefinition ControllerDefinition { get { return Atari2600ControllerDefinition; } }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public int Frame { get { return _frame; } set { _frame = value; } }
diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/7800/Atari7800.cs b/BizHawk.Emulation.Cores/Consoles/Atari/7800/Atari7800.cs
index c71020bee2..b5d8220b05 100644
--- a/BizHawk.Emulation.Cores/Consoles/Atari/7800/Atari7800.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Atari/7800/Atari7800.cs
@@ -151,7 +151,7 @@ namespace BizHawk.Emulation.Cores.Atari.Atari7800
public Atari7800Control ControlAdapter { get; private set; }
public ControllerDefinition ControllerDefinition { get; private set; }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
private class ConsoleLogger : ILogger
diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/lynx/Lynx.cs b/BizHawk.Emulation.Cores/Consoles/Atari/lynx/Lynx.cs
index ffc81924d7..5d5561d2d7 100644
--- a/BizHawk.Emulation.Cores/Consoles/Atari/lynx/Lynx.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Atari/lynx/Lynx.cs
@@ -175,7 +175,7 @@ namespace BizHawk.Emulation.Cores.Atari.Lynx
};
public ControllerDefinition ControllerDefinition { get { return LynxTroller; } }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
private LibLynx.Buttons GetButtons()
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Coleco/ColecoVision.cs b/BizHawk.Emulation.Cores/Consoles/Coleco/ColecoVision.cs
index fbaad91e3d..1d8e382027 100644
--- a/BizHawk.Emulation.Cores/Consoles/Coleco/ColecoVision.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Coleco/ColecoVision.cs
@@ -76,7 +76,7 @@ namespace BizHawk.Emulation.Cores.ColecoVision
private readonly ColecoVisionControllerDeck ControllerDeck;
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
private const ushort RamSizeMask = 0x03FF;
diff --git a/BizHawk.Emulation.Cores/Consoles/Intellivision/Intellivision.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Intellivision/Intellivision.IEmulator.cs
index 6cd75072b2..fa0bd5ae59 100644
--- a/BizHawk.Emulation.Cores/Consoles/Intellivision/Intellivision.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Intellivision/Intellivision.IEmulator.cs
@@ -8,7 +8,7 @@ namespace BizHawk.Emulation.Cores.Intellivision
public ControllerDefinition ControllerDefinition => _controllerDeck.Definition;
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public void FrameAdvance(bool render, bool rendersound)
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.Core.cs b/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.Core.cs
index 606e7e7a61..5052193482 100644
--- a/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.Core.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.Core.cs
@@ -332,17 +332,17 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
if (_isVS)
{
- if (controller.IsPressed("Service Switch"))
+ if (Controller.IsPressed("Service Switch"))
VS_service = 1;
else
VS_service = 0;
- if (controller.IsPressed("Insert Coin P1"))
+ if (Controller.IsPressed("Insert Coin P1"))
VS_coin_inserted |= 1;
else
VS_coin_inserted &= 2;
- if (controller.IsPressed("Insert Coin P2"))
+ if (Controller.IsPressed("Insert Coin P2"))
VS_coin_inserted |= 2;
else
VS_coin_inserted &= 1;
diff --git a/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.cs b/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.cs
index badb9a58cc..12283d547c 100644
--- a/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Nintendo/NES/NES.cs
@@ -42,7 +42,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
this.SyncSettings = (NESSyncSettings)SyncSettings ?? new NESSyncSettings();
this.ControllerSettings = this.SyncSettings.Controls;
CoreComm = comm;
-
+
MemoryCallbacks = new MemoryCallbackSystem();
BootGodDB.Initialize();
videoProvider = new MyVideoProvider(this);
@@ -64,14 +64,14 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
PickVSPalette(cart);
}
-
+
ser.Register(cpu);
Tracer = new TraceBuffer { Header = cpu.TraceHeader };
ser.Register(Tracer);
ser.Register(videoProvider);
ser.Register(magicSoundProvider);
-
+
if (Board is BANDAI_FCG_1)
{
var reader = (Board as BANDAI_FCG_1).reader;
@@ -354,15 +354,9 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
public ControllerDefinition ControllerDefinition { get; private set; }
- IController controller;
- public IController Controller
- {
- get { return controller; }
- set { controller = value; }
- }
-
- int _frame;
+ public IController Controller { private get; set; }
+ private int _frame;
public int Frame { get { return _frame; } set { _frame = value; } }
public void ResetCounters()
diff --git a/BizHawk.Emulation.Cores/Consoles/Nintendo/QuickNES/QuickNES.cs b/BizHawk.Emulation.Cores/Consoles/Nintendo/QuickNES/QuickNES.cs
index 0178bf8ceb..b3432100ae 100644
--- a/BizHawk.Emulation.Cores/Consoles/Nintendo/QuickNES/QuickNES.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Nintendo/QuickNES/QuickNES.cs
@@ -112,7 +112,7 @@ namespace BizHawk.Emulation.Cores.Consoles.Nintendo.QuickNES
#region Controller
public ControllerDefinition ControllerDefinition { get; private set; }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
void SetControllerDefinition()
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES/LibsnesCore.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES/LibsnesCore.IEmulator.cs
index 3f5558bbba..eb9446cac4 100644
--- a/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES/LibsnesCore.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES/LibsnesCore.IEmulator.cs
@@ -10,7 +10,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.SNES
public ControllerDefinition ControllerDefinition => _controllerDeck.Definition;
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public void FrameAdvance(bool render, bool rendersound)
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES9X/Snes9x.cs b/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES9X/Snes9x.cs
index 15fbd3e03a..2e0d9e110b 100644
--- a/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES9X/Snes9x.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Nintendo/SNES9X/Snes9x.cs
@@ -19,7 +19,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.SNES9X
get { return NullController.Instance.Definition; }
}
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
#endregion
diff --git a/BizHawk.Emulation.Cores/Consoles/PC Engine/PCEngine.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/PC Engine/PCEngine.IEmulator.cs
index dd9245de06..d8c15137ad 100644
--- a/BizHawk.Emulation.Cores/Consoles/PC Engine/PCEngine.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/PC Engine/PCEngine.IEmulator.cs
@@ -8,7 +8,7 @@ namespace BizHawk.Emulation.Cores.PCEngine
public ControllerDefinition ControllerDefinition => PCEngineController;
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public void FrameAdvance(bool render, bool rendersound)
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Sega/Genesis/Genesis.Input.cs b/BizHawk.Emulation.Cores/Consoles/Sega/Genesis/Genesis.Input.cs
index b9a92f22f9..890679d39e 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sega/Genesis/Genesis.Input.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sega/Genesis/Genesis.Input.cs
@@ -15,6 +15,6 @@ namespace BizHawk.Emulation.Cores.Sega.Genesis
};
public ControllerDefinition ControllerDefinition { get { return GenesisController; } }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
}
}
\ No newline at end of file
diff --git a/BizHawk.Emulation.Cores/Consoles/Sega/SMS/SMS.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Sega/SMS/SMS.IEmulator.cs
index 8fd3b8c735..f9f036fa4f 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sega/SMS/SMS.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sega/SMS/SMS.IEmulator.cs
@@ -19,7 +19,7 @@ namespace BizHawk.Emulation.Cores.Sega.MasterSystem
}
}
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public void FrameAdvance(bool render, bool rendersound)
{
diff --git a/BizHawk.Emulation.Cores/Consoles/Sega/Saturn/Yabause.cs b/BizHawk.Emulation.Cores/Consoles/Sega/Saturn/Yabause.cs
index 03aca2e19b..3a1bc3d4c4 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sega/Saturn/Yabause.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sega/Saturn/Yabause.cs
@@ -167,7 +167,7 @@ namespace BizHawk.Emulation.Cores.Sega.Saturn
get { return SaturnController; }
}
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public bool GLMode { get; private set; }
diff --git a/BizHawk.Emulation.Cores/Consoles/Sega/gpgx/GPGX.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Sega/gpgx/GPGX.IEmulator.cs
index e5163372c3..03f6b0824b 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sega/gpgx/GPGX.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sega/gpgx/GPGX.IEmulator.cs
@@ -9,7 +9,7 @@ namespace BizHawk.Emulation.Cores.Consoles.Sega.gpgx
public ControllerDefinition ControllerDefinition { get; private set; }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
// TODO: use render and rendersound
public void FrameAdvance(bool render, bool rendersound = true)
diff --git a/BizHawk.Emulation.Cores/Consoles/Sega/gpgx64/GPGX.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Sega/gpgx64/GPGX.IEmulator.cs
index b62423e328..96d1e37944 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sega/gpgx64/GPGX.IEmulator.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sega/gpgx64/GPGX.IEmulator.cs
@@ -9,7 +9,7 @@ namespace BizHawk.Emulation.Cores.Consoles.Sega.gpgx64
public ControllerDefinition ControllerDefinition { get; private set; }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
// TODO: use render and rendersound
public void FrameAdvance(bool render, bool rendersound = true)
diff --git a/BizHawk.Emulation.Cores/Consoles/Sony/PSP/PSP.cs b/BizHawk.Emulation.Cores/Consoles/Sony/PSP/PSP.cs
index c7cd9507b2..18b39b5eb3 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sony/PSP/PSP.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sony/PSP/PSP.cs
@@ -39,7 +39,7 @@ namespace BizHawk.Emulation.Cores.Sony.PSP
};
public ControllerDefinition ControllerDefinition { get { return PSPController; } }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public bool DeterministicEmulation { get { return true; } }
public string SystemId { get { return "PSP"; } }
public CoreComm CoreComm { get; private set; }
diff --git a/BizHawk.Emulation.Cores/Consoles/Sony/PSX/Octoshock.cs b/BizHawk.Emulation.Cores/Consoles/Sony/PSX/Octoshock.cs
index 8a701a7aa9..7b8d65e8b7 100644
--- a/BizHawk.Emulation.Cores/Consoles/Sony/PSX/Octoshock.cs
+++ b/BizHawk.Emulation.Cores/Consoles/Sony/PSX/Octoshock.cs
@@ -819,7 +819,7 @@ namespace BizHawk.Emulation.Cores.Sony.PSX
}
public ControllerDefinition ControllerDefinition { get; private set; }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
public int Frame { get; private set; }
public int LagCount { get; set; }
diff --git a/BizHawk.Emulation.Cores/Consoles/WonderSwan/WonderSwan.Controller.cs b/BizHawk.Emulation.Cores/Consoles/WonderSwan/WonderSwan.Controller.cs
index 715bd5b9a1..1a8bcec7b5 100644
--- a/BizHawk.Emulation.Cores/Consoles/WonderSwan/WonderSwan.Controller.cs
+++ b/BizHawk.Emulation.Cores/Consoles/WonderSwan/WonderSwan.Controller.cs
@@ -37,12 +37,12 @@ namespace BizHawk.Emulation.Cores.WonderSwan
"P2 B",
"P2 A",
- "Power",
+ "Power",
"Rotate"
}
};
public ControllerDefinition ControllerDefinition { get { return WonderSwanController; } }
- public IController Controller { get; set; }
+ public IController Controller { private get; set; }
BizSwan.Buttons GetButtons()
{