Jump to content
  • 0

Function executes on second launch


n3kitOzz

Question

Why is the function is executing after the second time? Even in the logs, everything is fine.

Script:

local gg = gg
menucode = 1
gg.alert('\nDev: @n3kitOzz\nTelegram: @ssb2cheat')

function main()
menu = gg.choice({'Функции ', 'Выход '})
menucode = 1
if menu == nil then hidemenu() end
if menu == 1 then cheatmenu() end
if menu == 2 then os.exit() end
end

function cheatmenu()
menucode = 2
cmenu = gg.choice({'♾ Бесконечные патроны', 'Годмод ', 'Темп стрельбы', 'Хилпушка(скоро) ', 'На главную', 'Выйти'})
if cmenu == nil then hidemenu() end
if cmenu == 1 then inf_ammo() end
if cmenu == 2 then godmode() end
if cmenu == 3 then firerate() end
if cmenu == 4 then healgun() end
if cmenu == 5 then main() end
if cmenu == 6 then os.exit() end
end

function inf_ammo()
gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber('444418', gg.TYPE_DWORD)
gg.sleep(2000)
gg.getResults(10000)
gg.sleep(3000)
gg.editAll('100000000', gg.TYPE_DWORD)
gg.sleep(300)
gg.toast('Ammo hacked')
gg.sleep(100)
gg.alert('Теперь у вас миллионы патронов')
end

function firerate()
gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber('0.15244479477', gg.TYPE_FLOAT)
gg.sleep(2000)
gg.getResults(100000)
gg.sleep(1000)
gg.editAll('0.001', gg.TYPE_FLOAT)
gg.sleep(3000)
gg.toast('Firerate hacked')
gg.alert('Повышен темп стрельбы у ак и скар.')
end

function godmode()
gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber('1132809191', gg.TYPE_DWORD)
gg.sleep(2000)
a = gg.getResults(10000)
gg.sleep(1000)
gg.editAll('2000000000', gg.TYPE_DWORD)
gg.sleep(500)
gg.freeze = true
gg.sleep(300)
gg.freezeType = FREEZE_NORMAL
gg.sleep(399)
gg.toast('You are GOOOOOD!')
end


function megadamage()
end

function healgun()
end

function hidemenu()
gg.sleep(100)
gg.toast('Меню скрыто')
gg.setVisible(false)
end

while true do
if gg.isVisible(true) then
  if menucode == 1 then
    main()
  elseif menucode == 2 then
    cheatmenu()
  else
    main()
end
end
end

And logs:

gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber("0.15244479477", gg.TYPE_FLOAT)
gg.getResults(100000)
gg.editAll("0.001", gg.TYPE_FLOAT)
gg.toast("Firerate hacked")
gg.alert("Повышен темп стрельбы у ак и скар.")

BUT HERE IS NO EFFECT, AND NOTHING HAPPEND.

--[[ return: 1 ]]
gg.choice({ -- table(1498f91)
	[1] = '♾ Бесконечные патроны',
	[2] = 'Годмод ',
	[3] = 'Темп стрельбы',
	[4] = 'Хилпушка(скоро) ',
	[5] = 'На главную',
	[6] = 'Выйти',
})
--[[ return: 3 ]]
gg.setRanges(gg.REGION_ANONYMOUS)
gg.searchNumber("0.15244479477", gg.TYPE_FLOAT)
gg.getResults(100000)
gg.editAll("0.001", gg.TYPE_FLOAT)
gg.toast("Firerate hacked")
gg.alert("Повышен темп стрельбы у ак и скар.")
--[[ return: 1 ]]

AND AFTER SECOND CALL THIS WORKED

 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

32 minutes ago, loversSlayer said:

What the reason of using "sleep" here?

As i got, there is just more then 100K variables so thats why its worked only after 2nd call. Try to use complicated group search with related functions.

In real - 100< variables. I need to do this numbers lower, allright?

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.