OraOraOra Posted May 27, 2020 Share Posted May 27, 2020 I need help Example i search value : 1;2;3;4::14 value show : 1;2;3;4 i want to edit : 1 to 10, 2 to 20, 3 to 30, 4 to 40. simultaneously How i write command in the script? Link to comment Share on other sites More sharing options...
HEROGAMEOfficial Posted May 27, 2020 Share Posted May 27, 2020 55 minutes ago, OraOraOra said: I need help Example i search value : 1;2;3;4::14 value show : 1;2;3;4 i want to edit : 1 to 10, 2 to 20, 3 to 30, 4 to 40. simultaneously How i write command in the script? a = gg.searchNumber("1;2;3;4::14", gg.TYPE_DWORD) a = gg.getResults(gg.getResultsCount()) b = gg.refineNumber("1", gg.TYPE_DOWRD) gg.getResults(gg.getResultsCount()) gg.editAll(10, gg.TYPE_DWORD) gg.clearResults() gg.loadResults(a) b = gg.refineNumber("2", gg.TYPE_DOWRD) gg.getResults(gg.getResultsCount()) gg.editAll(20, gg.TYPE_DWORD) gg.clearResults() gg.loadResults(a) b = gg.refineNumber("3", gg.TYPE_DOWRD) gg.getResults(gg.getResultsCount()) gg.editAll(30, gg.TYPE_DWORD) gg.clearResults() gg.loadResults(a) b = gg.refineNumber("4", gg.TYPE_DOWRD) gg.getResults(gg.getResultsCount()) gg.editAll(40, gg.TYPE_DWORD) gg.clearResults() Link to comment Share on other sites More sharing options...
El_dorado Posted May 27, 2020 Share Posted May 27, 2020 1 hour ago, OraOraOra said: I need help Example i search value : 1;2;3;4::14 value show : 1;2;3;4 i want to edit : 1 to 10, 2 to 20, 3 to 30, 4 to 40. simultaneously How i write command in the script? gg.searchNumber("1;2;3;4::14", 4) local t = gg.getResults(10) for i,v in ipairs(t) do local value = v.value if value == 1 then v.flags = 4 v.value = 10 end if value == 2 then v.flags = 4 v.value = 20 end if value == 3 then v.flags = 4 v.value = 30 end if value == 4 then v.flags = 4 v.value = 40 end Link to comment Share on other sites More sharing options...
OraOraOra Posted May 27, 2020 Author Share Posted May 27, 2020 Thx you all Link to comment Share on other sites More sharing options...
ItsSC Posted May 27, 2020 Share Posted May 27, 2020 10 minutes ago, El_dorado said: gg.searchNumber("1;2;3;4::14", 4) local t = gg.getResults(10) for i,v in ipairs(t) do local value = v.value if value == 1 then v.flags = 4 v.value = 10 end if value == 2 then v.flags = 4 v.value = 20 end if value == 3 then v.flags = 4 v.value = 30 end if value == 4 then v.flags = 4 v.value = 40 end Use pairs instead of ipairs. Link to comment Share on other sites More sharing options...
El_dorado Posted May 27, 2020 Share Posted May 27, 2020 5 minutes ago, ItsSC said: Use pairs instead of ipairs. Alright boss Link to comment Share on other sites More sharing options...
Question
OraOraOra
I need help
Example i search value : 1;2;3;4::14
value show : 1;2;3;4
i want to edit :
1 to 10, 2 to 20, 3 to 30, 4 to 40. simultaneously
How i write command in the script?
Link to comment
Share on other sites
5 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.