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 


How Do You Get Generate Trainer From Table To Work?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
RyanFialcowitz
How do I cheat?
Reputation: 0

Joined: 16 Mar 2012
Posts: 8

PostPosted: Thu Mar 22, 2012 9:43 am    Post subject: How Do You Get Generate Trainer From Table To Work? Reply with quote

I got a script I'm using via Show Cheat Table Lua Script and that works great but it's a pain to having to re-paste the code every time I run the game.

I've heard this program can be used to make trainers but when I do that with the code activated as detailed above, nothing happens when I run the trainer with the game when Cheat Engine is closed.

Clearly, I'm doing something wrong. What step am I missing?

- Ryan Paul Fialcowitz
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

Joined: 09 May 2003
Posts: 25831
Location: The netherlands

PostPosted: Thu Mar 22, 2012 10:03 am    Post subject: Reply with quote

That depends on the lua script

if it's not designed to funtion when the game isn't running you need to make some modifications, like adding an auto attach routine, and activate the cheat when the process has been opened (I recommend a delay since it sometimes happens not all the code is loaded by the game right away)

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
RyanFialcowitz
How do I cheat?
Reputation: 0

Joined: 16 Mar 2012
Posts: 8

PostPosted: Thu Mar 22, 2012 10:05 am    Post subject: Reply with quote

Dark Byte wrote:
That depends on the lua script

if it's not designed to funtion when the game isn't running you need to make some modifications, like adding an auto attach routine, and activate the cheat when the process has been opened (I recommend a delay since it sometimes happens not all the code is loaded by the game right away)


The script is for Deus Ex: Human Revolution and it runs fine as long as I run it through Cheat Engine. What I want to do is have Cheat Engine make a trainer that can run the script.

Here's the script:
Code:
-- set this to the max number of batteries to regenerate
local batteries = 5;

local addr = "[[[[dxhr.exe+01723728]+14]+44]+11c]+1fc";
local f = createForm( true );
local t = createTimer( f, true );
timer_setInterval( t, 1000 );

timer_onTimer( t, function( )
local energy = readFloat(addr);
if math.abs(energy % 30.0) < 0.005 and energy < 30*batteries then
writeFloat(addr, energy + 0.01);
end
end );
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

Joined: 09 May 2003
Posts: 25831
Location: The netherlands

PostPosted: Thu Mar 22, 2012 10:18 am    Post subject: Reply with quote

yes, that script doesn't take care of knowing when the process has been attached, or anything else

anyhow, try this table. If you save it as a .cetrainer with ce (or as a .exe) it will function as a standalone trainer



deusextrainerexample.Ct
 Description:
updated. Clicking the X will close it now too

Download
 Filename:  deusextrainerexample.Ct
 Filesize:  1.54 KB
 Downloaded:  1076 Time(s)


_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping


Last edited by Dark Byte on Thu Mar 22, 2012 10:22 am; edited 1 time in total
Back to top
View user's profile Send private message MSN Messenger
RyanFialcowitz
How do I cheat?
Reputation: 0

Joined: 16 Mar 2012
Posts: 8

PostPosted: Thu Mar 22, 2012 10:22 am    Post subject: Reply with quote

Dark Byte wrote:
yes, that script doesn't take care of knowing when the process has been attached, or anything else

anyhow, try this table. If you save it as a .cetrainer with ce (or as a .exe) it will function as a standalone trainer


Tried saving it as an executable and got en error when running it, any ideas?

- Ryan Paul Fialcowitz
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

Joined: 09 May 2003
Posts: 25831
Location: The netherlands

PostPosted: Thu Mar 22, 2012 10:22 am    Post subject: Reply with quote

Make sure you give it an icon

and save using the save dialog button in ce 6.1 and save as deusextrainer.exe (don't use 6.0, or 5.x, and also do not use the generate trainer from table option. and don't name it deusex.exe, that will conflict)

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
RyanFialcowitz
How do I cheat?
Reputation: 0

Joined: 16 Mar 2012
Posts: 8

PostPosted: Thu Mar 22, 2012 10:30 am    Post subject: Reply with quote

Dark Byte wrote:
Make sure you give it an icon

and save using the save dialog button in ce 6.1 and save as deusextrainer.exe (don't use 6.0, or 5.x, and also do not use the generate trainer from table option. and don't name it deusex.exe, that will conflict)


I used Generate Trainer and it seems to be working. . .

When I run it I get three window popups, is there anyway to have it run silently in the background?

Also, is there a way to make it run the game and then close itself when the game closes?

Lastly, does the file you supplied require Cheat Engine to be installed or can it be run on it's own?

In any case, thanks a lot- you really helped me out!

- Ryan Paul Fialcowitz
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

Joined: 09 May 2003
Posts: 25831
Location: The netherlands

PostPosted: Thu Mar 22, 2012 10:38 am    Post subject: Reply with quote

using generate trainer will add another script that might cause conflicts. Just save the trainer as a .exe using the normal table save method. If it sees you're saving as .exe, it'll show a dialog with some options

also, what do those popups say ?

And yes, these trainers run without having cheat engine installed (they come with cheatengine on board)

I've uploaded the trainer example as an exe here: http://cheatengine.org/temp/deusexampletrainer.rar (does this also give popups? And what are they ?)

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
RyanFialcowitz
How do I cheat?
Reputation: 0

Joined: 16 Mar 2012
Posts: 8

PostPosted: Thu Mar 22, 2012 10:42 am    Post subject: Reply with quote

Dark Byte wrote:
using generate trainer will add another script that might cause conflicts. Just save the trainer as a .exe using the normal table save method. If it sees you're saving as .exe, it'll show a dialog with some options

also, what do those popups say ?

And yes, these trainers run without having cheat engine installed (they come with cheatengine on board)


Yours has one less pop up, two to my three. Probably a result of my compiling it the wrong way as you said.

I get a UDF_0 & Close this trainer. window. As I said I would prefer it run without any windows and just end it's process when the game's ends. But if that is not an option this is stil FAR better then pasting the script every time like I was doing before.

- Ryan Paul Fialcowitz
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