View previous topic :: View next topic |
Author |
Message |
nitrox How do I cheat?
Reputation: 0
Joined: 16 Mar 2013 Posts: 3
|
Posted: Sat Mar 30, 2013 10:34 pm Post subject: C++ XYZ Freeze Help |
|
|
Can someone please show me how they freeze x and y coords, This would be simple if i was dealing with a static value, But as im trying to read the current x and y and then freeze them if HP drops below 100. Im finding this really hard.
Thanks Guys
I will explain a little easier below.. keep reading lol.
If i want to get a freeze effect, I will use a while loop. This works Fine
Code: | while (1)
{
*(float*)0x123456 = 1000;
} | Ok now this is what im trying to do is below
Code: |
while (1)
{
*(float*)0x123456 = What ever value is currently stored in memory here;
} | So basicly i want to be able to loop the current value stored in memory at that moment in time, This value changes all the time..
Thank you
Last edited by nitrox on Sun Mar 31, 2013 8:17 am; edited 1 time in total |
|
Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8587 Location: 127.0.0.1
|
Posted: Sun Mar 31, 2013 7:25 am Post subject: |
|
|
You need to read the current value of the address into a buffer before you start your while loop to 'freeze' the value, then continuously write the new value to the address. Something like this:
Code: | void war( bool fEnable )
{
// Read the original value..
float fOriginal = *(float*)0x123456;
while (true)
{
// Write the original back constantly..
*(float*)0x123456 = fOriginal;
// Sleep to prevent 100% CPU usage..
Sleep( 10 );
//
// Add some code here to break the loop when needed..
//
}
} |
Or you can patch all the functions that write to the address to prevent anything from overwriting it instead. _________________
- Retired. |
|
Back to top |
|
 |
TsTg Master Cheater
Reputation: 5
Joined: 12 Dec 2012 Posts: 340 Location: Somewhere....
|
Posted: Sun Mar 31, 2013 7:33 am Post subject: |
|
|
I don't get exactly what you want to do with that code, but generally,I guess you need to copy the HP value to a new DWORD, the same way done to the co-ordinates (the first condition of your code copies them), so when you want to restore the co-ordinates, the HP value at that time, will be restored too. |
|
Back to top |
|
 |
nitrox How do I cheat?
Reputation: 0
Joined: 16 Mar 2013 Posts: 3
|
Posted: Sun Mar 31, 2013 8:06 am Post subject: |
|
|
I would just like to say, Thank you very much for the help.
I was going the wrong way about this, i managed to basicly just change a [EAX+30] value. now this locks my coords to current postion.
why am i so stupid lol,
once again thank you very much |
|
Back to top |
|
 |
|