CGUnit_C__GetUnitName issue menu

User Tag List

Results 1 to 4 of 4
  1. #1
    derekman007's Avatar Member
    Reputation
    6
    Join Date
    Aug 2008
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    CGUnit_C__GetUnitName issue

    I am having a strange issue after reversing CGUnit_C__GetUnitName to get the name offsets for a Unit. The Unit name works for some targets and for target Marshal McBridge for example it shows some strange name.
    Also it seems some of the other properties of the Unit are not being read correctly either.

    Currently some of the offsets I am using are [6.0.3 19342]:
    Code:
    public enum Offsets : uint
            {
                version = 0xC7584F,
                curMgr = 0xCB9068,
                firstObject = 0xD8,
                nextObject = 0x3C,
                playerName = 0xED5CD0,
                objectType = 0xC,
                descriptors = 0x4,
                unitHealth = 0x0EC,
                unitPower = 0x0F0,
                unitHealthMax = 0x108,
                unitPowerMax = 0x10C,
                unitLevel = 0x154,
                guidOffset = 0x28,
                xOffset = 0xA80,
                yOffset = 0xA84,
                zOffset = 0xA88,
                rotOffset = 0xA8C,
                targetGUID = 0xD93AA8,
                mouseOverGUID = 0xD93A78
                npcCache = 0xBC4,
                npcName = 0x7C
            }
    This is the code for how I make the unit object:
    Code:
    WoWUnit unit = new WoWUnit();
    unit.baseAddress = curObject;
    unit.guid = wow.ReadUInt64(curObject + (uint)Offsets.guidOffset);
    unit.curHealth = wow.ReadInt(wow.ReadUInt(curObject + (uint)Offsets.descriptors) + (uint)Offsets.unitHealth);
    unit.maxHealth = wow.ReadInt(wow.ReadUInt(curObject + (uint)Offsets.descriptors) + (uint)Offsets.unitHealthMax);
    unit.curPower = wow.ReadInt(wow.ReadUInt(curObject + (uint)Offsets.descriptors) + (uint)Offsets.unitPower);
    unit.maxPower = wow.ReadInt(wow.ReadUInt(curObject + (uint)Offsets.descriptors) + (uint)Offsets.unitPowerMax);
    unit.x = wow.ReadFloat(curObject + (uint)Offsets.xOffset);
    unit.y = wow.ReadFloat(curObject + (uint)Offsets.yOffset);
    unit.z = wow.ReadFloat(curObject + (uint)Offsets.zOffset);
    unit.rotation = wow.ReadFloat(curObject + (uint)Offsets.rotOffset);
    unit.type = objType;
    unit.name = wow.ReadASCIIString(wow.ReadUInt(wow.ReadUInt(curObject + 0xBC4) + 0x7C), 40);
    Here is an image of what my GUI looks like with the problem:


    If anyone has any ideas of why this is happening I would appreciate any advice.

    Thanks for your time.

    CGUnit_C__GetUnitName issue
  2. #2
    fvicaria's Avatar Active Member
    Reputation
    29
    Join Date
    Jan 2009
    Posts
    55
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just by looking very quickly I spotted one issue... Guid should be 128 bits not 64.

  3. #3
    TOM_RUS's Avatar Legendary
    Reputation
    914
    Join Date
    May 2008
    Posts
    699
    Thanks G/R
    0/52
    Trade Feedback
    0 (0%)
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by fvicaria View Post
    Just by looking very quickly I spotted one issue... Guid should be 128 bits not 64.
    Yeah, probably half of guid is same for multiple units and as a result target unit is completely different from what is expected.

  4. #4
    derekman007's Avatar Member
    Reputation
    6
    Join Date
    Aug 2008
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by fvicaria View Post
    Just by looking very quickly I spotted one issue... Guid should be 128 bits not 64.
    Yeah that was the issue. After making the guid 128bit everything is working fine. Thanks.

Similar Threads

  1. Issues with Deeprun Tram exploit
    By shade599 in forum World of Warcraft Exploration
    Replies: 3
    Last Post: 03-25-2007, 08:01 AM
  2. !xSpeednet Issues
    By Taldeer in forum World of Warcraft General
    Replies: 5
    Last Post: 01-28-2007, 06:32 PM
  3. DBC More issues.
    By dela in forum WoW ME Questions and Requests
    Replies: 3
    Last Post: 09-29-2006, 07:46 PM
  4. patching issue
    By Marlo in forum World of Warcraft General
    Replies: 0
    Last Post: 07-22-2006, 07:35 PM
  5. [Patch 1.11] - Known Issues (6-20-06)
    By Cypher in forum World of Warcraft General
    Replies: 1
    Last Post: 06-24-2006, 12:42 AM
All times are GMT -5. The time now is 08:08 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