Read Name menu

Shout-Out

User Tag List

Thread: Read Name

Results 1 to 6 of 6
  1. #1
    Eviin's Avatar Private
    Reputation
    1
    Join Date
    Jun 2012
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Read Name

    Hey everyone,

    im writing a bot for myself and i have a problem with reading the playerName.
    ( Official Servers )

    I use Delphi for programming.


    The Result of my Code is that the Function who reads the playerName returns an Integer ( converted into string )

    Can anyone help me? ^^

    Code:
    Constants.pas
    Code:
    unit Constants;
    
    interface
    
    const
    	OBJECT_FIELD_GUID     = $0;
    	OBJECT_FIELD_DATA     = $2;
    	OBJECT_FIELD_TYPE     = $4;
    	OBJECT_FIELD_ENTRY    = $5;
    	OBJECT_FIELD_SCALE_X  = $6;
    	OBJECT_FIELD_PADDING  = $7;
    	OBJECT_END            = $8;
    
      playerName            = $9BE820;
      currentRealm          = $9BE9AE;
      UNIT_FIELD_HEALTH     = $68;
    
      playerBase            = $00A70C50;
      playerBaseOff1        = $34;
      playerBaseOff2        = $24;
    
    implementation
    
    end.
    Main:
    Code:
    procedure TMain.Start1Click(Sender: TObject);
    var
    returnedINT : Integer;
    begin
     returnedINT := _MemReadInt(playerName, 16);
     playerNameLabel.Caption := inttostr(returnedINT);
    end;
    _MemReadInt [email protected]

    Read Name
  2. #2
    Frosttall's Avatar Active Member
    Reputation
    64
    Join Date
    Feb 2011
    Posts
    261
    Thanks G/R
    16/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can't convert an Integer to a string like this.

    The name gets stored as a pointer as member of WowObject. You have to read that pointer and then read the amount of bytes at the pointed address of the chars you want to have.

  3. #3
    Eviin's Avatar Private
    Reputation
    1
    Join Date
    Jun 2012
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    How can i do that,
    do you have an example?

  4. #4
    Cen01's Avatar Banned
    Reputation
    92
    Join Date
    Dec 2011
    Posts
    53
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    edit: delete me
    Last edited by Cen01; 06-27-2012 at 01:17 PM.

  5. #5
    Eviin's Avatar Private
    Reputation
    1
    Join Date
    Jun 2012
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    @Cen01
    Why you delete your Post?
    It helped me, so thanks anyway

  6. #6
    radarlove's Avatar Contributor
    Reputation
    158
    Join Date
    Jun 2012
    Posts
    205
    Thanks G/R
    2/11
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    I'm a Delphi programmer as well. Here's how i read the (max 20 length/zero terminated) charactername, i read it byte by byte:


    Code:
    function ReadCharacterName(iPid: Integer; iAddress: Cardinal): String;
    var
      bytesRead: Cardinal;
      PidHandle: Integer;
      myResult: Cardinal;
      lLooper: Boolean;
      lLoopValue: Integer;
      lString: String;
      lIndex: Integer;
    begin
      bytesRead:= 0;
      Pidhandle := OpenProcess(PROCESS_VM_READ,False,iPid); 
      lLooper := True;
      lLoopValue := 0;
      lIndex := 1;
      lString := '';
      while lLooper and (lIndex  <= 20) do
      begin
        ReadProcessMemory(PidHandle, ptr(iAddress + lLoopValue), @myResult, 1, bytesRead);
        if chr(myResult) = #0 then 
          lLooper := False
        else
        begin
          lString := lString + Chr(myResult);
          lLoopValue := lLoopValue + 1;
        end;
        lIndex := lIndex + 1;
      end;
      closehandle(Pidhandle);
      Result := lString;
    end;

    function input: the process id and the modulebaseadress+playername offset. I suppose you have the function to get the module baseaddress, can post that as well if you like.
    I also see the CurrentRealm offset in you're code. Can be read in the exact same way as the charactername, maybe change the max length offset.

    Good luck!

Similar Threads

  1. ObjectManager stuck on reading names
    By kosacid in forum WoW Memory Editing
    Replies: 12
    Last Post: 05-31-2012, 01:45 PM
  2. Reading unit name
    By miceiken in forum WoW Memory Editing
    Replies: 10
    Last Post: 04-08-2009, 10:15 PM
  3. [?] Reading Object Name
    By Smarter in forum WoW Memory Editing
    Replies: 4
    Last Post: 04-03-2009, 08:03 PM
  4. Can you read player names out of process?
    By sweeper18 in forum WoW Memory Editing
    Replies: 10
    Last Post: 07-06-2008, 08:54 PM
  5. Reveal name of one who reads threads command?
    By Lucifear in forum Community Chat
    Replies: 3
    Last Post: 09-23-2007, 12:21 PM
All times are GMT -5. The time now is 01:45 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search