Remove autofire from IController & inherited objects other than Controller
This commit is contained in:
parent
9b2ba5c85c
commit
d10f38af5d
|
@ -63,8 +63,6 @@ namespace BizHawk
|
||||||
writer.Seek(frame * 2, SeekOrigin.Begin);
|
writer.Seek(frame * 2, SeekOrigin.Begin);
|
||||||
writer.Write((ushort)encodedValue);
|
writer.Write((ushort)encodedValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public class InputPlayback : IController
|
public class InputPlayback : IController
|
||||||
|
@ -123,7 +121,5 @@ namespace BizHawk
|
||||||
public bool IsSticky(string button) { return false; }
|
public bool IsSticky(string button) { return false; }
|
||||||
|
|
||||||
public bool MovieEnded { get { return frame >= input.Length; } }
|
public bool MovieEnded { get { return frame >= input.Length; } }
|
||||||
|
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -15,6 +15,5 @@
|
||||||
|
|
||||||
private static NullController nullController = new NullController();
|
private static NullController nullController = new NullController();
|
||||||
public static NullController GetNullController() { return nullController; }
|
public static NullController GetNullController() { return nullController; }
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -22,8 +22,5 @@ namespace BizHawk
|
||||||
|
|
||||||
//TODO - why does this have a frame argument. must be removed.
|
//TODO - why does this have a frame argument. must be removed.
|
||||||
void UpdateControls(int frame);
|
void UpdateControls(int frame);
|
||||||
|
|
||||||
//Flag for whether the controller will behave like a autofire (rapid fire) controller
|
|
||||||
bool Autofire { get; set; }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,6 @@ namespace BizHawk.MultiClient
|
||||||
public class ClickyVirtualPadController : IController
|
public class ClickyVirtualPadController : IController
|
||||||
{
|
{
|
||||||
public ControllerDefinition Type { get; set; }
|
public ControllerDefinition Type { get; set; }
|
||||||
public bool Autofire { get { return false; } set { } } //TODO: do we want virtualpad autofire pads?
|
|
||||||
public bool this[string button] { get { return IsPressed(button); } }
|
public bool this[string button] { get { return IsPressed(button); } }
|
||||||
public float GetFloat(string name) { return 0.0f; } //TODO
|
public float GetFloat(string name) { return 0.0f; } //TODO
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
|
@ -49,7 +48,7 @@ namespace BizHawk.MultiClient
|
||||||
public bool this[string button] { get { return IsPressed(button); } }
|
public bool this[string button] { get { return IsPressed(button); } }
|
||||||
public float GetFloat(string name) { return 0.0f; } //TODO
|
public float GetFloat(string name) { return 0.0f; } //TODO
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
public bool IsPressed(string button)
|
public bool IsPressed(string button)
|
||||||
{
|
{
|
||||||
if (Global.Config.AllowUD_LR == true)
|
if (Global.Config.AllowUD_LR == true)
|
||||||
|
@ -83,7 +82,7 @@ namespace BizHawk.MultiClient
|
||||||
public virtual bool IsPressed(string button) { return this[button]; }
|
public virtual bool IsPressed(string button) { return this[button]; }
|
||||||
public float GetFloat(string name) { return 0.0f; } //TODO
|
public float GetFloat(string name) { return 0.0f; } //TODO
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
public virtual void LatchFrom(IController source)
|
public virtual void LatchFrom(IController source)
|
||||||
{
|
{
|
||||||
foreach (string button in source.Type.BoolButtons)
|
foreach (string button in source.Type.BoolButtons)
|
||||||
|
@ -98,7 +97,6 @@ namespace BizHawk.MultiClient
|
||||||
public bool IsPressed(string button) { return this[button]; }
|
public bool IsPressed(string button) { return this[button]; }
|
||||||
public float GetFloat(string name) { return 0.0f; } //TODO
|
public float GetFloat(string name) { return 0.0f; } //TODO
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
public bool Autofire { get { return false; } set { } } //TODO: sticky autofire buttons?
|
|
||||||
|
|
||||||
public IController Source;
|
public IController Source;
|
||||||
public IController SourceOr;
|
public IController SourceOr;
|
||||||
|
@ -126,7 +124,7 @@ namespace BizHawk.MultiClient
|
||||||
public bool IsPressed(string button) { return this[button]; }
|
public bool IsPressed(string button) { return this[button]; }
|
||||||
public float GetFloat(string name) { return 0.0f; } //TODO
|
public float GetFloat(string name) { return 0.0f; } //TODO
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
public bool Autofire { get { return false; } set { } } //TODO: sticky autofire buttons?
|
|
||||||
public bool this[string button] {
|
public bool this[string button] {
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
|
@ -330,7 +328,7 @@ namespace BizHawk.MultiClient
|
||||||
else return Source;
|
else return Source;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
public ControllerDefinition Type { get { return Curr.Type; } }
|
public ControllerDefinition Type { get { return Curr.Type; } }
|
||||||
public bool this[string button] { get { return Curr[button]; } }
|
public bool this[string button] { get { return Curr[button]; } }
|
||||||
public bool IsPressed(string button) { return Curr.IsPressed(button); }
|
public bool IsPressed(string button) { return Curr.IsPressed(button); }
|
||||||
|
@ -381,7 +379,7 @@ namespace BizHawk.MultiClient
|
||||||
public bool this[string button] { get { return this.IsPressed(button); } }
|
public bool this[string button] { get { return this.IsPressed(button); } }
|
||||||
public float GetFloat(string name) { return Source.GetFloat(name); }
|
public float GetFloat(string name) { return Source.GetFloat(name); }
|
||||||
public void UpdateControls(int frame) { Source.UpdateControls(frame); }
|
public void UpdateControls(int frame) { Source.UpdateControls(frame); }
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
public bool IsPressed(string button)
|
public bool IsPressed(string button)
|
||||||
{
|
{
|
||||||
//do we even have a source?
|
//do we even have a source?
|
||||||
|
@ -414,7 +412,6 @@ namespace BizHawk.MultiClient
|
||||||
public bool IsPressed(string button) { return MyBoolButtons[button]; }
|
public bool IsPressed(string button) { return MyBoolButtons[button]; }
|
||||||
public float GetFloat(string name) { return 0; }
|
public float GetFloat(string name) { return 0; }
|
||||||
public void UpdateControls(int frame) { }
|
public void UpdateControls(int frame) { }
|
||||||
public bool Autofire { get { return false; } set { } }
|
|
||||||
//--------
|
//--------
|
||||||
|
|
||||||
WorkingDictionary<string, bool> MyBoolButtons = new WorkingDictionary<string, bool>();
|
WorkingDictionary<string, bool> MyBoolButtons = new WorkingDictionary<string, bool>();
|
||||||
|
|
Loading…
Reference in New Issue