Disable button once clicked Cheatengine Lua

1.9k Views Asked by At

So I've been struggling making a button that on pressed goes to a link and toggles Enabled to false so you cant click it anymore

function CEButton1Click(sender)
shellExecute("https://google.com/search")
CEButton1.Enabled=false
end

The above is what I have so far but it does not seem to be working.

1

There are 1 best solutions below

0
On BEST ANSWER

The documentation for cheat engine is severely lacking, but sender in that function is actually the button itself. This means you can simple do

sender.Enabled = false

and that successfully disables the button.

It works!