private static uint FrameScript_ExecuteBuffer = 0x43C010;
private static uint FrameScript__GetLocalizedText = 0x1BB0C0;
private static uint ClntObjMgrGetActivePlayerObj = 0x3410;
i am sure i have added wowbaseaddress on all the offset,but don't work out with my code,this would be shame
Code:
public string GetLocalizedText(string variable)
{
if (!IsLoading()) { return ""; }
uint codeCave = Memory.AllocateMemory(Encoding.UTF8.GetBytes(variable).Length + 1);
Memory.WriteBytes(codeCave, Encoding.UTF8.GetBytes(variable));
String[] asm = new String[]
{
"call " + ClntObjMgrGetActivePlayerObj,
"mov ecx, eax",
"push -1",
"mov edx, " + codeCave + "",
"push edx",
"call " + FrameScript__GetLocalizedText,
"retn",
};
string sResult = Encoding.ASCII.GetString(InjectAndExecute(asm));
Memory.FreeMemory(codeCave);
return sResult;
}