WoW Memory EditingWoW Memory Editing for learning purposes only.
This section is more advanced than others on MMOwnedRead the section specific rules, infractions will be given out if u break them!That is including the expectations! - If you don't meet them then don't post
Here is the WMO Indexer example updated for 3.2.2b
This is used to gather data from WMO's currently loaded (nearby) directly from the memory. The script is made so that it is easy to extend to get any data you need.
This example will print some of the data, you can see a example of the output data here: [Only registered and activated users can see links. ]
Code:
#RequireAdmin
;;================================================================================
;;SETTINGS
;;================================================================================
global $WMOIndexOffset = 0x01318678 ;//This offset is the Only thing you need to change every patch.
global $detailMOGI = 0 ;//Output Flag Data
global $detailMODN = 1 ;//Output M2 file names
;;================================================================================
;;INCLUDE DEFINITION
;;================================================================================
#include <NomadMemory.au3>
#include <ListboxConstants.au3>
#include <WindowsConstants.au3>
#include <GUIConstantsEx.au3>
;;================================================================================
;;BASIC WOW APP START
;;================================================================================
Opt("GUIOnEventMode", 1)
GUISetOnEvent($GUI_EVENT_CLOSE, "exitnow")
global $Listview
dim $WMOsetname_M2[1]
$MainGUI = GUICreate("WMO INDEXER by Malu05",700,500)
$ListView = GUICtrlCreateList("",0,0,700,500, bitor($WS_BORDER, $WS_VSCROLL))
GUISetState()
GUISetOnEvent($GUI_EVENT_CLOSE, "exitnow")
;;================================================================================
;;PRE PREPERATION
;;================================================================================
SetPrivilege("SeDebugPrivilege", 1)
$list = ProcessList("wow.exe")
if $list[0][0] = 0 Then
MsgBox(0,0,"Unable to detect WoW.exe running")
exit
EndIf
$wow = _memoryopen($list[1][1])
if FileExists("WMO_Output.txt") then FileDelete("WMO_Output.txt")
WMOINDEX()
;;================================================================================
;;WMO Indexing
;;================================================================================
Func WMOINDEX()
WriteOutput("---INGAME WMO INDEXER By MALU05---" & "")
$mainWMOindex = _MemoryRead($WMOIndexOffset, $wow, 'ptr')
WriteOutput("")
for $i = 0 to 30 step +1
if $mainWMOindex <> 0x00000000 Then
$_WSMainOffs = $mainWMOindex
$_WSName = _MemoryRead($mainWMOindex + 0x1C, $wow, 'char[700]')
;find number of names
$_WSLinkToWmoMOHD = _MemoryRead($mainWMOindex + 0x120, $wow, 'ptr')
$_WSLinkToWmoMOTX = _MemoryRead($mainWMOindex + 0x120, $wow, 'ptr') ;!!this one is wrong...
$_WSLinkToWmoMOMT = _MemoryRead($mainWMOindex + 0x124, $wow, 'ptr')
$_WSLinkToMOGN = _MemoryRead($mainWMOindex + 0x128, $wow, 'ptr')
$_WSLinkToWmoMOSB = _MemoryRead($mainWMOindex + 0x12C, $wow, 'ptr') ;lol?
$_WSLinkToWmoMOGI = _MemoryRead($mainWMOindex + 0x130, $wow, 'ptr') ;lol?
$_WSLinkToWmoMOPV = _MemoryRead($mainWMOindex + 0x134, $wow, 'ptr')
$_WSLinkToWmoMOPT = _MemoryRead($mainWMOindex + 0x138, $wow, 'ptr')
$_WSLinkToWmoMOPR = _MemoryRead($mainWMOindex + 0x13C, $wow, 'ptr')
$_WSLinkToWmoMOVV = _MemoryRead($mainWMOindex + 0x140, $wow, 'ptr')
$_WSLinkToWmoMOVB = _MemoryRead($mainWMOindex + 0x144, $wow, 'ptr')
$_WSLinkToWmoMOLT = _MemoryRead($mainWMOindex + 0x148, $wow, 'ptr')
$_WSLinkToWmoMODS = _MemoryRead($mainWMOindex + 0x14C, $wow, 'ptr')
$_WSLinkToWmoMODN = _MemoryRead($mainWMOindex + 0x150, $wow, 'ptr')
$_WSLinkToWmoMODD = _MemoryRead($mainWMOindex + 0x154, $wow, 'ptr')
$_WSLinkToWmoMFOG = _MemoryRead($mainWMOindex + 0x158, $wow, 'ptr')
$_WSLinkToWmoMCVP = _MemoryRead($mainWMOindex + 0x15C, $wow, 'ptr')
$_WSLinkToWmo = _MemoryRead($mainWMOindex + 0x1C8, $wow, 'ptr')
$_WSNoOfNames = _MemoryRead($_WSLinkToWmo + 0x18, $wow, 'int')
;find each subgroup
$WMOm2setname = _MemoryRead($_WSLinkToWmoMODS + 0x0, $wow, 'char[20]')
$WMOm2setindex = _MemoryRead($_WSLinkToWmoMODS + 0x14, $wow, 'int')
$WMOm2setnr = _MemoryRead($_WSLinkToWmoMODS + 0x18, $wow, 'int')
$WMOm2Nnr = _MemoryRead($_WSLinkToWmoMOHD + 0x10, $wow, 'int')
WriteOutput("#######################################################################################################" &"")
WriteOutput("Loading WMO Nr. " & $i & "")
WriteOutput("Located at: " & $mainWMOindex & "")
WriteOutput("FileName: " & $_WSName & "")
WriteOutput("Number Of SUB WMO's: " & $_WSNoOfNames &"")
WriteOutput("Number of Models: " & $WMOm2Nnr &"")
WriteOutput("Model Set Name: " & $WMOm2setname &"")
WriteOutput("Number of set models: " & $WMOm2setnr &"") ;Flags from MOGI
WriteOutput("-------------------------------------------------------------------------------------------------------" &"")
;//==================================================
;// Look through the MODN list and index filenames.
;//==================================================
redim $WMOsetname_M2[$WMOm2Nnr+1]
writeoutput("List of filenames for M2 models that appear in this WMO." &"")
writeoutput("")
if $WMOm2Nnr = 0 Then WriteOutput("//This file does not contain any M2 Objects "&"")
for $i2 = 1 to $WMOm2Nnr step + 1
$plaus = 1
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x0, $wow, 'char[700]')
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x1, $wow, 'char[700]')
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x2, $wow, 'char[700]')
$plaus = 2
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x3, $wow, 'char[700]')
$plaus = 3
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x4, $wow, 'char[700]')
$plaus = 4
EndIf
EndIf
EndIf
EndIf
$WMOsetname_M2[$i2] = StringReplace($WMOsetname,"MDX","M2")
if $detailMODN = 1 Then writeoutput($_WSLinkToWmoMODN & @TAB & $WMOsetname_M2[$i2] &"")
$_WSLinkToWmoMODN = $_WSLinkToWmoMODN + stringlen($WMOsetname) +$plaus
Next
writeoutput("" &"")
;//==================================================
;// Look through the MOGN list and index filenames.
;//==================================================
writeoutput("_______________________________________________________________________________________________________" &"")
writeoutput("Data for SUB WMO's." &"")
writeoutput("")
if $_WSNoOfNames = 0 Then WriteOutput("//This file does not contain any SUB WMO's "&"")
for $i2 = 1 to $_WSNoOfNames step + 1
$flag = _MemoryRead($_WSLinkToWmoMOGI, $wow, 'int')
$valueFlags = _MemoryRead($_WSLinkToWmoMOGI, $wow, 'ushort')
$valueFlagName = _MemoryRead($_WSLinkToWmo, $wow, 'int')
$plaus = 1
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x0, $wow, 'char[700]')
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x1, $wow, 'char[700]')
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x2, $wow, 'char[700]')
$plaus = 2
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x3, $wow, 'char[700]')
EndIf
EndIf
EndIf
$_WSLinkToMOGN = $_WSLinkToMOGN + stringlen($WMOeditorname) +$plaus
;//Announce Data
WriteOutput("SubWMO Located at: " & $_WSLinkToWmoMOGI & " " & @tab & " IndexName: " &$WMOeditorname &"")
if $detailMOGI = 1 Then WriteOutput(@TAB & "*Flags: " & " " & @tab & $valueFlags &"") ;Flags from MOGI
$_WSLinkToWmoMOGI = $_WSLinkToWmoMOGI + 0x20
Next
WriteOutput("")
WriteOutput("=======================================================================================================" &"")
WriteOutput("")
$mainWMOindex = _MemoryRead($mainWMOindex + 0x14, $wow, 'ptr')
EndIf
Next
EndFunc
Run("Notepad.exe " & @scriptdir&"/WMO_Output.txt", "")
while 1
WEnd
func WriteOutput($_input)
if $_input = "" then $_input = " "
GUICtrlSetData($ListView, stringreplace($_input,@TAB,""))
ConsoleWrite($_input &@CRLF)
FileWriteLine("WMO_Output.txt",$_input)
EndFunc
func ExitNow()
Exit
endFunc
Quote:
(9:47:33 PM) Sychotix: you know, 99% of people don't know wtf t odo with all that nice shit you post? =P (9:47:40 PM) Mads Lund: Hehe (9:47:47 PM) Mads Lund: I do use it alot (9:47:54 PM) Mads Lund: So there might be someone else who need it
Last edited by UnknOwned; 09-26-2009 at 04:58 PM.
Donate to remove ads, get your "DONATOR title, and get access to the MMOwned community's elite Shoutbawx.
Here is the WMO Indexer example updated for 3.2.2b
This is used to gather data from WMO's currently loaded (nearby) directly from the memory. The script is made so that it is easy to extend to get any data you need.
This example will print some of the data, you can see a example of the output data here: [Only registered and activated users can see links. ]
Code:
#RequireAdmin
;;================================================================================
;;SETTINGS
;;================================================================================
global $WMOIndexOffset = 0x01318678 ;//This offset is the Only thing you need to change every patch.
global $detailMOGI = 0 ;//Output Flag Data
global $detailMODN = 1 ;//Output M2 file names
;;================================================================================
;;INCLUDE DEFINITION
;;================================================================================
#include <NomadMemory.au3>
#include <ListboxConstants.au3>
#include <WindowsConstants.au3>
#include <GUIConstantsEx.au3>
;;================================================================================
;;BASIC WOW APP START
;;================================================================================
Opt("GUIOnEventMode", 1)
GUISetOnEvent($GUI_EVENT_CLOSE, "exitnow")
global $Listview
dim $WMOsetname_M2[1]
$MainGUI = GUICreate("WMO INDEXER by Malu05",700,500)
$ListView = GUICtrlCreateList("",0,0,700,500, bitor($WS_BORDER, $WS_VSCROLL))
GUISetState()
GUISetOnEvent($GUI_EVENT_CLOSE, "exitnow")
;;================================================================================
;;PRE PREPERATION
;;================================================================================
SetPrivilege("SeDebugPrivilege", 1)
$list = ProcessList("wow.exe")
if $list[0][0] = 0 Then
MsgBox(0,0,"Unable to detect WoW.exe running")
exit
EndIf
$wow = _memoryopen($list[1][1])
if FileExists("WMO_Output.txt") then FileDelete("WMO_Output.txt")
WMOINDEX()
;;================================================================================
;;WMO Indexing
;;================================================================================
Func WMOINDEX()
WriteOutput("---INGAME WMO INDEXER By MALU05---" & "")
$mainWMOindex = _MemoryRead($WMOIndexOffset, $wow, 'ptr')
WriteOutput("")
for $i = 0 to 30 step +1
if $mainWMOindex <> 0x00000000 Then
$_WSMainOffs = $mainWMOindex
$_WSName = _MemoryRead($mainWMOindex + 0x1C, $wow, 'char[700]')
;find number of names
$_WSLinkToWmoMOHD = _MemoryRead($mainWMOindex + 0x120, $wow, 'ptr')
$_WSLinkToWmoMOTX = _MemoryRead($mainWMOindex + 0x120, $wow, 'ptr') ;!!this one is wrong...
$_WSLinkToWmoMOMT = _MemoryRead($mainWMOindex + 0x124, $wow, 'ptr')
$_WSLinkToMOGN = _MemoryRead($mainWMOindex + 0x128, $wow, 'ptr')
$_WSLinkToWmoMOSB = _MemoryRead($mainWMOindex + 0x12C, $wow, 'ptr') ;lol?
$_WSLinkToWmoMOGI = _MemoryRead($mainWMOindex + 0x130, $wow, 'ptr') ;lol?
$_WSLinkToWmoMOPV = _MemoryRead($mainWMOindex + 0x134, $wow, 'ptr')
$_WSLinkToWmoMOPT = _MemoryRead($mainWMOindex + 0x138, $wow, 'ptr')
$_WSLinkToWmoMOPR = _MemoryRead($mainWMOindex + 0x13C, $wow, 'ptr')
$_WSLinkToWmoMOVV = _MemoryRead($mainWMOindex + 0x140, $wow, 'ptr')
$_WSLinkToWmoMOVB = _MemoryRead($mainWMOindex + 0x144, $wow, 'ptr')
$_WSLinkToWmoMOLT = _MemoryRead($mainWMOindex + 0x148, $wow, 'ptr')
$_WSLinkToWmoMODS = _MemoryRead($mainWMOindex + 0x14C, $wow, 'ptr')
$_WSLinkToWmoMODN = _MemoryRead($mainWMOindex + 0x150, $wow, 'ptr')
$_WSLinkToWmoMODD = _MemoryRead($mainWMOindex + 0x154, $wow, 'ptr')
$_WSLinkToWmoMFOG = _MemoryRead($mainWMOindex + 0x158, $wow, 'ptr')
$_WSLinkToWmoMCVP = _MemoryRead($mainWMOindex + 0x15C, $wow, 'ptr')
$_WSLinkToWmo = _MemoryRead($mainWMOindex + 0x1C8, $wow, 'ptr')
$_WSNoOfNames = _MemoryRead($_WSLinkToWmo + 0x18, $wow, 'int')
;find each subgroup
$WMOm2setname = _MemoryRead($_WSLinkToWmoMODS + 0x0, $wow, 'char[20]')
$WMOm2setindex = _MemoryRead($_WSLinkToWmoMODS + 0x14, $wow, 'int')
$WMOm2setnr = _MemoryRead($_WSLinkToWmoMODS + 0x18, $wow, 'int')
$WMOm2Nnr = _MemoryRead($_WSLinkToWmoMOHD + 0x10, $wow, 'int')
WriteOutput("#######################################################################################################" &"")
WriteOutput("Loading WMO Nr. " & $i & "")
WriteOutput("Located at: " & $mainWMOindex & "")
WriteOutput("FileName: " & $_WSName & "")
WriteOutput("Number Of SUB WMO's: " & $_WSNoOfNames &"")
WriteOutput("Number of Models: " & $WMOm2Nnr &"")
WriteOutput("Model Set Name: " & $WMOm2setname &"")
WriteOutput("Number of set models: " & $WMOm2setnr &"") ;Flags from MOGI
WriteOutput("-------------------------------------------------------------------------------------------------------" &"")
;//==================================================
;// Look through the MODN list and index filenames.
;//==================================================
redim $WMOsetname_M2[$WMOm2Nnr+1]
writeoutput("List of filenames for M2 models that appear in this WMO." &"")
writeoutput("")
if $WMOm2Nnr = 0 Then WriteOutput("//This file does not contain any M2 Objects "&"")
for $i2 = 1 to $WMOm2Nnr step + 1
$plaus = 1
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x0, $wow, 'char[700]')
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x1, $wow, 'char[700]')
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x2, $wow, 'char[700]')
$plaus = 2
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x3, $wow, 'char[700]')
$plaus = 3
if $WMOsetname = "" or $WMOsetname = " "Then
$WMOsetname = _MemoryRead($_WSLinkToWmoMODN + 0x4, $wow, 'char[700]')
$plaus = 4
EndIf
EndIf
EndIf
EndIf
$WMOsetname_M2[$i2] = StringReplace($WMOsetname,"MDX","M2")
if $detailMODN = 1 Then writeoutput($_WSLinkToWmoMODN & @TAB & $WMOsetname_M2[$i2] &"")
$_WSLinkToWmoMODN = $_WSLinkToWmoMODN + stringlen($WMOsetname) +$plaus
Next
writeoutput("" &"")
;//==================================================
;// Look through the MOGN list and index filenames.
;//==================================================
writeoutput("_______________________________________________________________________________________________________" &"")
writeoutput("Data for SUB WMO's." &"")
writeoutput("")
if $_WSNoOfNames = 0 Then WriteOutput("//This file does not contain any SUB WMO's "&"")
for $i2 = 1 to $_WSNoOfNames step + 1
$flag = _MemoryRead($_WSLinkToWmoMOGI, $wow, 'int')
$valueFlags = _MemoryRead($_WSLinkToWmoMOGI, $wow, 'ushort')
$valueFlagName = _MemoryRead($_WSLinkToWmo, $wow, 'int')
$plaus = 1
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x0, $wow, 'char[700]')
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x1, $wow, 'char[700]')
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x2, $wow, 'char[700]')
$plaus = 2
if $WMOeditorname = "" or $WMOeditorname = " "Then
$WMOeditorname = _MemoryRead($_WSLinkToMOGN + 0x3, $wow, 'char[700]')
EndIf
EndIf
EndIf
$_WSLinkToMOGN = $_WSLinkToMOGN + stringlen($WMOeditorname) +$plaus
;//Announce Data
WriteOutput("SubWMO Located at: " & $_WSLinkToWmoMOGI & " " & @tab & " IndexName: " &$WMOeditorname &"")
if $detailMOGI = 1 Then WriteOutput(@TAB & "*Flags: " & " " & @tab & $valueFlags &"") ;Flags from MOGI
$_WSLinkToWmoMOGI = $_WSLinkToWmoMOGI + 0x20
Next
WriteOutput("")
WriteOutput("=======================================================================================================" &"")
WriteOutput("")
$mainWMOindex = _MemoryRead($mainWMOindex + 0x14, $wow, 'ptr')
EndIf
Next
EndFunc
Run("Notepad.exe " & @scriptdir&"/WMO_Output.txt", "")
while 1
WEnd
func WriteOutput($_input)
if $_input = "" then $_input = " "
GUICtrlSetData($ListView, stringreplace($_input,@TAB,""))
ConsoleWrite($_input &@CRLF)
FileWriteLine("WMO_Output.txt",$_input)
EndFunc
func ExitNow()
Exit
endFunc