[Help] CheckBox Lua Cheat Engine Enable/Disable

Anything Cheat Engine related, bugs, suggestions, helping others, etc..
Post Reply
Evoked100
Expert Cheater
Expert Cheater
Posts: 68
Joined: Mon Jul 27, 2020 4:16 pm
Reputation: 33

[Help] CheckBox Lua Cheat Engine Enable/Disable

Post by Evoked100 »

How to enable/disable script using lua?

exemple o mark checkbox set value float "10000"

disable set value float "50"

Image

i have sarch this code not working:

Code: Select all

function fov() --increase distance view
  if main.fov.checked==true then
    writeFloat("[trove.exe+0106FBB8]+4",10000)
  end
end

function float() --increase distance view
    writeFloat("[trove.exe+0106FBB8]+4",50)
end
and for OAB Script? how to Enable/Disable?

my code script :

Code: Select all

[ENABLE]

aobscanmodule(jumper,trove.exe,FF 46 3C 68) // should be unique
alloc(newmem,$1000)

label(code)

newmem:

code:
  inc [esi+3C]
  push trove.exe+C2080C

jumper:
 dec [esi+3C]
 return:
registersymbol(jumper)

[DISABLE]

jumper:
  db FF 46

unregistersymbol(jumper)
dealloc(newmem)

Evoked100
Expert Cheater
Expert Cheater
Posts: 68
Joined: Mon Jul 27, 2020 4:16 pm
Reputation: 33

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by Evoked100 »

thanks for read and help-me!!

Pitronic
What is cheating?
What is cheating?
Posts: 3
Joined: Tue Jul 06, 2021 12:30 pm
Reputation: 0

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by Pitronic »

how to write this code with these commands in lua?

CETrainer.CECheckbox1
enableInfiniteHealthCheat()
disableInfiniteHealthCheat()


CETrainer.CECheckbox2
enableInfiniteAmoCheat()
disableInfiniteAmoCheat()

User avatar
tdg6661
Table Makers
Table Makers
Posts: 698
Joined: Sat Dec 15, 2018 12:10 pm
Reputation: 267

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by tdg6661 »

Hmm, wrong section. You should post it in here: viewforum.php?f=14

Anyway,

Code: Select all

main.fov.OnChange = function(sender)
	local addr = getAddressSafe("[trove.exe+0106FBB8]+4")
	if addr == nil then return end

	if sender.checked then
		writeFloat(addr,10000)
	else
		writeFloat(addr,50)
	end
end

User avatar
tdg6661
Table Makers
Table Makers
Posts: 698
Joined: Sat Dec 15, 2018 12:10 pm
Reputation: 267

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by tdg6661 »

Pitronic wrote:
Sun May 28, 2023 7:18 am
how to write this code with these commands in lua?

CETrainer.CECheckbox1
enableInfiniteHealthCheat()
disableInfiniteHealthCheat()


CETrainer.CECheckbox2
enableInfiniteAmoCheat()
disableInfiniteAmoCheat()

Code: Select all

CETrainer.CECheckbox1.OnChange = function(sender)
	if sender.checked then
		enableInfiniteHealthCheat()
	else
		disableInfiniteHealthCheat()
	end
end
And so on..

Pitronic
What is cheating?
What is cheating?
Posts: 3
Joined: Tue Jul 06, 2021 12:30 pm
Reputation: 0

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by Pitronic »

tdg6661 wrote:
Mon May 29, 2023 7:34 pm
Pitronic wrote:
Sun May 28, 2023 7:18 am
how to write this code with these commands in lua?

CETrainer.CECheckbox1
enableInfiniteHealthCheat()
disableInfiniteHealthCheat()


CETrainer.CECheckbox2
enableInfiniteAmoCheat()
disableInfiniteAmoCheat()

Code: Select all

CETrainer.CECheckbox1.OnChange = function(sender)
	if sender.checked then
		enableInfiniteHealthCheat()
	else
		disableInfiniteHealthCheat()
	end
end
And so on..
Eror
[Link]
table [Link]

User avatar
tdg6661
Table Makers
Table Makers
Posts: 698
Joined: Sat Dec 15, 2018 12:10 pm
Reputation: 267

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by tdg6661 »

Pitronic wrote:
Tue Jun 06, 2023 7:23 am

Eror
[Link]
table [Link]
Yes. Because the function enableInfiniteHealthCheat() was not defined. Make it first then you can use that code above.

Code: Select all

function enableInfiniteHealthCheat()
	-- Your script is here
end
Here, like this

Code: Select all

CETrainer.CECheckbox1.OnChange = function(sender)
	local mr = getAddressList().getMemoryRecordByID(1)
	if mr == nil then return end

	if sender.checked then
		mr.Active = true
	else
		mr.Active = false
	end
end

Pitronic
What is cheating?
What is cheating?
Posts: 3
Joined: Tue Jul 06, 2021 12:30 pm
Reputation: 0

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by Pitronic »

tdg6661 wrote:
Tue Jun 06, 2023 8:53 am
Pitronic wrote:
Tue Jun 06, 2023 7:23 am

Eror
[Link]
table [Link]
Yes. Because the function enableInfiniteHealthCheat() was not defined. Make it first then you can use that code above.

Code: Select all

function enableInfiniteHealthCheat()
	-- Your script is here
end
Here, like this

Code: Select all

CETrainer.CECheckbox1.OnChange = function(sender)
	local mr = getAddressList().getMemoryRecordByID(1)
	if mr == nil then return end

	if sender.checked then
		mr.Active = true
	else

		mr.Active = false
		
	end
end
function enable Infinite Health Cheat()
-- Your script is here
end
I don't need the code for enable Infinite Health Cheat() I need the code for this command here is the source [Link] ... oassemble/
In other words, you need to execute two commands. If the check mark is on the checkbox, execute the command
enable Infinite Health Cheat()
CETrainer.CHEAT 0.SetActive(true)
if the check mark is not on the checkbox, execute the command
disable Infinite Health Cheat()
CETrainer.CHEAT 0.SetActive(false)
Last edited by Pitronic on Tue Jun 06, 2023 3:05 pm, edited 1 time in total.

jastgamess
What is cheating?
What is cheating?
Posts: 1
Joined: Thu Nov 23, 2023 6:49 pm
Reputation: 0

Re: [Help] CheckBox Lua Cheat Engine Enable/Disable

Post by jastgamess »

I have everything defined, but it doesn't work either.
Here's the table,
[Link]
make it work, and make a comment in the table so that I understand the logic.

Post Reply

Who is online

Users browsing this forum: No registered users