View previous topic :: View next topic |
Author |
Message |
anglez How do I cheat?
Reputation: 0
Joined: 15 Oct 2021 Posts: 2 Location: peru
|
Posted: Sat Nov 06, 2021 11:31 pm Post subject: help generate trainer lua +10 process id |
|
|
I can only select manually by testing but when I generate trainer it does not work because it grabs another process
help. !!!!!
Description: |
|
Filesize: |
147.95 KB |
Viewed: |
1864 Time(s) |

|
_________________
iselth |
|
Back to top |
|
 |
anglez How do I cheat?
Reputation: 0
Joined: 15 Oct 2021 Posts: 2 Location: peru
|
Posted: Mon Nov 08, 2021 1:55 pm Post subject: Re: help generate trainer lua +10 process id |
|
|
anglez wrote: | I can only select manually by testing but when I generate trainer it does not work because it grabs another process
help. !!!!! |
helpppppppppppppppppppppp ???
_________________
iselth |
|
Back to top |
|
 |
STN I post too much
Reputation: 43
Joined: 09 Nov 2005 Posts: 2676
|
Posted: Mon Nov 08, 2021 2:38 pm Post subject: |
|
|
can probably be done with lua (i don't know any and can't be bothered)
_________________
|
|
Back to top |
|
 |
Csimbi I post too much
Reputation: 97
Joined: 14 Jul 2007 Posts: 3325
|
Posted: Tue Nov 09, 2021 5:49 am Post subject: Re: help generate trainer lua +10 process id |
|
|
anglez wrote: | I can only select manually by testing but when I generate trainer it does not work because it grabs another process |
You need to write an auto-attach script that picks the right process.
Nobody except you knows how you are going to identify the right process though.
One way to go on about this would be using the image size, or, if that does not work, use signatures.
Once you have the logic in place, put that on a timer and check every 3-5 seconds that your PID is still valid, if not, destroy context and try to re-attach to the right process again.
Here's a template I use in my tables, this checks only the process name (you need to create your own process check routine):
Code: | PROCESS_NAME = 'BlaBlaBla.exe'
--------
-------- Check for process and auto attach if need be
--------
local autoAttachTimer = nil ---- Declaration for our static timer object (no destroy here!)
local autoAttachTimerInterval = 5000 ---- Timer in milliseconds
function clearUserDefinedSymbols()
local mv,sf = getMemoryViewForm()
if not mv.frmSymbolhandler then
local mvHidden
if not mv.Visible then mvHidden=true,mv.Show() end
mv.miuserdefinedsymbols:OnClick()
if mvHidden then mv.hide()end
sf = mv.frmSymbolhandler
sf.Hide()
else
sf = mv.frmSymbolhandler
end
if sf ~= nil then
local symbol
for i = sf.Listview1.Items.Count - 1, 0, -1 do
symbol = sf.Listview1.Items.Item[i].Caption
unregisterSymbol(symbol)
end
end
end
local function autoAttachTimer_tick(timer) ---- Timer callback
---- Check to see if we are attached to the right process
if getProcessIDFromProcessName(PROCESS_NAME) ~= getOpenedProcessID() then
---- If not the right process, check if process is running and attach if exists
AddressList.disableAllWithoutExecute()
clearUserDefinedSymbols()
if getProcessIDFromProcessName(PROCESS_NAME) ~= nil then
openProcess(PROCESS_NAME) ---- Open the process
end
end
end
autoAttachTimer = createTimer(getMainForm()) ---- Create timer with the main form as it's parent
autoAttachTimer.Interval = autoAttachTimerInterval ---- Set timer interval
autoAttachTimer.OnTimer = autoAttachTimer_tick ---- Set timer tick call back
|
|
|
Back to top |
|
 |
|