Jump to content
  • 0

pointer search not finding all addresses


nok1a
 Share

Question

Pointersearch does not show the address in region Cb, it's only showing those in Ca. If i do it manually it finds the address is Cb. Why?

  gg.clearResults()
  gg.setRanges(gg.REGION_ANONYMOUS | gg.REGION_C_ALLOC | gg.REGION_OTHER)
  gg.searchNumber("h 00 00 80 3F CD CC 4C 3E 00 00 00 41 00 00 C8 42 00 00 B4 43 0A D7 23 3C CD CC 4C 3E 00 00 40 3F 00 00 00")
  if gg.getResultsCount() == 0 then
    gg.alert("Search not found, Use Fuzzy or Xa")
    start()
  else
    gg.refineNumber("h 00 00 80 3F", gg.TYPE_FLOAT)
    local a = gg.getResults(gg.getResultsCount())
    local fakeSpeedPointers = {}
    for i, v in ipairs(a) do
      v.flags = gg.TYPE_FLOAT
    end
    a = gg.getValues(a)
    for i, v in ipairs(a) do
      if v.value == 1 then
        fakeSpeedPointers[#fakeSpeedPointers + 1] = {address = v.address - anonGroupSearchOffset, flags = gg.TYPE_FLOAT}
        fakeSpeedPointers[#fakeSpeedPointers + 1] = {address = v.address - 0x48, flags = gg.TYPE_FLOAT}
        fakeSpeedPointers[#fakeSpeedPointers + 1] = {address = v.address - 0x44, flags = gg.TYPE_FLOAT}
      end
    end
    gg.loadResults(fakeSpeedPointers)
    gg.setRanges(gg.REGION_C_BSS | gg.REGION_OTHER | gg.REGION_ANONYMOUS | gg.REGION_C_ALLOC)
    gg.searchPointer(0) -- manually = Ca (3 results), Cb (1 result)  | script = Ca (3 results), Cb (0 results)

 

Edited by nok1a
typo
Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0
2 hours ago, CmP said:

Try setting new ranges before the call to "loadResults" function.

Works. Any reason why it not search the ranges after loadResults ?

Link to comment
Share on other sites

  • 0
1 hour ago, nok1a said:

Any reason why it not search the ranges after loadResults ?

Only because it has been implemented like that. This is something that could be improved/fixed from GG side, pointer search needs to use search ranges that are set when pointer search is invoked instead of ranges that are set when results list is populated first time after being cleared (loading results works by clearing results list and then adding new ones). In other words, pointer search needs to work like new search, but currently it works like refine search.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.