_yourram Posted January 8 Posted January 8 (edited) [ @kiynox ] could this script be any better? function menus() choices = gg.choice({'Prepare spam','Search','Exit'}) if choices == nil then os.exit() else if choices == 3 then os.exit() else prepares(choices) end end end function prepares(choices) if choices == 1 then gg.clearResults() gg.searchNumber("9;74;8.0", gg.TYPE_FLOAT) gg.refineNumber('74', gg.TYPE_FLOAT) chatspam = gg.getResults(gg.getResultsCount()) gg.addListItems(chatspam) elseif choices == 2 then gg.loadResults(chatspam) gg.getResults(1000) chatspam = gg.prompt({"Enter which letter you want to spam?(0 = A, 1 = B, 2 = C, 3 = D, 4 = E, 5 = F, 6 = G, 7 = H, 8 = I, 9 = J, 10 = K, 11 = L, 12 = M, 13 = N, 14 = O, 15 = P, 16 = Q, 17 = R, 18 = S, 19 = T, 20 = U, 21 = V, 22 = W, 23 = X, 24 = Y, 25 = Z)"}, {[1] ="0"}, {["1"] ="number"}) if chatspam == nil then gg.alert("you haven't searched anything so the script will restart!") return end gg.editAll(chatspam[1] ,gg.TYPE_FLOAT) chatspam = gg.getResults(gg.getResultsCount()) end end knxs = false while true do if gg.isVisible(true) then knxs = true else knxs = false end if knxs == true then menus() else gg.setVisible(false) end end Edited January 8 by _yourram
0 MANDO01 Posted January 12 Posted January 12 43 minutes ago, kiynox said: [ @_yourram ] --- There's a lot of errors, but I will only explain: --Clearing results gg.clearResults() --Set memory region to Ca gg.setRanges(gg.REGION_C_ALLOC) --Search string: "nDstDist" gg.searchNumber(':nDstDist', 1) --Refining results that only contain '110' (I have no idea why) gg.refineNumber('110', 1) --Saving results as variable 'maintest' maintest = gg.getResults(6) --Clearing results gg.clearResults() --Taking address of the first result of 'maintest', then use offset -0x18 from the address. maintest2 = maintest[1].address - 0x18 --Searching address of 'maintest2' (I have no idea why) gg.searchNumber(maintest2, 32) --Saving results as variable 'results' local results = gg.getResults(19) --(A table that only contain 1, why? (I have no idea why) local resultnumber = {1} --Temporary table to store items local elements = {} --Enumerating table 'resultnumber' that only contain 1, what? (I have no idea why) for i, v in ipairs(resultnumber) do --Check if 'v' is not empty if results[v] ~= nil then --Adding table: {address = results[v].address, flags = 16,value = "-9e9"}, to table 'elements' table.insert(elements, {address = results[v].address, flags = 16,value = "-9e9"}) end end --Checking if table 'elements' has more than 0 item if #elements > 0 then --Applying changes in table 'elements' to memory gg.setValues(elements) end --- maybe his trying to make a no idea script lol 1
0 _yourram Posted January 12 Author Posted January 12 (edited) 【 @kiynox 】 --- 1 hour ago, kiynox said: --Clearing results gg.clearResults() --Set memory region to Ca gg.setRanges(gg.REGION_C_ALLOC) --Search string: "nDstDist" gg.searchNumber(':nDstDist', 1) --Refining results that only contain '110' (I have no idea why) gg.refineNumber('110', 1) --Saving results as variable 'maintest' maintest = gg.getResults(6) --Clearing results gg.clearResults() --Taking address of the first result of 'maintest', then use offset -0x18 from the address. maintest2 = maintest[1].address - 0x18 --Searching address of 'maintest2' (I have no idea why) gg.searchNumber(maintest2, 32) --Saving results as variable 'results' local results = gg.getResults(19) --(A table that only contain 1, why? (I have no idea why) local resultnumber = {1} --Temporary table to store items local elements = {} --Enumerating table 'resultnumber' that only contain 1, what? (I have no idea why) for i, v in ipairs(resultnumber) do --Check if 'v' is not empty if results[v] ~= nil then --Adding table: {address = results[v].address, flags = 16,value = "-9e9"}, to table 'elements' table.insert(elements, {address = results[v].address, flags = 16,value = "-9e9"}) end end --Checking if table 'elements' has more than 0 item if #elements > 0 then --Applying changes in table 'elements' to memory gg.setValues(elements) end thanks, I understood these commands perfectly, but I don't know what mistakes I made, can you fix it too? --- Edited January 12 by _yourram
0 _yourram Posted January 12 Author Posted January 12 【 @MANDO01 】 --- 54 minutes ago, MANDO01 said: maybe his trying to make a no idea script lol Fr lmao ---
0 kiynox Posted January 12 Posted January 12 [ @_yourram ] --- Quote thanks, I understood these commands perfectly, but I don't know what mistakes I made, can you fix it too? If you understood it, you would not say "I don't know what mistakes I made". And no, I can't help you to fix it because I don't know what you're trying to search here: ---[Fix this search yourself]--- gg.searchNumber(':nDstDist', 1) gg.refineNumber('110', 1) maintest = gg.getResults(6) gg.clearResults() maintest2 = maintest[1].address - 0x18 gg.searchNumber(maintest2, 32) ------------------------------- --- Quote can you fix it too? I can only help fixing the 'table': local results = gg.getResults(19) if results ~= nil then local elements = {} for k, v in ipairs(results) do table.insert(elements, {address = v.address, flags = 16, value = "-999"}) end gg.setValues(elements) end --- 1
0 _yourram Posted January 13 Author Posted January 13 【 @kiynox 】 --- 11 hours ago, kiynox said: I can only help fixing the 'table': local results = gg.getResults(19) if results ~= nil then local elements = {} for k, v in ipairs(results) do table.insert(elements, {address = v.address, flags = 16, value = "-999"}) end gg.setValues(elements) end thanks! 12 hours ago, kiynox said: If you understood it, you would not say "I don't know what mistakes I made". And no, I can't help you to fix it because I don't know what you're trying to search here: ---[Fix this search yourself]--- gg.searchNumber(':nDstDist', 1) gg.refineNumber('110', 1) maintest = gg.getResults(6) gg.clearResults() maintest2 = maintest[1].address - 0x18 gg.searchNumber(maintest2, 32) ------------------------------- well this script was given to me by my friend and I was trying to figure out what he was trying to do in this script lol ---
Question
_yourram
[ @kiynox ] could this script be any better?
function menus()
choices = gg.choice({'Prepare spam','Search','Exit'})
if choices == nil then
os.exit()
else
if choices == 3 then
os.exit()
else
prepares(choices)
end
end
end
function prepares(choices)
if choices == 1 then
gg.clearResults()
gg.searchNumber("9;74;8.0", gg.TYPE_FLOAT)
gg.refineNumber('74', gg.TYPE_FLOAT)
chatspam = gg.getResults(gg.getResultsCount())
gg.addListItems(chatspam)
elseif choices == 2 then
gg.loadResults(chatspam)
gg.getResults(1000)
chatspam = gg.prompt({"Enter which letter you want to spam?(0 = A, 1 = B, 2 = C, 3 = D, 4 = E, 5 = F, 6 = G, 7 = H, 8 = I, 9 = J, 10 = K, 11 = L, 12 = M, 13 = N, 14 = O, 15 = P, 16 = Q, 17 = R, 18 = S, 19 = T, 20 = U, 21 = V, 22 = W, 23 = X, 24 = Y, 25 = Z)"},
{[1] ="0"},
{["1"] ="number"})
if chatspam == nil then
gg.alert("you haven't searched anything so the script will restart!")
return
end
gg.editAll(chatspam[1] ,gg.TYPE_FLOAT)
chatspam = gg.getResults(gg.getResultsCount())
end
end
knxs = false
while true do
if gg.isVisible(true) then
knxs = true
else
knxs = false
end
if knxs == true then
menus()
else
gg.setVisible(false)
end
end
Edited by _yourramTop Posters For This Question
21
7
4
2
Popular Days
Jan 10
14
Jan 12
10
Jan 8
6
Jan 9
3
Top Posters For This Question
_yourram 21 posts
kiynox 7 posts
MANDO01 4 posts
MAARS 2 posts
Popular Days
Jan 10 2024
14 posts
Jan 12 2024
10 posts
Jan 8 2024
6 posts
Jan 9 2024
3 posts
Popular Posts
kiynox
[ @_yourram ] --- if trex == nil then alert('It has to be at least 1 millisecond') return end You put 'return' here, it is wrong. 'return' statement is used to exit a function: LUA 4.4: brea
MANDO01
no problem i'm here for help 😇
MAARS
local utf8 = require("utf8") local chars = {} for i = utf8.codepoint("A"), utf8.codepoint("Z") do table.insert(chars, utf8.char(i)) end local ch = gg.choice(chars, 0, "Choose a letter to spam")
35 answers to this question
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now