Autofire Config - Add flag for the "Take lag frames into account" feature, true by default
This commit is contained in:
parent
aba919874d
commit
4ef00921e9
|
@ -129,6 +129,7 @@
|
||||||
public bool BackupSavestates = true;
|
public bool BackupSavestates = true;
|
||||||
public int AutofireOn = 1;
|
public int AutofireOn = 1;
|
||||||
public int AutofireOff = 1;
|
public int AutofireOff = 1;
|
||||||
|
public bool AutofireLagFrames = true;
|
||||||
|
|
||||||
// Run-Control settings
|
// Run-Control settings
|
||||||
public int FrameProgressDelayMs = 500; //how long until a frame advance hold turns into a frame progress?
|
public int FrameProgressDelayMs = 500; //how long until a frame advance hold turns into a frame progress?
|
||||||
|
|
|
@ -1643,7 +1643,7 @@ namespace BizHawk.MultiClient
|
||||||
|
|
||||||
UpdateTools();
|
UpdateTools();
|
||||||
|
|
||||||
if (Global.Emulator.IsLagFrame)
|
if (Global.Emulator.IsLagFrame && Global.Config.AutofireLagFrames)
|
||||||
{
|
{
|
||||||
Global.AutoFireController.IncrementStarts();
|
Global.AutoFireController.IncrementStarts();
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,7 @@
|
||||||
this.label1 = new System.Windows.Forms.Label();
|
this.label1 = new System.Windows.Forms.Label();
|
||||||
this.label2 = new System.Windows.Forms.Label();
|
this.label2 = new System.Windows.Forms.Label();
|
||||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||||
|
this.LagFrameCheck = new System.Windows.Forms.CheckBox();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.OnNumeric)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.OnNumeric)).BeginInit();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.OffNumeric)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.OffNumeric)).BeginInit();
|
||||||
this.groupBox1.SuspendLayout();
|
this.groupBox1.SuspendLayout();
|
||||||
|
@ -44,7 +45,7 @@
|
||||||
// Ok
|
// Ok
|
||||||
//
|
//
|
||||||
this.Ok.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
this.Ok.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
this.Ok.Location = new System.Drawing.Point(42, 117);
|
this.Ok.Location = new System.Drawing.Point(120, 148);
|
||||||
this.Ok.Name = "Ok";
|
this.Ok.Name = "Ok";
|
||||||
this.Ok.Size = new System.Drawing.Size(75, 23);
|
this.Ok.Size = new System.Drawing.Size(75, 23);
|
||||||
this.Ok.TabIndex = 5;
|
this.Ok.TabIndex = 5;
|
||||||
|
@ -56,7 +57,7 @@
|
||||||
//
|
//
|
||||||
this.Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
this.Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
this.Cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
this.Cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||||
this.Cancel.Location = new System.Drawing.Point(123, 117);
|
this.Cancel.Location = new System.Drawing.Point(201, 148);
|
||||||
this.Cancel.Name = "Cancel";
|
this.Cancel.Name = "Cancel";
|
||||||
this.Cancel.Size = new System.Drawing.Size(75, 23);
|
this.Cancel.Size = new System.Drawing.Size(75, 23);
|
||||||
this.Cancel.TabIndex = 7;
|
this.Cancel.TabIndex = 7;
|
||||||
|
@ -139,13 +140,24 @@
|
||||||
this.groupBox1.TabStop = false;
|
this.groupBox1.TabStop = false;
|
||||||
this.groupBox1.Text = "Autofire Pattern";
|
this.groupBox1.Text = "Autofire Pattern";
|
||||||
//
|
//
|
||||||
|
// LagFrameCheck
|
||||||
|
//
|
||||||
|
this.LagFrameCheck.AutoSize = true;
|
||||||
|
this.LagFrameCheck.Location = new System.Drawing.Point(13, 100);
|
||||||
|
this.LagFrameCheck.Name = "LagFrameCheck";
|
||||||
|
this.LagFrameCheck.Size = new System.Drawing.Size(164, 17);
|
||||||
|
this.LagFrameCheck.TabIndex = 8;
|
||||||
|
this.LagFrameCheck.Text = "Take lag frames into account";
|
||||||
|
this.LagFrameCheck.UseVisualStyleBackColor = true;
|
||||||
|
//
|
||||||
// AutofireConfig
|
// AutofireConfig
|
||||||
//
|
//
|
||||||
this.AcceptButton = this.Ok;
|
this.AcceptButton = this.Ok;
|
||||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
this.CancelButton = this.Cancel;
|
this.CancelButton = this.Cancel;
|
||||||
this.ClientSize = new System.Drawing.Size(210, 152);
|
this.ClientSize = new System.Drawing.Size(288, 183);
|
||||||
|
this.Controls.Add(this.LagFrameCheck);
|
||||||
this.Controls.Add(this.groupBox1);
|
this.Controls.Add(this.groupBox1);
|
||||||
this.Controls.Add(this.Cancel);
|
this.Controls.Add(this.Cancel);
|
||||||
this.Controls.Add(this.Ok);
|
this.Controls.Add(this.Ok);
|
||||||
|
@ -161,6 +173,7 @@
|
||||||
this.groupBox1.ResumeLayout(false);
|
this.groupBox1.ResumeLayout(false);
|
||||||
this.groupBox1.PerformLayout();
|
this.groupBox1.PerformLayout();
|
||||||
this.ResumeLayout(false);
|
this.ResumeLayout(false);
|
||||||
|
this.PerformLayout();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -173,5 +186,6 @@
|
||||||
private System.Windows.Forms.Label label2;
|
private System.Windows.Forms.Label label2;
|
||||||
private System.Windows.Forms.GroupBox groupBox1;
|
private System.Windows.Forms.GroupBox groupBox1;
|
||||||
public System.Windows.Forms.NumericUpDown OnNumeric;
|
public System.Windows.Forms.NumericUpDown OnNumeric;
|
||||||
|
private System.Windows.Forms.CheckBox LagFrameCheck;
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -31,12 +31,15 @@ namespace BizHawk.MultiClient
|
||||||
OffNumeric.Value = OffNumeric.Maximum;
|
OffNumeric.Value = OffNumeric.Maximum;
|
||||||
else
|
else
|
||||||
OffNumeric.Value = Global.Config.AutofireOff;
|
OffNumeric.Value = Global.Config.AutofireOff;
|
||||||
|
|
||||||
|
LagFrameCheck.Checked = Global.Config.AutofireLagFrames;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Ok_Click(object sender, EventArgs e)
|
private void Ok_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
Global.AutoFireController.On = Global.Config.AutofireOn = (int)OnNumeric.Value;
|
Global.AutoFireController.On = Global.Config.AutofireOn = (int)OnNumeric.Value;
|
||||||
Global.AutoFireController.Off = Global.Config.AutofireOff = (int)OffNumeric.Value;
|
Global.AutoFireController.Off = Global.Config.AutofireOff = (int)OffNumeric.Value;
|
||||||
|
Global.Config.AutofireLagFrames = LagFrameCheck.Checked;
|
||||||
this.Close();
|
this.Close();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -112,12 +112,12 @@
|
||||||
<value>2.0</value>
|
<value>2.0</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="reader">
|
<resheader name="reader">
|
||||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="writer">
|
<resheader name="writer">
|
||||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||||
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
AAABAAYAAAAAAAEAIAAoIAQAZgAAAICAAAABACAAKAgBAI4gBABAQAAAAQAgAChCAAC2KAUAMDAAAAEA
|
AAABAAYAAAAAAAEAIAAoIAQAZgAAAICAAAABACAAKAgBAI4gBABAQAAAAQAgAChCAAC2KAUAMDAAAAEA
|
||||||
|
|
Loading…
Reference in New Issue