Hi, i recently managed to inject my code into wow with easyhook and hook up the endscene call with Apoc's whitemagic (thanks for that one btw) however i have problem with wow crashing when closing it, by simply commenting out the code i have in the injected lib i tracked down the error to be comming from the endscene hook or rather the endscene delgate/endscene handler...
is there a function like ApplicationExit i should hook and do my disposing in or is the problem something else i've overlooked?
Another thing, I freaking LOVE the new additions in .net 4 and would like to use it for my project BUT easyhook complains when i try to inject a .net 4 assembly but have no problem doing it with .net 3.5 and below assemblies, therefor i've for the last 2 hours been looking through the source code of easyhook...
I've tracked down the exception to be comming from:
Code:
public static void GacInstallAssembly(
IntPtr InContext,
String InAssemblyPath,
String InDescription,
String InUniqueID)
{
Boolean Res;
if (Is64Bit) Res = NativeAPI_x64.GacInstallAssembly(InContext, InAssemblyPath, InDescription, InUniqueID);
else Res = NativeAPI_x86.GacInstallAssembly(InContext, InAssemblyPath, InDescription, InUniqueID);
if(!Res)
throw new ApplicationException("Unable to install assembly in the GAC. This usually indicates either an invalid assembly path or you are not admin.");
}
so it's calling a importet function from the c++ easyhook dll:
Code:
extern "C" __declspec(dllexport) BOOL __stdcall GacInstallAssembly(
LPINTERNAL_CONTEXT InContext,
WCHAR* InAssemblyPath,
WCHAR* InDescription,
WCHAR* InUniqueID){
FUSION_INSTALL_REFERENCE InstallInfo;
// setup installation parameters
memset(&InstallInfo, 0, sizeof(InstallInfo));
InstallInfo.cbSize = sizeof(InstallInfo);
InstallInfo.dwFlags = 0;
InstallInfo.guidScheme = FUSION_REFCOUNT_OPAQUE_STRING_GUID;
InstallInfo.szIdentifier = InUniqueID;
InstallInfo.szNonCannonicalData = InDescription;
// install assembly with given parameters
if(!SUCCEEDED(InContext->Cache->InstallAssembly(0, InAssemblyPath, &InstallInfo)))
return FALSE;
return TRUE;
}
So it's not because easyhook does some checks on the .net version of the assembly wich i first assumed therefor im pretty clueless about why it doesn't work, any ideas?
Last question:
I've picked up Apoc's http://www.mmowned.com/forums/c/2327...your-bots.html and implemented a few of my own ideas, but regarding the design usage of it, would it be best to "nest" FSM's? like say we have 4 states in the first FSM: BgMode, GrindMode, QuestMode, ProfessionMode
and inside each these states we have a different FSM with states regarding the state of the previous state...
Thanks in advance :wave: