hi problems new patch
plz help
Code:
/// <summary>
/// Interacts with the object, loot, target etc.
/// </summary>
public void Interact2()
{
if (MyObjectManager.InGameStatus != eInGameStatus.Login)
return;
if (this.ObjectPointer != IntPtr.Zero && this.IsNotTrash)
{
uint codecave = MyObjectManager.Memory.AllocateMemory();
try
{
uint virtualMethodTable = MyObjectManager.Memory.ReadUInt((uint)ObjectPointer);
MyObjectManager.SuspendMainThread();
MyObjectManager.Memory.Asm.Clear();
MyObjectManager.Memory.Asm.AddLine("fs mov eax, [0x2C]");
MyObjectManager.Memory.Asm.AddLine("mov eax, [eax]");
MyObjectManager.Memory.Asm.AddLine("add eax, 8");
MyObjectManager.Memory.Asm.AddLine("mov dword [eax], {0}", new object[] { MyObjectManager.CurrentMgr });
MyObjectManager.Memory.Asm.AddLine("mov ecx, {0}", new object[] { this.ObjectPointer });
MyObjectManager.Memory.Asm.AddLine("call {0}",
new object[] {
MyObjectManager.Memory.ReadUInt(virtualMethodTable +
WoWOffsets.Instance.VFT__Interact * 4) });
MyObjectManager.Memory.Asm.AddLine("retn");
MyObjectManager.Memory.Asm.InjectAndExecute(codecave);
Thread.Sleep(10);
}
catch (Exception e)
{
Common.Logger.PrintImportantMessage("[GObject] Interact() - " +
e.Message);
Common.Logger.PrintToLogFile("[GObject] Interact() - " +
e.Message);
}
MyObjectManager.ResumeMainThread();
MyObjectManager.Memory.FreeMemory(codecave);
}
}