diff --git a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.Designer.cs b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.Designer.cs
index 712ddfe9cb..d81a1f71be 100644
--- a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.Designer.cs
+++ b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.Designer.cs
@@ -156,6 +156,7 @@
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.DisplayTypeDropdown = new System.Windows.Forms.ComboBox();
+ this.AutoSearchAccountForLagMenuItem = new System.Windows.Forms.ToolStripMenuItem();
SearchMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.ListViewContextMenu.SuspendLayout();
this.RamSearchMenu.SuspendLayout();
@@ -350,7 +351,7 @@
this.ClearPreviewContextMenuItem.Text = "&Clear Preview";
this.ClearPreviewContextMenuItem.Click += new System.EventHandler(this.ClearPreviewContextMenuItem_Click);
//
- // menuStrip1
+ // RamSearchMenu
//
this.RamSearchMenu.ClickThrough = true;
this.RamSearchMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
@@ -359,7 +360,7 @@
this.searchToolStripMenuItem,
this.optionsToolStripMenuItem});
this.RamSearchMenu.Location = new System.Drawing.Point(0, 0);
- this.RamSearchMenu.Name = "menuStrip1";
+ this.RamSearchMenu.Name = "RamSearchMenu";
this.RamSearchMenu.Size = new System.Drawing.Size(445, 24);
this.RamSearchMenu.TabIndex = 4;
this.RamSearchMenu.Text = "menuStrip1";
@@ -745,6 +746,7 @@
this.optionsToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.PreviewModeMenuItem,
this.AutoSearchMenuItem,
+ this.AutoSearchAccountForLagMenuItem,
this.toolStripSeparator9,
this.ExcludeRamWatchMenuItem,
this.UseUndoHistoryMenuItem,
@@ -1361,6 +1363,13 @@
this.DisplayTypeDropdown.TabIndex = 95;
this.DisplayTypeDropdown.SelectedIndexChanged += new System.EventHandler(this.DisplayTypeDropdown_SelectedIndexChanged);
//
+ // AutoSearchAccountForLagMenuItem
+ //
+ this.AutoSearchAccountForLagMenuItem.Name = "AutoSearchAccountForLagMenuItem";
+ this.AutoSearchAccountForLagMenuItem.Size = new System.Drawing.Size(240, 22);
+ this.AutoSearchAccountForLagMenuItem.Text = "&Auto-Search Account for Lag";
+ this.AutoSearchAccountForLagMenuItem.Click += new System.EventHandler(this.AutoSearchAccountForLagMenuItem_Click);
+ //
// RamSearch
//
this.AllowDrop = true;
@@ -1532,5 +1541,6 @@
private System.Windows.Forms.ToolStripMenuItem FloatingWindowMenuItem;
private System.Windows.Forms.ToolStripButton ErrorIconButton;
private System.Windows.Forms.ToolStripMenuItem Previous_LastChangeMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem AutoSearchAccountForLagMenuItem;
}
}
\ No newline at end of file
diff --git a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs
index 65256b1c90..d08fb3c678 100644
--- a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs
+++ b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs
@@ -70,6 +70,9 @@ namespace BizHawk.Client.EmuHawk
[RequiredService]
public IEmulator Emu { get; set; }
+ [RequiredService]
+ public IInputPollable InputPollableCore { get; set; }
+
[ConfigPersist]
public RamSearchSettings Settings { get; set; }
@@ -267,7 +270,14 @@ namespace BizHawk.Client.EmuHawk
if (_autoSearch)
{
- DoSearch();
+ if (Settings.AutoSearchTakeLagFramesIntoAccount && InputPollableCore.IsLagFrame)
+ {
+ // Do nothing
+ }
+ else
+ {
+ DoSearch();
+ }
}
_forcePreviewClear = false;
@@ -931,11 +941,13 @@ namespace BizHawk.Client.EmuHawk
PreviewMode = true;
RecentSearches = new RecentFiles(8);
+ AutoSearchTakeLagFramesIntoAccount = true;
}
public ColumnList Columns { get; set; }
public bool PreviewMode { get; set; }
public bool AlwaysExcludeRamWatch { get; set; }
+ public bool AutoSearchTakeLagFramesIntoAccount { get; set; }
public RecentFiles RecentSearches { get; set; }
}
@@ -1271,6 +1283,7 @@ namespace BizHawk.Client.EmuHawk
AlwaysOnTopMenuItem.Checked = Settings.TopMost;
FloatingWindowMenuItem.Checked = Settings.FloatingWindow;
AutoSearchMenuItem.Checked = _autoSearch;
+ AutoSearchAccountForLagMenuItem.Checked = Settings.AutoSearchTakeLagFramesIntoAccount;
}
private void PreviewModeMenuItem_Click(object sender, EventArgs e)
@@ -1287,6 +1300,11 @@ namespace BizHawk.Client.EmuHawk
!_autoSearch;
}
+ private void AutoSearchAccountForLagMenuItem_Click(object sender, EventArgs e)
+ {
+ Settings.AutoSearchTakeLagFramesIntoAccount ^= true;
+ }
+
private void ExcludeRamWatchMenuItem_Click(object sender, EventArgs e)
{
Settings.AlwaysExcludeRamWatch ^= true;
diff --git a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.resx b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.resx
index acb812c494..99f4bc1a57 100644
--- a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.resx
+++ b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.resx
@@ -121,16 +121,16 @@
False
- 457, 17
+ 161, 17
-
- 150, 17
+
+ 17, 17
- 602, 17
+ 331, 17
- 699, 17
+ 428, 17