Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Tsearch float and Delphi?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
Müller
How do I cheat?
Reputation: 0

Joined: 22 Nov 2010
Posts: 5

PostPosted: Mon Nov 22, 2010 10:34 am    Post subject: Tsearch float and Delphi? Reply with quote

Hello guys,

I use tsearch for searching my adresses and to overwatch these. Now I have a problem. According to tsearch, the value of my adresse with the type float is 0. until 1.
Now I tried to write this 1. into the adress. But this don't work.
My Code:
Code:

var
HandleWindow: Integer;
temp: cardinal;
buf: Pchar;


GetMem(buf,4);
buf^ := Chr($3F800000);
WriteProcessMemory(HandleWindow,ptr($59A018),@buf,4,temp);
FreeMem(buf);

But in tsearch I see that it write not 1. but 8.229097206e-039.
I forgot: $3F800000 is the hex code for 1.

Maybe you can help me.

Thanks,
Müller
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 468

Joined: 09 May 2003
Posts: 25710
Location: The netherlands

PostPosted: Mon Nov 22, 2010 11:39 am    Post subject: Reply with quote

not sure, but I think chr only sets one byte and not multiple

anyhow, change
Code:

buf: pchar;

to:
Code:

value: single;


and change:
Code:

GetMem(buf,4);
buf^ := Chr($3F800000);
WriteProcessMemory(HandleWindow,ptr($59A018),@buf,4,temp);
FreeMem(buf);

to
Code:

value:=1;
WriteProcessMemory(HandleWindow,ptr($59A018),@value,sizeof(value),temp);

_________________
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
View user's profile Send private message MSN Messenger
Müller
How do I cheat?
Reputation: 0

Joined: 22 Nov 2010
Posts: 5

PostPosted: Tue Nov 23, 2010 9:46 am    Post subject: Reply with quote

Thank you very much.
That was the solution.
I can't say how much I'm happy that now this f**king shit work.
Thank you very much. Very Happy
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites