From b90e40ae5ca17f2a58ff69a81f14a9f785325930 Mon Sep 17 00:00:00 2001 From: Morilli <35152647+Morilli@users.noreply.github.com> Date: Tue, 3 Sep 2024 01:34:24 +0200 Subject: [PATCH] don't refetch current vale in MiniWatchDetails.SetPreviousToCurrent --- .../tools/RamSearchEngine/IMiniWatchDetails.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/BizHawk.Client.Common/tools/RamSearchEngine/IMiniWatchDetails.cs b/src/BizHawk.Client.Common/tools/RamSearchEngine/IMiniWatchDetails.cs index 9c5821479d..d0416a9bd6 100644 --- a/src/BizHawk.Client.Common/tools/RamSearchEngine/IMiniWatchDetails.cs +++ b/src/BizHawk.Client.Common/tools/RamSearchEngine/IMiniWatchDetails.cs @@ -20,12 +20,12 @@ namespace BizHawk.Client.Common.RamSearchEngine public MiniByteWatchDetailed(MemoryDomain domain, long addr) : base(domain, addr) { - SetPreviousToCurrent(domain, false); + _previous = _current = GetByte(Address, domain); } public override void SetPreviousToCurrent(MemoryDomain domain, bool bigEndian) { - _previous = _current = GetByte(Address, domain); + _previous = _current; } public int ChangeCount { get; private set; } @@ -59,12 +59,12 @@ namespace BizHawk.Client.Common.RamSearchEngine public MiniWordWatchDetailed(MemoryDomain domain, long addr, bool bigEndian) : base(domain, addr, bigEndian) { - SetPreviousToCurrent(domain, bigEndian); + _previous = _current = GetUshort(Address, domain, bigEndian); } public override void SetPreviousToCurrent(MemoryDomain domain, bool bigEndian) { - _previous = _current = GetUshort(Address, domain, bigEndian); + _previous = _current; } public uint Current => _current; @@ -100,12 +100,12 @@ namespace BizHawk.Client.Common.RamSearchEngine public MiniDWordWatchDetailed(MemoryDomain domain, long addr, bool bigEndian) : base(domain, addr, bigEndian) { - SetPreviousToCurrent(domain, bigEndian); + _previous = _current = GetUint(Address, domain, bigEndian); } public override void SetPreviousToCurrent(MemoryDomain domain, bool bigEndian) { - _previous = _current = GetUint(Address, domain, bigEndian); + _previous = _current; } public int ChangeCount { get; private set; }