| View previous topic :: View next topic |
| Author |
Message |
Gwinx Advanced Cheater
Reputation: 0
Joined: 30 Jul 2010 Posts: 65
|
Posted: Sat Oct 20, 2012 9:15 pm Post subject: CE Scripting |
|
|
When developing a script in Cheat Engine's auto assembler, is it possible to call a Window API? For an example
[enable]
alloc(FindWindow,123)
...
FindWindow:
push ... (parameter 1 - ClassName)
push ... (parameter 2 - WindowName)
call User32.FindWindowA
[disable]
...
|
|
| Back to top |
|
 |
Dark Byte Site Admin
Reputation: 473
Joined: 09 May 2003 Posts: 25918 Location: The netherlands
|
Posted: Sun Oct 21, 2012 12:29 am Post subject: |
|
|
Yes, exactly like that, but you must push the variables in the opposite direction , first param2, then param1, then the call
_________________
Tools give you results. Knowledge gives you control.
Like my help? Join me on Patreon so i can keep helping |
|
| Back to top |
|
 |
Gwinx Advanced Cheater
Reputation: 0
Joined: 30 Jul 2010 Posts: 65
|
Posted: Sun Oct 21, 2012 4:25 pm Post subject: |
|
|
| Dark Byte wrote: | | Yes, exactly like that, but you must push the variables in the opposite direction , first param2, then param1, then the call |
Thanks. But for some reason, when I call user32.FindWindowA it says something like, "user32.FindWindowA this instruction can't be compiled". Is it a bug? :0
|
|
| Back to top |
|
 |
Dark Byte Site Admin
Reputation: 473
Joined: 09 May 2003 Posts: 25918 Location: The netherlands
|
Posted: Sun Oct 21, 2012 5:22 pm Post subject: |
|
|
the following script orks fine for me:
| Code: |
[enable]
alloc(FindWindow, 4096)
FindWindow:
push 0
push 0
call User32.FindWindowA
[disable]
|
Just make sure you have targeted a process when editing the script
_________________
Tools give you results. Knowledge gives you control.
Like my help? Join me on Patreon so i can keep helping |
|
| Back to top |
|
 |
Gwinx Advanced Cheater
Reputation: 0
Joined: 30 Jul 2010 Posts: 65
|
Posted: Wed Oct 24, 2012 5:53 pm Post subject: |
|
|
| Dark Byte wrote: | the following script orks fine for me:
| Code: |
[enable]
alloc(FindWindow, 4096)
FindWindow:
push 0
push 0
call User32.FindWindowA
[disable]
|
Just make sure you have targeted a process when editing the script |
You solved my problem, thank you! I love you.
|
|
| Back to top |
|
 |
|