Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- G_ClientConnection = 0xEC4628
- CurMgrOffset = 0x462C
- FirstObject = 0xCC
- NextObject = 0x34
- LocalGuid = 0xE8
- TlsGuidOffset = 0x28; CurObject+TlsGuidoffset will return the GUID of desired object, can be used with CTM
- //Only need to be read every screenload
- ObjectMgr = Read(read(BaseModuleAdress + G_ClientConnection) + CurMgrOffset)
- //With this you can read guid from BaseModuleAdress + PlayerGuid to get its object
- function GetObjectFromGuid(uint64 guid){
- CurObject = Read(ObjectMgr + FirstObject)
- while (CurObject <> 0) {
- ;//If we match a guid in our objectMgr we can return the object and use it for all sorts of stuff, everthing has an guid
- if guid == read(CurObject+TlsGuidOffset) {
- return curObject; // <--
- }
- //Next object, always at the end of loop
- CurObject = read(curObject+NextObject)
- }
- }
- PlayerGuid = Read<uint64>(ObjectMgr+LocalGuid)
- PlayerObject = GetObjectFromGuid(PlayerGuid)
- //Get coords from object (Player and npc coords)
- x = 0x838
- y = x + 0x4
- z = x + 0x8
- r = x + 0x10
- read<float>(PlayerObject+x)
- read<float>(PlayerObject+y)
- read<float>(PlayerObject+z)
- If you use any other PlayerObject that will also work, as long the returned object is an type of 5 (Player and npc)
Advertisement
Add Comment
Please, Sign In to add comment