Group Search

Group Searches are used when you know that several values are in the same region of memory, but you don’t know their order, or if you know their order but don’t know their values.

 

I Know the Values are Close Together

There are two sets of options to use if you know the values but don’t know how close they are together.

In this case, you must specify the group size and enter the values that are to be found within that range. The following chart explains the options related to this type of search. A group is a series of bytes that are to be checked for containing the specified elements.

Option

Meaning

Total Group Elements Total size of the group, in elements. For example, if you search for ints and set the Total Group Elements to 3, the total bytes in the group is 12, or 4 × 3. See below for details on how this is used during the actual search.
Values to Find Each value to find within the group, where each value is separated by a space and is of the type specified in Treat Elements in List as. Values may appear more than once in the list. Each value is an element.
Ordered If you know the order of the elements, set this option. The order of the values in the groups will match the order of the elements listed in Values to Find. This can not be used with Count Elements.
Count Elements

Use this to indicate that the elements in Values to Find are to appear in the group the same number of times as they appear in Values to Find. For example, if Values to Find contains the number 13 two times, the groups returned in the search will also contain 13 two times—no more and no fewer.

This can not be used with Ordered because order is ignored when counting.

Treat Elements in List as Each element in Values to Find is of this type. For an explanation of each data type, see Data Types.
List is in Hex Each element in Values to Find is in hexadecimal form.

Total Group Elements indicates the number of elements in the group. If each element is of type short and there are 5 elements, the group size is 2 × 5, or 10. The scanner will then buffer sets of 10 bytes (a group) and check to see if they match the specified criteria, adding them to the Found Addresses list if they match. If a group (set of 10 bytes in this case) matches the specified criteria, it means all values listed in Values to Find are inside that set of 10 bytes.

For example, if we search using the criteria specified in the picture above, with Total Group Elements set to 5 and a Values to Find of 45, 56, and 12, each as bytes, we may get the following list of returns:

In each group of 5 bytes, we can find 45, 56, and 12. Because of the options used, these bytes can appear in any order and any number of times, as shown above.

 

I Know the Order of the Values, but not the Values

Sometimes you can see a pattern in the game but not know the values of the data used to represent the pattern. This raises need for a special type of Group Search called the Relative List Order search, sometimes called the USD search.

It gets the name USD from the values you must enter into the Values to Find. The following chart explains their meanings. Letters are not case-sensitive

Letter Meaning Description
U Unknown The element in the list is unknown.
S Same The element in the list is the same as the previous element.
D Different The element in the list is different from the previous element.

Each letter in Values to Find is an element of the type specified in Treat Elements in List as. Each element is based off the element before it in the list, except for unknown elements. Because of this, the list must begin with a U.

Using the above picture and searching for lists of bytes with the USD string ussdssdds, we may get the following return.

The first value is unknown. The next value is the same as that value, and so is the next. The next value is different from the previous, but the following two values are the same as it. The next value is different, and the next value is different again, followed at last by a value that is the same as it.

 

But How is This Useful?

It depends on your needs and interests. USD searches are important in various types of game-resource hacking. If you wanted to make extremely accurate maps for Super Mario World, you can use USD searches to get the tile information used to make each map in the game. Remember, not all hacking is meant to hurt others.

But resource hacking isn’t the only use for USD searches. An example that appeals to a larger range of people is the idea of hacking grid-based games, such as Tetrinet 2. Using USD searches is an easy way to find the board data—use the colors of the blocks to create a list order. Once you have found the board in RAM, you can make online bots play your game for you, using MHS’s scripting capabilities.

 

Common Options

Option Description
Search Every Four Bytes Searches starting on every four bytes instead of every byte. This does not change how it checks elements inside a group. Improves speed but may fail to return some results.
From Specifies the starting address from which to search.
To Specifies the ending address at which to stop searching (exclusive).

 

Additional Notes

The search itself always starts at the lower address and goes to the higher address, regardless of the order in which they are entered.

All search data entered into the dialog is saved if you click OK and perform a search, which allows you to repeat searches without having to fill out every box again.

Only if you perform a search will the previous results be lost.

Relative List-Order searches allow Sub Searching. See Sub Search.

 

Tips

  • USD searches are useful for finding any kind of tile-based information in games, including textures, bitmaps, and map data.
  • Finding game resources can be useful for extracting data to be used in your own personal projects. Such projects may include making maps or converting textures to be used in mods.
  • Finding tile-based map information can be useful for making bots.
  • Group Search can be used to find your player class more quickly by allowing you to specify your health, armor, ammo, etc., all at once inside the group.
Copyright © 2006 Shawn (L. Spiro) Wilcoxen