Jump to content
  • 1

If "switch" = on then "other switch" = off


YeetMeister

Question

So... im working on a menu with Configs you can load in with seperate Switches (On/Off)

My plan was that when i activate one Switch, but want to change to another switch then the function would turn of the other recently used switch ( not the one i pressed)

Here's a simple code i guess. It might not be right or something but please help me

 

 

--<Switches>
on = "[Active] "
off = "[Inactive] "
hvh = off
legit = off
unfair = off
working = "[[Working]]"
nouse = "[[NoUse]]"


if hvh == on then legit = off end
if hvh == on then unfair = off end

if legit == on then hvh = off end
if legit == on then unfair = off end

if unfair == on then hvh = off end
if unfair == on then legit = off end
--<Switches>

 

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

4 hours ago, XxhentaixX said:

No. I putted in there because of the particle game the script was desiged for...its was not realy nicesairy

Ok... can you explain or tell me something else?

 

I want ti use the gg.searchAdress() function, but idk how to find the exact adress. Can you help me?

 

Link to comment
Share on other sites

9 minutes ago, YeetMeister said:

So... im working on a menu with Configs you can load in with seperate Switches (On/Off)

My plan was that when i activate one Switch, but want to change to another switch then the function would turn of the other recently used switch ( not the one i pressed)

Here's a simple code i guess. It might not be right or something but please help me

 

 


--<Switches>
on = "[Active] "
off = "[Inactive] "
hvh = off
legit = off
unfair = off
working = "[[Working]]"
nouse = "[[NoUse]]"


if hvh == on then legit = off end
if hvh == on then unfair = off end

if legit == on then hvh = off end
if legit == on then unfair = off end

if unfair == on then hvh = off end
if unfair == on then legit = off end
--<Switches>

 

The Switch system used in this Example: Prefix Tutorial

Link to comment
Share on other sites

48 minutes ago, YeetMeister said:

So... im working on a menu with Configs you can load in with seperate Switches (On/Off)

My plan was that when i activate one Switch, but want to change to another switch then the function would turn of the other recently used switch ( not the one i pressed)

Here's a simple code i guess. It might not be right or something but please help me

 

 


--<Switches>
on = "[Active] "
off = "[Inactive] "
hvh = off
legit = off
unfair = off
working = "[[Working]]"
nouse = "[[NoUse]]"


if hvh == on then legit = off end
if hvh == on then unfair = off end

if legit == on then hvh = off end
if legit == on then unfair = off end

if unfair == on then hvh = off end
if unfair == on then legit = off end
--<Switches>

 

We use the same rype of switch system. But i use multiChoice and i savd my results derictly in the table so when i activate s hack if wong need to search for like 20seconds jnorder to activate or deactivate...watch this script..its supposed to be for slither.io you will understand it quickly


menuk = 1


if gg.isVisible(true) then
  gg.setVisible(false)
end

local old = gg.getRanges();
gg.setRanges(gg.REGION_CODE_APP)
gg.searchNumber('-1.5881868e-23F;1.69999992847F;14.0E;2.6875F::29', gg.TYPE_DOUBLE)
if gg.getResultCount() == 0 then 
gg.toast('First play 1 match')
gg.sleep(4000)
os.exit()
else
gg.searchNumber(14, gg.TYPE_DOUBLE)
m = gg.getResults(1)
gg.addListItems(m)
gg.clearResults()
gg.searchNumber('1.0E;6.8500028e35F;2.4170348e26F;1.11499989033F::41', gg.TYPE_FLOAT)
t = gg.getResults(4)
gg.addListItems(t)
gg.clearResults()
gg.searchNumber('25,549,618.0F;7.0E;2.4375F;6.8500028e35F::512', gg.TYPE_DOUBLE)
gg.searchNumber(7, gg.TYPE_DOUBLE)
r = gg.getResults(2)
gg.addListItems(r)
gg.clearResults()
gg.searchNumber('1.0924349e-19F;-0.00003169477F;1.0E;1.875F;6.8500028e35F;7.213542e35F::21', gg.TYPE_DOUBLE)
b = gg.getResults(6)
gg.addListItems(b)
gg.clearResults()
gg.searchNumber('2.3150184e36F;-0.00003169477F;10E;2.5625F;1.5948906e26F::17', gg.TYPE_DOUBLE)
gg.searchNumber(10, gg.TYPE_DOUBLE)
a = gg.getResults(1)
gg.addListItems(a)
gg.clearResults()
gg.searchNumber('9.1866338e35F;-0.00003169477F;-1.0E;-1.875F;1.5948906e26F;7.0059935e35F::21', gg.TYPE_DOUBLE)
c = gg.getResults(6)
gg.addListItems(c)
gg.clearResults()
gg.searchNumber('2.7675717e26F;-0.00003169477F;4.0E;2.25F;3.7133939e16F;2.3928563e26F::21', gg.TYPE_DOUBLE)
d = gg.getResults(3)
gg.addListItems(d)
gg.clearResults()
end
gg.setRanges(old)


on = '[ON]'
off = '[OFF]'
skin = off
speed = off
grade = off
zoom = off
rank = off
hit = off
mass = off

function START()

local menu = gg.multiChoice({
skin.. 'Brightness color[A.I.]',
speed.. 'Speed Hack[A.I.]',
grade.. '20 Grade Hook[A.I.]',
zoom.. 'Zoom Hack(small)[ONLINE]',
rank.. 'Rank Hack[A.I.]',
hit.. 'Hit Distance[A.I.]',
mass.. 'Mass Increase(will bug)[A.I.]',
'EXIT'},
nil,
'choose hacks')

if menu == nil then noselect()
else
if menu[8] then
os.exit()
else
if menu[1] then
if skin == on then
skin = off
gg.getListItems(t)
t[1].value = '1'
gg.setValues(t)
gg.toast('deactivated skin')
else
skin = on
gg.getListItems(t)
t[1].value = '60'
gg.setValues(t)
gg.toast('activated skin')
end
end

if menu[2] then
if speed == on then
speed = off
gg.getListItems(m)
m[1].value = '14'
gg.setValues(m)
gg.toast('deactivated speed')
else
speed = on
gg.getListItems(m)
m[1].value = '20'
gg.setValues(m)
gg.toast('activated speed')
end
end

if menu[3] then
if grade == on then
grade = off
gg.getListItems(r)
for i, v in ipairs(r) do
r.value = '7'
end
gg.setValues(r)
gg.toast('deactivated grade')
else
grade = on
gg.getListItems(r)
for i, v in ipairs(r) do
r.value = '8.5'
end
gg.setValues(r)
gg.toast('activated grade')
end
end

if menu[4] then
if zoom == on then
zoom = off
gg.getListItems(b)
b[4].value = '1.875'
gg.setValues(b)
gg.toast('deactivated Zoom')
else
zoom = on 
gg.getListItems(b)
b[4].value = '1.82'
gg.setValues(b)
gg.toast('activated zoom')
end
end

if menu[5] then
if rank == on then
rank = off
gg.getListItems(a)
a[1].value = '10'
gg.setValues(a)
gg.toast('deactivated rank')
else
rank = on
gg.getListItems(a)
a[1].value = '50'
gg.setValues(a)
gg.toast('activated rank')
end
end


if menu[6] then
if hit == on then
hit = off
gg.getListItems(d)
d[3].value = '4'
gg.setValues(d)
gg.toast('deactivated hit')
else
hit = on
gg.getListItems(d)
d[3].value = '0'
gg.setValues(d)
gg.toast('activated hit')
end
end


if menu[7] then
if mass == on then
mass = off
gg.getListItems(c)
c[3].value = '-1'
gg.setValues(c)
gg.toast('deactivated mass')
else
mass = on
gg.getListItems(c)
c[3].value = '-0.9'
gg.setValues(c)
gg.toast('activated mass')
end
end

end
end
menuk =-1
end


function noselect()
gg.toast('You not select anything')
end

START()

while (true) do
  if gg.isVisible(true) then
    gg.setVisible(false)
    menuk = 1
  end
if menuk == 1 then START() end
end

 

air.com.hypah.slither.io.lua

Link to comment
Share on other sites

19 hours ago, XxhentaixX said:

We use the same type of switch system. But i use multiChoice and i saved my results derictly in the table so when i activate the hack i wont need to search for like 20seconds in order to activate or deactivate...watch this script..its supposed to be for slither.io you will understand it quickly


menuk = 1


if gg.isVisible(true) then
  gg.setVisible(false)
end

local old = gg.getRanges();
gg.setRanges(gg.REGION_CODE_APP)
gg.searchNumber('-1.5881868e-23F;1.69999992847F;14.0E;2.6875F::29', gg.TYPE_DOUBLE)
if gg.getResultCount() == 0 then 
gg.toast('First play 1 match')
gg.sleep(4000)
os.exit()
else
gg.searchNumber(14, gg.TYPE_DOUBLE)
m = gg.getResults(1)
gg.addListItems(m)
gg.clearResults()
gg.searchNumber('1.0E;6.8500028e35F;2.4170348e26F;1.11499989033F::41', gg.TYPE_FLOAT)
t = gg.getResults(4)
gg.addListItems(t)
gg.clearResults()
gg.searchNumber('25,549,618.0F;7.0E;2.4375F;6.8500028e35F::512', gg.TYPE_DOUBLE)
gg.searchNumber(7, gg.TYPE_DOUBLE)
r = gg.getResults(2)
gg.addListItems(r)
gg.clearResults()
gg.searchNumber('1.0924349e-19F;-0.00003169477F;1.0E;1.875F;6.8500028e35F;7.213542e35F::21', gg.TYPE_DOUBLE)
b = gg.getResults(6)
gg.addListItems(b)
gg.clearResults()
gg.searchNumber('2.3150184e36F;-0.00003169477F;10E;2.5625F;1.5948906e26F::17', gg.TYPE_DOUBLE)
gg.searchNumber(10, gg.TYPE_DOUBLE)
a = gg.getResults(1)
gg.addListItems(a)
gg.clearResults()
gg.searchNumber('9.1866338e35F;-0.00003169477F;-1.0E;-1.875F;1.5948906e26F;7.0059935e35F::21', gg.TYPE_DOUBLE)
c = gg.getResults(6)
gg.addListItems(c)
gg.clearResults()
gg.searchNumber('2.7675717e26F;-0.00003169477F;4.0E;2.25F;3.7133939e16F;2.3928563e26F::21', gg.TYPE_DOUBLE)
d = gg.getResults(3)
gg.addListItems(d)
gg.clearResults()
end
gg.setRanges(old)


on = '[ON]'
off = '[OFF]'
skin = off
speed = off
grade = off
zoom = off
rank = off
hit = off
mass = off

function START()

local menu = gg.multiChoice({
skin.. 'Brightness color[A.I.]',
speed.. 'Speed Hack[A.I.]',
grade.. '20 Grade Hook[A.I.]',
zoom.. 'Zoom Hack(small)[ONLINE]',
rank.. 'Rank Hack[A.I.]',
hit.. 'Hit Distance[A.I.]',
mass.. 'Mass Increase(will bug)[A.I.]',
'EXIT'},
nil,
'choose hacks')

if menu == nil then noselect()
else
if menu[8] then
os.exit()
else
if menu[1] then
if skin == on then
skin = off
gg.getListItems(t)
t[1].value = '1'
gg.setValues(t)
gg.toast('deactivated skin')
else
skin = on
gg.getListItems(t)
t[1].value = '60'
gg.setValues(t)
gg.toast('activated skin')
end
end

if menu[2] then
if speed == on then
speed = off
gg.getListItems(m)
m[1].value = '14'
gg.setValues(m)
gg.toast('deactivated speed')
else
speed = on
gg.getListItems(m)
m[1].value = '20'
gg.setValues(m)
gg.toast('activated speed')
end
end

if menu[3] then
if grade == on then
grade = off
gg.getListItems(r)
for i, v in ipairs(r) do
r.value = '7'
end
gg.setValues(r)
gg.toast('deactivated grade')
else
grade = on
gg.getListItems(r)
for i, v in ipairs(r) do
r.value = '8.5'
end
gg.setValues(r)
gg.toast('activated grade')
end
end

if menu[4] then
if zoom == on then
zoom = off
gg.getListItems(b)
b[4].value = '1.875'
gg.setValues(b)
gg.toast('deactivated Zoom')
else
zoom = on 
gg.getListItems(b)
b[4].value = '1.82'
gg.setValues(b)
gg.toast('activated zoom')
end
end

if menu[5] then
if rank == on then
rank = off
gg.getListItems(a)
a[1].value = '10'
gg.setValues(a)
gg.toast('deactivated rank')
else
rank = on
gg.getListItems(a)
a[1].value = '50'
gg.setValues(a)
gg.toast('activated rank')
end
end


if menu[6] then
if hit == on then
hit = off
gg.getListItems(d)
d[3].value = '4'
gg.setValues(d)
gg.toast('deactivated hit')
else
hit = on
gg.getListItems(d)
d[3].value = '0'
gg.setValues(d)
gg.toast('activated hit')
end
end


if menu[7] then
if mass == on then
mass = off
gg.getListItems(c)
c[3].value = '-1'
gg.setValues(c)
gg.toast('deactivated mass')
else
mass = on
gg.getListItems(c)
c[3].value = '-0.9'
gg.setValues(c)
gg.toast('activated mass')
end
end

end
end
menuk =-1
end


function noselect()
gg.toast('You not select anything')
end

START()

while (true) do
  if gg.isVisible(true) then
    gg.setVisible(false)
    menuk = 1
  end
if menuk == 1 then START() end
end

 

air.com.hypah.slither.io.lua

 

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.