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 


Saving settings of CE trainer in separate files?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
Dr.Disrespect
Grandmaster Cheater
Reputation: 3

Joined: 17 Feb 2016
Posts: 526

PostPosted: Wed Apr 13, 2016 8:37 pm    Post subject: Saving settings of CE trainer in separate files? Reply with quote

Is it possible to save settings, such as checkbox selection, numbers in editbox, in separate files and load them when needed? For example, separate txt files for different settings?

Thanks in advance.
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Wed Apr 13, 2016 9:27 pm    Post subject: Reply with quote

http://www.lua.org/manual/5.1/manual.html#5.7
Back to top
View user's profile Send private message
ParkourPenguin
I post too much
Reputation: 152

Joined: 06 Jul 2014
Posts: 4702

PostPosted: Wed Apr 13, 2016 9:35 pm    Post subject: Reply with quote

Sure. Just get all the data using the respective class functions (e.g. checkbox.Checked) and save the data to a file. I'm not experienced with file management in Lua, but from looking through main.lua you should be able to use the Strings class to do it. Also it seems like Lua has its own built in file IO library.
_________________
I don't know where I'm going, but I'll figure it out when I get there.
Back to top
View user's profile Send private message
Dr.Disrespect
Grandmaster Cheater
Reputation: 3

Joined: 17 Feb 2016
Posts: 526

PostPosted: Wed Apr 13, 2016 10:27 pm    Post subject: Reply with quote

Thanks Zaner and Penguin. I think I need some time to understand the lua manual. Sad I tried to find some example, but I couldn't.

Update:
Can I get a simple example?
Say, checkbox1 is checked. How to save this to a txt file and then load it, and then set checkbox1 to checked?
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Thu Apr 14, 2016 6:01 pm    Post subject: Reply with quote

http://forum.cheatengine.org/viewtopic.php?t=545361
Back to top
View user's profile Send private message
Dr.Disrespect
Grandmaster Cheater
Reputation: 3

Joined: 17 Feb 2016
Posts: 526

PostPosted: Thu Apr 14, 2016 10:02 pm    Post subject: Reply with quote

Zanzer wrote:
http://forum.cheatengine.org/viewtopic.php?t=545361


Edit:
Thanks Zaner, I'm making progress with your help.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine 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