Jump to content
  • 0

How to search continously. if one not found, search another one


Lover1500

Question

I am trying to make a script with user input prompt

 

I could hack the game but to search it with group search is sometimes failed

 

The around addresses are changed whenever I reenter.

I noticed it changed into only three numbers.

What I want to is my script will search one

if not found?Try another one.

I have trouble with this.I dont know how to write in script and whats wrong in my script.

Help me plz.

 

local var = input[1]..";3485744::"

local var2 = input[1]..";30303006h::"

local var3 = input[1]..";32303006h::"

gg.searchNumber(var, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

if gg.getResultsCount == "0" then

gg.searchNumber(var2, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

if gg.getResultsCount == "0" then

gg.searchNumber(var3, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD)

end

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD)

end

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD)

end

 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

6 hours ago, Lover1500 said:

local var = input[1]..";3485744::"

local var2 = input[1]..";30303006h::"

local var3 = input[1]..";32303006h::"

gg.searchNumber(var, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

if gg.getResultsCount ~=0 then

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD) else

gg.searchNumber(var2, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1) end

if gg.getResultsCount ~= "0" then

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD) else

gg.searchNumber(var3, gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

gg.refineNumber(input[1])

gg.getResults("1")

gg.editAll("0", gg.TYPE_DWORD)

end

 

 

Link to comment
Share on other sites

local var = input[1]..";3485744::"
local var2 = input[1]..";30303006h::"
local var3 = input[1]..";32303006h::"
	gg.searchNumber(var,gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)

if gg.getResultsCount()==0 then
    gg.searchNumber(var2,gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)
	    if gg.getResultsCount() == 0 then
        gg.searchNumber(var3,gg.TYPE_DWORD,false,gg.SIGN_EQUAL, 0, -1)
        gg.refineNumber(tonumber(input[1]))
        gg.getResults(1)
        gg.editAll(0,gg.TYPE_DWORD)
    end
	    gg.refineNumber(tonumber(input[1]))
    gg.getResults(1)
    gg.editAll(0,gg.TYPE_DWORD)
	end
	gg.refineNumber(tonumber(input[1]))
gg.getResults(1)
gg.editAll(0,gg.TYPE_DWORD)
	end -- end what?
	
user input values are strings 
"1" is a string
1 is a number
gg.getResultsCount() not gg.getResultsCount
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.