Im currently using
Code:
public bool CastSpellByID(uint id)
{
Console.WriteLine("Castspell");
uint codeCave = wow.AllocateMemory();
const uint CastSpellID = 0x007735F0;
wow.Asm.Clear();
wow.Asm.AddLine("fs mov eax, [0x2C]");
wow.Asm.AddLine("mov eax, [eax]");
wow.Asm.AddLine("add eax, 8");
wow.Asm.AddLine("mov dword [eax], {0}", CurMgr);
wow.Asm.AddLine("push 0");
wow.Asm.AddLine("push 0");
wow.Asm.AddLine("push 0");
wow.Asm.AddLine("push {0}", id);
wow.Asm.AddLine("call {0}", CastSpellID);
wow.Asm.AddLine("add esp,16");
wow.Asm.AddLine("retn");
wow.Asm.InjectAndExecute(codeCave); //<-- This line makes the error
wow.FreeMemory(codeCave);
return true;
}
yet it keeps springing the error, could not inject for some reason, does any one have any info that could help?