KeinNiemand / LargePageInjectorMods

MIT License
23 stars 2 forks source link

Unable to inject the dll (Factorio) #9

Open AkaraVortex opened 3 weeks ago

AkaraVortex commented 3 weeks ago

Trying to run the injector results in the following error:

RhInjectLibrary failed with error code = -1073741581
Unable to load the given 64-bit library into target process.

Injector is in correct location, as otherwise it will send an error for unable to locate the process.

Tried both on Steam and .zip versions of the Factorio, both with and without admin privileges.

Other injectors (such as Unreal Engine Unlocker) work without any issues. I am using Windows 11 Pro build 26252, and Factorio is version 1.1.110

KeinNiemand commented 3 weeks ago

I also use Windows 11 and the latest Factorio so that's not the issue do you have all the other files extracted as well?
I have no idea what could be going wrong and I can't fix anything without a way to identify and replicate the issue.

AkaraVortex commented 3 weeks ago

Well, I think it is a problem on my side, I will try doing some troubleshooting then, very eager to test that mod. Thanks for fast reply.

KeinNiemand commented 3 weeks ago

Are you running Injector.exe from the same folder it's in? I'm using relative paths so running it from a different folder doesn't work (at least in the current version, that will be fixed in the next version).

AkaraVortex commented 3 weeks ago

I dropped all the files near the factorio.exe, so it detects the process. As I mentioned, I tried moving it in other places and it has an error message for being unable to find the process. So I think in my case it understands where it needs to inject the dll.

Simpler question - in what order does it injects dlls? Maybe I can do it with other injector.

KeinNiemand commented 3 weeks ago

It only Injects MiMallocReplacer.dll which has the other dlls as dependanys and no you can't use a diffrent injector because simply injecting the dll will do nothing, the libary I'm using for the Injecting (EasyHook) uses it's own Entry point that's called from the Injector so if you Inject it any other way it won't do anything.
What version of the mod are you using?
Maybe try the latest pre release (prerelease because of stellaris issue) version 2.1.0

AkaraVortex commented 3 weeks ago

Same issue. I guess I will just quickly make a separate clean install of the system and test it here, I am highly suspicious that the issue lies with my system and not the code.

KeinNiemand commented 3 weeks ago

Also maybe try Factorio 1.1.109 it's unlikely to be an issue but I'm using the stable version and I haven't tested the experimental version yet.

AkaraVortex commented 3 weeks ago

No luck, sadly. In short - this is access violation error. (I've tried taking ownership of everything, disabling some exploit protections and such) Which is strange, as any other similar principle apps work without problems. I am still not sure if this is problem with my system, or something else.

AkaraVortex commented 3 weeks ago

I can manually inject redirect and override dlls, but Replacer causes the problem. I guess I should just stop and thank you regardless for that project :D

KeinNiemand commented 3 weeks ago

The only things I can think of you trying is a clean windows install and if you already tried that trying it on a different machine to see if your machine is the problem. What kind of hardware (mainly CPU) do you have?

AkaraVortex commented 3 weeks ago

Laptop 12700H, I've tried disabling some security features in a bios, but to no avail. I will try doing it on another machine in next week or so.