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 


WHY is cheat engine bugging out when re-generating trainer?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
mordax
Expert Cheater
Reputation: 1

Joined: 16 Apr 2010
Posts: 138

PostPosted: Tue May 28, 2024 8:39 am    Post subject: WHY is cheat engine bugging out when re-generating trainer? Reply with quote

Hiya. There is one bug that has really been making me angry, it has existed ever since I have been using CE for making simple trainers for myself and friends.

today that bug happened in this exact way:
i always manually design the trainer, so it looks nice and tidy!
I tested and everything works as i know how to write basic trainer.
now my custom trainer is all ok, but in lua i forgot to add [ ] around couple addresses and this prevented couple things from working in a combo box.

so i went into lua and fixed it, but when i clicked "execute" then on some reason it undid some of the design changes.
so i was like "ok WHATEVER!" and i reloaded entire CE and the table.
i then click on edit trainer and it shows up fine. i made the changes again and this time execute did not revert any of my changes. all seems fine!

FIRST PROBLEM is that there is no way to get back into the trainer generator, only way i know of, is to save anything as .exe and this opens the generator form again.
I choose 64-bit and hit generate, i set filename as before and it generates the .exe of my trainer, but it doesn't launch!

in task manager i can see the process, but there's no visual interface and none of the hotkeys work either.

WHY IS IT DOING THAT?

ONLY "fix" i know, is to close CE again, reload the latest saved table, fix the visuals and code, then save the design as .lfm in the design editor.
then close CE again (because if i delete trainer, it remains open and starts spitting out access violation errors when trying to close the trainer that no longer exists).
SO once i reload CE again, i have to reload my table again.
then DELETE the trainer without opening it.
then generate a new trainer and go back into the manual editing of interface and then load the saved .lfm file to get my interface back, but this still doesn't load images, title nor description / info.

it's hell of a lot of work to bypass this bug. can you please fix this bug?
or does anyone know a better way to prevent this bug from happening?
I have never bothered to make a topic about it as i have been using that bypass trick, but it can be very nerve wrecking if i only want to make one tiny change and trainer refuses to open after re-generating it.

This same thing happens when I update previous trainers. like when game has update and i only have to edit the AoB or simple address. it's a quick edit of couple bytes, but then i have to go through that painful process of bypassing the bug.

I would very much appreciate if someone can help me fix this. Thanks!
Back to top
View user's profile Send private message
mordax
Expert Cheater
Reputation: 1

Joined: 16 Apr 2010
Posts: 138

PostPosted: Wed Jun 12, 2024 5:18 pm    Post subject: Reply with quote

sorry for the bump, but is there really no solution? just got stuck on it again and this time loading the form did not fix it either. something is fundementally wrong somewhere that prevents trainers from opening after edit + generate.

i'm not doing anything i shouldn't. i simply click on generate trainer and design it myself with colors and some explenation what things do.

sometimes trainer just won't open after it's generated. i'm not "looking" at the folder where i put it, but that's never been issue. i usually put it on my desktop and it never has issues. that issue i'm talking about is related to something else messing up.

could it be due 4k desktop? generated trainers usually look bit weird in 1080p when made in 4k desktop.

today i could not make trainer load at all after generating. i ended up having to completely re-design it from scratch, because the damn thing wouldn't start! seriously nobody else has this issue?
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

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

PostPosted: Wed Jun 12, 2024 6:20 pm    Post subject: Reply with quote

For DPI issues when designing forms: go to the exe of CE, and rightclick it. Properties->compatibility->change high dpi settings, override, and select system

or always use anchors instead of relying on pixel positions

As for the issues you have, don't ever click execute while designing the trainer.
That will mess up a lot of stuff (unless it's to test run the trainer, but afterwards, close CE. don't design in that state)

when editing a trainer (assuming it's a .ct you saved after generating the trainer) , don't use the generate generic lua script for trainer option to save your changes. Just save as .exe


As for the trainer not showing, you'd have to look at the code and print some info, like is the form visible, what are the coordinates, etc...
Once everything is fine, save the table with correct lua scripts and forms (again, don't save if you've clicked execute)

_________________
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
mordax
Expert Cheater
Reputation: 1

Joined: 16 Apr 2010
Posts: 138

PostPosted: Fri Jun 21, 2024 10:15 pm    Post subject: Reply with quote

Dark Byte wrote:
For DPI issues when designing forms: go to the exe of CE, and rightclick it. Properties->compatibility->change high dpi settings, override, and select system

or always use anchors instead of relying on pixel positions

As for the issues you have, don't ever click execute while designing the trainer.
That will mess up a lot of stuff (unless it's to test run the trainer, but afterwards, close CE. don't design in that state)

when editing a trainer (assuming it's a .ct you saved after generating the trainer) , don't use the generate generic lua script for trainer option to save your changes. Just save as .exe


As for the trainer not showing, you'd have to look at the code and print some info, like is the form visible, what are the coordinates, etc...
Once everything is fine, save the table with correct lua scripts and forms (again, don't save if you've clicked execute)


thanks, i will try the DPI settings, but other info is bit confusing, can you please clarify?

are you saying that after i have executed lua script, i shouldn't click on "generate generic trainer lua script from table"?
i should first close the CE, re-open and then without executing the lua generate the trainer?
because i don't have issues on first try, i generate the trainer and slightly change the design (renaming some cheat options and changing some colors) and then i generate it as .exe and it launches just fine.

BUT when i add things to my list or simply have to change AoB instruction when game has update, then i go back to my generated design and click "edit". i don't execute any lua. i make my changes to the code and replace old AoB with new one.
then i do exactly as you said, i save it as .exe and it opens the trainer generator again. i generate it as .exe, but then trainer won't open.
i see process, but no visible window. (no, it's not outside of monitor or minimized, it simply has no visible window).

ONLY working way i found, is to save the trainer form (.frm i think?) and then deleting the trainer completely, save the table again, close CE, open CE, load the newly saved table without trainer, then generate generic trainer and once that form opens, then i reload the trainer form so it loads my custom design and then i can generate it.
However recently that did not work either, i ended up having to re-design everything from scratch as it simply did not start after generating a trainer.
it makes the trainer.exe, but it doesn't show visible window. i only see it in process list, but no visible window. This happens very often when making changes to trainer and trying to re-generate it.

just additional info:
i keep all my cheats as .ct table, even trainers.
i only generate them to share with friends or some small groups
when game updates, i open the old .ct table and update it accordingly
this is where my issues start. i do as you said, i save it as .exe to open trainer generator and i can generate the trainer as .exe, but generated trainer.exe opens without visible window.
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

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

PostPosted: Sat Jun 22, 2024 12:14 am    Post subject: Reply with quote

add some print statements to your code

the important line is CETrainer.show() , does the code reach there and after it ?

oh, and go to CE settings and disable saving/loading window positions

_________________
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
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