/[RomCheater]/trunk/RomCheater/Docking/FloatingMemorySearcher.cs
ViewVC logotype

Diff of /trunk/RomCheater/Docking/FloatingMemorySearcher.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 388 by william, Tue Jun 19 11:59:13 2012 UTC revision 389 by william, Tue Jun 19 12:47:26 2012 UTC
# Line 1  Line 1 
1  //#define USE_AUTOMATIC_MEMORY_SEARCH_RANGE // when defined will automatically choose the best starting address and size for memory search otherwise it will use the constants defined in MemorySizeConstants  #define USE_AUTOMATIC_MEMORY_SEARCH_RANGE // when defined will automatically choose the best starting address and size for memory search otherwise it will use the constants defined in MemorySizeConstants
2  #if !USE_AUTOMATIC_MEMORY_SEARCH_RANGE  #if !USE_AUTOMATIC_MEMORY_SEARCH_RANGE
3  #define FORCE_USE_OF_MEMORYSIZECONSTANTS // when defined wil force the use of the constants defined in MemorySizeConstants for memory search range  #define FORCE_USE_OF_MEMORYSIZECONSTANTS // when defined wil force the use of the constants defined in MemorySizeConstants for memory search range
4  #endif  #endif
# Line 63  namespace RomCheater.Docking Line 63  namespace RomCheater.Docking
63          {          {
64              this.lstResults.AcceptedPlugin = config;              this.lstResults.AcceptedPlugin = config;
65              this.lstPatchList.AcceptedPlugin = config;              this.lstPatchList.AcceptedPlugin = config;
66                if (config != null)
67                {
68                    MemoryRangeStart = AcceptedPlugin.MemoryRangeStart;
69                    MemoryRangeSize = AcceptedPlugin.MemoryRangeStart + AcceptedPlugin.MemoryRangeSize;
70                }
71          }          }
72          private void UpdateAcceptedProcess(Process process)          private void UpdateAcceptedProcess(Process process)
73          {                      {            
# Line 88  namespace RomCheater.Docking Line 93  namespace RomCheater.Docking
93              //}              //}
94              //else              //else
95              //{              //{
96              txtMemoryRangeStart.Value = MemorySizeConstants.MinimumSearchAddress;              //txtMemoryRangeStart.Value = MemorySizeConstants.MinimumSearchAddress;
97              txtMemoryRangeSize.Value = (MemorySizeConstants.MinimumSearchAddress > 0) ? (uint)(MemorySizeConstants.MaximumSearchAddress - MemorySizeConstants.MinimumSearchAddress) : MemorySizeConstants.MaximumSearchAddress;              //txtMemoryRangeSize.Value = MemorySizeConstants.MinimumSearchAddress + MemorySizeConstants.MaximumSearchSize;
98              //}              //}
99                if (AcceptedPlugin != null)
100                {
101                    MemoryRangeStart = AcceptedPlugin.MemoryRangeStart;
102                    MemoryRangeSize = AcceptedPlugin.MemoryRangeStart + AcceptedPlugin.MemoryRangeSize;
103                }
104    
105  #endif  #endif
106    
107          }          }
# Line 100  namespace RomCheater.Docking Line 111  namespace RomCheater.Docking
111    
112          #region IAcceptsMemoryRange          #region IAcceptsMemoryRange
113  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS
114          private int _MemoryRangeStart;          private uint _MemoryRangeStart;
115          private uint _MemoryRangeSize;          private uint _MemoryRangeSize;
116  #endif  #endif
117          public uint MemoryRangeStart          public uint MemoryRangeStart
# Line 117  namespace RomCheater.Docking Line 128  namespace RomCheater.Docking
128              {              {
129  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS
130                  _MemoryRangeStart = value;                  _MemoryRangeStart = value;
131                    txtMemoryRangeStart.Value = value;
132  #endif  #endif
133              }              }
134          }                  }        
# Line 134  namespace RomCheater.Docking Line 146  namespace RomCheater.Docking
146              {              {
147  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS  #if !FORCE_USE_OF_MEMORYSIZECONSTANTS
148                  _MemoryRangeSize = value;                  _MemoryRangeSize = value;
149                    txtMemoryRangeSize.Value = value;
150  #endif  #endif
151              }              }
152          }          }

Legend:
Removed from v.388  
changed lines
  Added in v.389

  ViewVC Help
Powered by ViewVC 1.1.22