Jump to content
  • 0

Edit only last result


Guest OnlyGodForgives

Question

Guest OnlyGodForgives

I need help, I have already looked everywhere but there is nothing that suited my problem.

There are more "0" values in the search, I am only interested in changing the last one:

function radar()
	local ret = gg.alert('Are you in the lobby?', 'YES', 'NO')
	if ret == 2 then impmenu() end
	if ret == 1 then 
gg.alert("Press on GG icon when 5 second countdown")
while(true)do
if gg.isVisible(true) then	
gg.setVisible(false)
gg.clearResults()
gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber("43;9;9;0~0::30", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1, 0)
gg.refineNumber("0", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1, 0)
local table = gg.getResults(100)
for i = 1, #table do
	table[i]["value"] = 1
	table[i]["freeze"] = true
	table[i]["freezeType"] = gg.FREEZE_NORMAL
end
gg.setValues(table)
gg.addListItems(table)
gg.toast('Done!')
Minimize()
end
end
end
end

Can someone please help me?

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Use offset edit. 

If the 0 you want to edit is at offset C from 43,I'll write like below

gg.searchNumber("43;9;9;0::30", 4) --4 is Dword
gg.refineNumber("43",4)
local table = gg.getResults(100)
for i,v in ipair(table) do
  table[i].address = table[i].address+0xc
  table[i].flags = 4 --must use value type
  table[i].value = 1
  table[i].freeze = true --if u dont put freezetype gg will use normal freeze automatically
end
gg.setValues(table)
gg.addListItems(table)

If this dont work let me know

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.