Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[Help] Assembly script Enable/Disable LUA

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
johnkittz
Advanced Cheater
Reputation: 0

Joined: 17 May 2016
Posts: 95
Location: orderandhacks

PostPosted: Mon Jun 27, 2016 5:00 am    Post subject: [Help] Assembly script Enable/Disable LUA Reply with quote

I finally figured out assembly and I wanna make a trainer but....I want my trainer to have a button which will enable on first click and disable on second click

I've looked everywhere

(PS): I'm looking for a quick example I don't wanna take to much of anybody's time
Back to top
View user's profile Send private message Send e-mail Visit poster's website
DaSpamer
Grandmaster Cheater Supreme
Reputation: 52

Joined: 13 Sep 2011
Posts: 1578

PostPosted: Mon Jun 27, 2016 7:59 am    Post subject: Reply with quote

Code:
function onButtonClick(sender)
   local tag = sender.Tag;
   if (tag == 0) then
      sender.Tag = 1;
      autoAssemble([[//enable script]])
   else
      sender.Tag = 0
      autoAssemble([[//disable script]])
   end
end


_________________
HEY Hitler
Do you get lazy when making trainers?
Well no more!
My CETrainer will generate it for you in seconds, so you won't get lazy! Very Happy

http://forum.cheatengine.org/viewtopic.php?t=564919
Back to top
View user's profile Send private message
johnkittz
Advanced Cheater
Reputation: 0

Joined: 17 May 2016
Posts: 95
Location: orderandhacks

PostPosted: Mon Jun 27, 2016 12:35 pm    Post subject: Reply with quote

DaSpamer wrote:
Code:
function onButtonClick(sender)
   local tag = sender.Tag;
   if (tag == 0) then
      sender.Tag = 1;
      autoAssemble([[//enable script]])
   else
      sender.Tag = 0
      autoAssemble([[//disable script]])
   end
end



Thanks Spamer!!!! Smile
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites