View previous topic :: View next topic |
Author |
Message |
beagle Cheater Reputation: 0
Joined: 27 Aug 2014 Posts: 36
|
Posted: Wed Sep 13, 2017 7:19 pm Post subject: SaveOpenedFile not working when trainer is saved as .EXE |
|
|
I'm using the latest github build of CE so that memory scanning works with open file, and i'm using openfileasprocess/saveopenedfile.
Everything works fine when used as a cheat table, but once i save it as an .EXE, saveopenedfile seems to stop working.
Normally saveopenedfile will save a copy of the file you are modifying in the folder where the cheat table is located, but when saved as an .EXE it wont modify the original file or create a copy of it.
Also i had to transfer the file "standalonephase2.dat" from the cheat engine 6.7 bin folder to the github compiled CE folder since it gave an error when trying to create the .exe, saying the file wasnt found.
I get the same problem though when saving the cheat table as an .EXE using regular CE 6.7, so i'm not sure if it has to do with that standalonephase2.dat file.
edit: updated title for clarity
also .CETRAINER works like normal
edit2:
it works as an .exe if i use the same filename:
Code: |
FileName= dialog.FileName
openFileAsProcess(FileName,false)
...
SaveOpenedFile(FileName)
|
but if i do this so it doesnt overwrite the file, it wont create a new copy:
Code: |
FileName= dialog.FileName
openFileAsProcess(FileName,false)
...
SaveOpenedFile("new copy")
|
this is fine for me, but if someone knows why the .exe wont save a new copy or how to fix it that would be ideal
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25296 Location: The netherlands
|
Posted: Thu Sep 14, 2017 2:01 am Post subject: |
|
|
Use the TrainerOrigin variable for the path where the trainer exe is
_________________
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 |
|
|
beagle Cheater Reputation: 0
Joined: 27 Aug 2014 Posts: 36
|
Posted: Thu Sep 14, 2017 1:05 pm Post subject: |
|
|
i'm unsure how to use TrainerOrigin since saveopenedfile only has one parameter for the file's name
also, can the file be easily saved in the location of the file you are modifying, rather than the trainer location?
|
|
Back to top |
|
|
|