hello,i wanna to ask How to write script to select freeze_in_range type data in saved list, and change them to a faourite value?
I've been learning a lot from here for a long time, but I didn't solve this problem. Manual change them one by one is very complicated. (the game will reduce it, but i don't want it to become "0" or to be freezed, so i set it freeze_in_range).
For example, there are 18 saved values, 6 of them are freeze in range. It's easy to find them, but it's very tiring to change them once in two minutes.
I tried gg.getListItems () , but it couldn't be selected and change, unlike gg.getResults().
This is a part of my script:
gg.clearResults()
if gg.isVisible() then gg.setVisible(false) end
A1 = 17341
A2 = 13552
B1 = 13716
B2 = 14304
C1 = 14226 ~~~~~~
gg.searchNumber(A1..';'..A2..'', gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
if gg.getResultCount() == 0 then
gg.searchNumber(A1..';'..A2..'', gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
if gg.getResultCount() == 0 then
gg.setVisible(true)
end
else
gg.toast('searching correct')
end
t=gg.getResults(3)
t[1].value = A2
t[1].freeze = true
t[2].value = A1
t[2].freeze = true
t[2].freezeType = gg.FREEZE_IN_RANGE
t[2].freezeFrom = '1'
t[2].freezeTo = A1
t[3].value = A1
t[3].freeze = true
print('addListItems: ', gg.addListItems(t))
gg.clearResults()
gg.searchNumber(B1..';'..B2..'', gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1)
~~~~~~~~~~~~~~~~
::loop::
(waiting for help,Thanks a lot)
go to loop