View previous topic :: View next topic |
Author |
Message |
misha-cs Newbie cheater Reputation: 0
Joined: 02 Jul 2012 Posts: 12
|
Posted: Tue Mar 04, 2014 10:48 am Post subject: Kill Proc |
|
|
Hi!
How can I destroy a particular process, such as "Notepad"?
Reviewed all the features, but have not found an answer.
|
|
Back to top |
|
|
Gniarf Grandmaster Cheater Supreme Reputation: 43
Joined: 12 Mar 2012 Posts: 1285
|
Posted: Thu Mar 06, 2014 1:30 am Post subject: |
|
|
In lua, a simple way would be: Code: | os.execute("taskkill /im notepad.exe /f") |
_________________
DO NOT PM me if you want help on making/fixing/using a hack. |
|
Back to top |
|
|
misha-cs Newbie cheater Reputation: 0
Joined: 02 Jul 2012 Posts: 12
|
Posted: Thu Mar 06, 2014 12:30 pm Post subject: |
|
|
Thanks.
And one question:
How I can find HANDLE of window programm not a CE ?
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Thu Mar 06, 2014 12:54 pm Post subject: |
|
|
execute this auto assemble script (e.g using autoAssemble() )
Code: |
alloc(term,512)
term:
push 0
call ExitProcess
createthread(term)
|
_________________
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 |
|
|
misha-cs Newbie cheater Reputation: 0
Joined: 02 Jul 2012 Posts: 12
|
Posted: Thu Mar 06, 2014 2:47 pm Post subject: |
|
|
How with HANDLE window ?
Thanks
|
|
Back to top |
|
|
Gniarf Grandmaster Cheater Supreme Reputation: 43
Joined: 12 Mar 2012 Posts: 1285
|
Posted: Thu Mar 06, 2014 3:14 pm Post subject: |
|
|
misha-cs wrote: | How I can find HANDLE of window programm not a CE ? | If you meant "How to get the handle of a window that doesn't belong to CE", here's one way:
Code: | function CallFindWindowA(WindowName)
--keep window names below 256 characters.
--lpClassName is set to NULL
local FindWindowAStub;
--Looks like the [64-bit] and [32-bit] directives don't work in FindWindowAStub.
if (cheatEngineIs64Bit()) then
FindWindowAStub=[[
globalalloc(FindWindowMemory,1024) //global alloc instead of alloc: see CleanupFindWindowAStub
label(WindowName_)
label(FindWindowAResult)
label(FindWindowADone)
registersymbol(WindowName_)
registersymbol(FindWindowAResult)
registersymbol(FindWindowADone)
FindWindowMemory:
mov rdx, WindowName_
xor rcx,rcx //LpClassName=NULL
call FindWindowA
mov qword [FindWindowAResult],rax
mov dword [FindWindowADone],1
retn
FindWindowAResult:
dq 0
FindWindowADone:
dd 0
WindowName_:
dq 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 //256 bytes
]];
else
FindWindowAStub=[[
globalalloc(FindWindowMemory,1024) //global alloc instead of alloc: see CleanupFindWindowAStub
label(WindowName_)
label(FindWindowAResult)
label(FindWindowADone)
registersymbol(WindowName_)
registersymbol(FindWindowAResult)
registersymbol(FindWindowADone)
FindWindowMemory:
push, WindowName_
push 0 //LpClassName=NULL
call FindWindowA
mov dword [FindWindowAResult],eax
mov dword [FindWindowADone],1
retn
FindWindowAResult:
dd 0
FindWindowADone:
dd 0
WindowName_:
dq 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 //256 bytes
]];
end
local RunFindWindowAStub = "createthread(FindWindowMemory)";
local CleanupFindWindowAStub = [[
dealloc(FindWindowMemory) //taskman inspection shows that dealloc (with a simple alloc) doens't seem to work on CE itself
//unregistersymbol(FindWindowMemory)
unregistersymbol(WindowName_)
unregistersymbol(FindWindowAResult)
unregistersymbol(FindWindowADone)]];
--initialize the FindWindowA caller
autoAssemble(FindWindowAStub,true);
--give the parameter
writeStringLocal("WindowName_",WindowName);
--run the function
autoAssemble(RunFindWindowAStub,true);
--wait till done
while(readIntegerLocal("FindWindowADone")==0) do
sleep(10);
end
--fetch result
local WindowHandle;
if (cheatEngineIs64Bit()) then
WindowHandle=readQwordLocal("FindWindowAResult");
else
WindowHandle=readIntegerLocal("FindWindowAResult");
end
--cleanup
autoAssemble(CleanupFindWindowAStub,true);
return WindowHandle;
end
print(string.format("%x",CallFindWindowA("Untitled - Notepad"))); | Mind you, I really wonder what you want to do with that though.
_________________
DO NOT PM me if you want help on making/fixing/using a hack. |
|
Back to top |
|
|
bknight2602 Grandmaster Cheater Reputation: 0
Joined: 08 Oct 2012 Posts: 577
|
Posted: Sun Mar 30, 2014 12:44 pm Post subject: |
|
|
On a similar vein, what would be the code to close CE if/when the process it is pointing toward is closed?
|
|
Back to top |
|
|
Keule Cheater Reputation: 0
Joined: 08 Aug 2012 Posts: 25
|
Posted: Mon Mar 31, 2014 5:40 am Post subject: |
|
|
bknight2602 wrote: | On a similar vein, what would be the code to close CE if/when the process it is pointing toward is closed? |
use this:
Code: |
GameExeFile = 'game.exe'
-- rename it with youe .exe file or something else
t = createTimer(nil, true)
t.Interval = 100
t.onTimer = _CheckGameStatus
function _CheckGameStatus() if readInteger(GameExeFile) == nil then closeCE() end end |
-- edited t.Interval to 100
Last edited by Keule on Mon Mar 31, 2014 11:19 am; edited 1 time in total |
|
Back to top |
|
|
mgr.inz.Player I post too much Reputation: 218
Joined: 07 Nov 2008 Posts: 4438 Location: W kraju nad Wisla. UTC+01:00
|
Posted: Mon Mar 31, 2014 8:01 am Post subject: |
|
|
Agree. I also recommend bigger Interval, for example 100 or 500.
_________________
|
|
Back to top |
|
|
bknight2602 Grandmaster Cheater Reputation: 0
Joined: 08 Oct 2012 Posts: 577
|
Posted: Mon Mar 31, 2014 4:24 pm Post subject: |
|
|
Thanks to both
|
|
Back to top |
|
|
|