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 


C++ Change Player Name ?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
B14CKS1D3
Cheater
Reputation: 0

Joined: 30 Jul 2014
Posts: 26

PostPosted: Tue Aug 04, 2015 2:51 pm    Post subject: C++ Change Player Name ? Reply with quote

How can I change string in C++ ? Here's what I have currently, which crashes.
The process is 64 bits
Code:
   void SetName(char* name){
      __int64 Pointer = NameChangeAddress;//0x012345...
      __int64 addr = *(__int64*)(GetModuleBase(GetCurrentProcess(), string("Process.exe")) + NameChangeAddress);
      *(char**)addr = name;//Also tried with *(string*)
   }
   
Back to top
View user's profile Send private message
justa_dude
Grandmaster Cheater
Reputation: 23

Joined: 29 Jun 2010
Posts: 891

PostPosted: Tue Aug 04, 2015 7:53 pm    Post subject: Reply with quote

Is this within a DLL that has been successfully injected into the target process or not? You should always check return values from API calls. You can step through your code or create trace messages to see what each value is and it should be obvious where you're going wrong.
_________________
A nagy kapu mellett, mindig van egy kis kapu.
----------------------
Come on...
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 Gamehacking 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