| View previous topic :: View next topic |
| Author |
Message |
cancandodo Advanced Cheater
Reputation: 0
Joined: 09 Mar 2012 Posts: 75
|
Posted: Tue Feb 15, 2022 6:57 am Post subject: how to get a process's folder or full filename? |
|
|
running a process
d:\test\mygame.exe
how to
print "d:\test\mygame.exe" or print "d:\test\"
by get process "mygame.exe"
|
|
| Back to top |
|
 |
Dark Byte Site Admin
Reputation: 471
Joined: 09 May 2003 Posts: 25859 Location: The netherlands
|
Posted: Tue Feb 15, 2022 7:07 am Post subject: |
|
|
| Code: |
print(enumModules()[1].PathToFile)
|
for the path you can do:
| Code: |
print(extractFilePath(enumModules()[1].PathToFile))
|
_________________
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 |
|
 |
cancandodo Advanced Cheater
Reputation: 0
Joined: 09 Mar 2012 Posts: 75
|
Posted: Tue Feb 15, 2022 7:32 am Post subject: |
|
|
| Dark Byte wrote: | | Code: |
print(enumModules()[1].PathToFile)
|
for the path you can do:
| Code: |
print(extractFilePath(enumModules()[1].PathToFile))
|
|
run this lua
print
C:\Program Files\Cheat Engine 7.3\cheatengine-x86_64-SSE4-AVX2.exe
not print d:\test\mygame.exe
|
|
| Back to top |
|
 |
Dark Byte Site Admin
Reputation: 471
Joined: 09 May 2003 Posts: 25859 Location: The netherlands
|
Posted: Tue Feb 15, 2022 7:43 am Post subject: |
|
|
are you attached to mygame.exe ?
_________________
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 |
|
 |
cancandodo Advanced Cheater
Reputation: 0
Joined: 09 Mar 2012 Posts: 75
|
Posted: Tue Feb 15, 2022 7:53 am Post subject: |
|
|
| Dark Byte wrote: | | are you attached to mygame.exe ? |
mygame.exe is a another process, not the running game process.
i want to get any process's patch,it can be "explorer.exe" or "Chrome.exe" or any other process
|
|
| Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8587 Location: 127.0.0.1
|
Posted: Tue Feb 15, 2022 8:35 pm Post subject: |
|
|
| Code: |
getProcesslist(Strings): Fills a Strings inherited object with the processlist of the system. Format: %x-pidname
getProcesslist(): Returns a table with the processlist (pid - name )
|
You can use these to get the process list, then use with each processes id to get its individual module list, then do what Dark Byte showed with the first module in the list to get the path.
_________________
- Retired. |
|
| Back to top |
|
 |
|