View previous topic :: View next topic |
Author |
Message |
Filipe_Br Master Cheater
Reputation: 3
Joined: 07 Jan 2016 Posts: 272 Location: My house
|
Posted: Mon Dec 05, 2016 4:08 pm Post subject: Hide the mouse. |
|
|
To leave a hack that I created for a game, I would like that certain moments the mouse was hidden.
How can I do this?
_________________
... |
|
Back to top |
|
 |
ParkourPenguin I post too much
Reputation: 152
Joined: 06 Jul 2014 Posts: 4702
|
Posted: Mon Dec 05, 2016 7:17 pm Post subject: |
|
|
Call ShowCursor from whatever thread created the window.
_________________
I don't know where I'm going, but I'll figure it out when I get there. |
|
Back to top |
|
 |
Filipe_Br Master Cheater
Reputation: 3
Joined: 07 Jan 2016 Posts: 272 Location: My house
|
Posted: Tue Dec 06, 2016 5:46 am Post subject: |
|
|
It's more like I can make a script in Lua or assembly. Because with this information, I still do not know how to hide the mouse.
_________________
... |
|
Back to top |
|
 |
ParkourPenguin I post too much
Reputation: 152
Joined: 06 Jul 2014 Posts: 4702
|
Posted: Tue Dec 06, 2016 8:57 am Post subject: |
|
|
assembly:
Code: | push 0
call User32.ShowCursor |
_________________
I don't know where I'm going, but I'll figure it out when I get there. |
|
Back to top |
|
 |
Filipe_Br Master Cheater
Reputation: 3
Joined: 07 Jan 2016 Posts: 272 Location: My house
|
Posted: Tue Dec 06, 2016 12:59 pm Post subject: |
|
|
I guess just showing me step by step '-'.
I have two doubts.
1 - For either this "push 0"
2 - How exactly I use this script to disappear and show the mouse, in the window of a certain game.
Code: |
openProcess("Tutorial-x86_64.exe")
autoAssemble([[
alloc(code, 2000)
createthread(code)
code:
push 0
call User32.ShowCursor
ret
]]) |
This script just makes the tutorial stop working
_________________
... |
|
Back to top |
|
 |
ParkourPenguin I post too much
Reputation: 152
Joined: 06 Jul 2014 Posts: 4702
|
Posted: Tue Dec 06, 2016 1:16 pm Post subject: |
|
|
1 - I don't know what you're trying to say. push 0 is pushing an argument onto the stack. It's the stdcall calling convention. For 64-bit calling conventions, see this.
2 - That's why I said it needs to be executed from whatever thread created the window.
If you want to do it from some other thread like that, then the first thing that comes to my mind is hooking the window's WndProc function and writing code to handle a user window message. Then just send a message to the window however you want that tells it whether it should show its cursor or not.
I will not show you how to do that step by step since I would be here all day. Learn the basics first (e.g. how to call a function). I'm sure there are some tutorials you can find online.
_________________
I don't know where I'm going, but I'll figure it out when I get there. |
|
Back to top |
|
 |
Filipe_Br Master Cheater
Reputation: 3
Joined: 07 Jan 2016 Posts: 272 Location: My house
|
Posted: Tue Dec 06, 2016 1:24 pm Post subject: |
|
|
I'll see if I find out, it's going to be difficult, after all I do not speak English, and the best information is in English.
_________________
... |
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Tue Dec 06, 2016 1:51 pm Post subject: |
|
|
If you're not sure how to call a function, you can try manipulating internal, game values to achieve the desired effect.
Depending on how the target was programed, the cursor may have an on/off boolean that can be found, a transparency value and/or a size modifier etc. - all of which may be used, depending.
Sometimes, just switching over to joystick can automatically remove the mouse from the screen, providing scan opportunities.
Finding mouse coordinates may get you a size modifier or allow you to force the mouse off-screen, rendering it useless.
Pausing target, entering a special sub-menu/screen and or performing scans during cinematic sequences or the like may get you an on/off boolean...and etcetera...
Worst-case scenario, you can bulk-edit values of 3F800000 (float 1.0) to 0 and see what happens.
|
|
Back to top |
|
 |
|