gw2-addon-loader / GW2-Addon-Manager

Installer and updater for Guild Wars 2 addons.
MIT License
439 stars 56 forks source link

Addons not loading in game anymore #18

Open OmNomMonster opened 4 years ago

OmNomMonster commented 4 years ago

I was able to download both the d912pxy and radial mod with the version prior to 1.0. I never had any issues with the addons being disabled somehow or performing incorrectly. I had updated the manager to 1.0 and downloaded an update for both mods. At first I was able to use both mods in the game until I quit to the desktop and re logged in a couple of hours later. Both the radial and d912 mods just stopped working.

At first I noticed you had previously suggested to delete the addon and bin folder and reinstall which did fix the issue momentarily and I was able to use the mods when logging into the game. The problem is that every time I quit out of the game and either re log in a couple of minutes or hours the mods just completely stop working.

I initially after this redid the same step of deleting the addon and bin folder but now I can't seem to get either of the two mods working ever. I have tried going to previous versions of the addon manager with no luck. I have also tried running the addon manager in compatibility mode and admin mode with no luck.

I just as of 10 minutes ago reinstalled the addon manager 1.0 version and installed both of the mods and loaded the game up. Neither mod is showing that it is installed or working in game.

The following below is the config file information:

application_version: v1.0.0 loader_version: v0.1 bin_folder: bin64 isupdate: true game_path: C:\Guild Wars 2 default_configuration: d3d9_wrapper: false version: d3d9_wrapper: v1.0 d912pxy: v2.1h1 gw2radial: v1.2.4_al installed: d3d9_wrapper: d3d9_wrapper d912pxy: d912pxy gw2radial: gw2radial disabled: d3d9_wrapper: false d912pxy: false gw2radial: false

Thanks

OmNomMonster commented 4 years ago

Apparently renaming the folder to say GW2 instead of Guild Wars 2 fixed the issue. If anything else weird pops up I'll be sure to report it. If you don't mind I'll keep this open for another day just to be sure.

OmNomMonster commented 4 years ago

I had to re open this issue as changing the file name is basically a temp fix that only lasts a couple of days. Is there anything that can be permanently done to fix this problem?

OmNomMonster commented 4 years ago

Basically if you just keep renaming the folder to GW2 then GW3 it would fix the issue temporarily until it stops working again. I'm not sure if this will help you in tracking the issue down.

fmmmlee commented 4 years ago

Sorry for the late response, got finals week coming up (though tbh just about everything's been cancelled except for a dynamic memory allocator assignment due to the pandemic).

No idea what could be causing this issue, but I'll look into it after finals. I'm guessing it's an addon loader issue, perhaps Megai can shed some light on it.

I have an extended spring break, so hopefully I can clear up my backlog of development stuff then including this.

OmNomMonster commented 4 years ago

Yeah no rush take your time. I would rather you spend time on something more important than this like finals. I'll update this if anything else weird pops up but this is basically the only issue related to the addon manager that I'm having.

yechingu commented 4 years ago

https://github.com/megai2/d912pxy/issues/38#issuecomment-520420672

use ReShade 4.3.0 Case 1 use arcdps , d912pxy ,ReShade :

    arcdps => /bin64/d3d9.dll
    d912pxy =>/bin64/d3d9_chainload.dll
    ReShade => allfile => Game directory ReShade64.dll => dxgi.dll or d3d12.dll

Case 2 use arcdps , d912pxy ,ReShade, gw2raidal:

    arcdps => /bin64/d3d9.dll
    gw2raidal =>/bin64/d3d9_chainload.dll
    d912pxy =>/bin64/d912pxy.dll
    ReShade => allfile => Game directory ReShade64.dll => dxgi.dll or d3d12.dll

Case 3 use d912pxy ,ReShade, gw2raidal:

    gw2raidal =>/bin64/d3d9.dll
    d912pxy =>/bin64/d912pxy.dll
    ReShade => allfile => Game directory ReShade64.dll => dxgi.dll or d3d12.dll

This is instruction from dx912pxy addon dev. Gotta make sure that things are properly chain-loaded.

Also, Boon Table/Mechanics addon is no longer maintained, thus it can cause chainload to break. In addition, Blish Add-on is causing another error.

  1. not getting downloaded via UOAM
  2. not getting installed properly by UOAM
  3. not getting chain loaded properly by UOAM

You might need to totally rewrite how UOAM combines addon files.

yechingu commented 4 years ago

NVM on what I commented

Even when I manually installed Add-ons it does not load properly. (Yes I clean reinstalled GW2)

obnoxious.. this must be Anet's problem.

Ghoulify commented 4 years ago

Basically if you just keep renaming the folder to GW2 then GW3 it would fix the issue temporarily until it stops working again. I'm not sure if this will help you in tracking the issue down.

Me and a friend of mine can second this, the addon-manager is always working for a day or two, then it stops working until you change the offical Guild Wars 2 folder name from GW2 to something else. Once you've used a name you can't re-use it afterwards

Azania commented 4 years ago

Can confirm, exact same issue. After removing all addons and going manual nothing loads at all. Ended up renaming the directory to have my addons loaded again with the manual install. Something is being prevented the addons from being loaded even with manual after they stopped working. Is the way the addons being loaded by this manager considered cheating by anet or something?

fmmmlee commented 4 years ago

Potential source of issue: http://reddit.com/r/Guildwars2/comments/f8pq9z/d912pxy_dx12_for_gw2_now_v21/fm3fhvl

BernardZhao commented 4 years ago

I am having the same issue, my add-ons won't load and even when going manual they still won't load. arcdps won't show up even after a clean install.

Yoza1 commented 4 years ago

I am having the same issue, I used the GW2 addon manager to being with then it all stopped working. I tried installing it the normal way through copy pasting the d3d9.dll as well, after re-installing gw2, but the arc settings-window still doesnt pop up on the screen.

Here is also my config:

application_version: v1.0.0 loader_version: v0.1 bin_folder: bin64 isupdate: true game_path: D:\Spel\Guild Wars 2 default_configuration: d3d9_wrapper: false arcdps: true version: d3d9_wrapper: v1.0 arcdps: > 0cff00472d7e6566aa684c5e0c1fd93c d3d9.dll d912pxy: v2.1.1 gw2radial: v1.2.4_al installed: d3d9_wrapper: d3d9_wrapper arcdps: arcdps d912pxy: d912pxy gw2radial: gw2radial disabled: d3d9_wrapper: false arcdps: false d912pxy: false gw2radial: false

CTech88 commented 4 years ago

Same issue here for the past few days. I was able to get d912pxy working by installing it as d3d9.dll, but that only works when installed outside of the bin64 folder.

blocke commented 4 years ago

On my Windows 10 1903 system (Education SKU) after exiting from Guild Wars 2 the following registry key gets created:

Registry::\HKEY_USERS\\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers NoteProperty E:\Guild Wars 2\Gw2-64.exe=$ IgnoreFreeLibrary

This appears to be Windows disabling the loading of d3d9.dll from the GW2 directory due to apparent compatibility issues. This registry key prevents add ons from working until it is removed. Remove this registry key before starting GW2 and addons will work for the play station. Once you quit GW2 the registry key gets created again.

My workaround is to run the following in powershell before each time I start the GW2 client:

$current_sid = [System.Security.Principal.WindowsIdentity]::GetCurrent().User | Select-Object -ExpandProperty Value

Remove-ItemProperty -Path "Registry::HKEY_USERS\$current_sid\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers" -Name *Gw2-64.exe*
fmmmlee commented 4 years ago

Thanks for the update @blocke; do those commands require admin? If not, could I include them as part of the boot or shutdown process of the addon manager and achieve the same effect?

blocke commented 4 years ago

@fmmmlee My user in Windows is in the administrator group but I did not do anything to elevate my privileges. I did not run powershell with any UAC prompt or specific privilege escalation action.

I'm not a Windows admin so I don't know what restrictions Windows places on editing the specific user's HKEY_USERS registry hive. Also I honestly don't know if the registry edit I'm doing is going to cause other problems but so far it Works For Me (tm).

fmmmlee commented 4 years ago

@blocke appreciate the privilege info, thanks. As for the key itself, does modifying the data in the registry key fix the problem, or is deleting it the only solution? If the former is the case, you could just modify the key to fix the problem and then deny edit access for everyone, so that (hopefully) the key remains set to a value that doesn't interfere with loading the addon libraries.

Edit: A solution that may work for you (though it probably shouldn't be implemented as part of this application) is described by virtuali here; they give instructions for disabling the IgnoreFreeLibrary feature altogether.

blocke commented 4 years ago

@fmmmlee Playing with registry permissions was a good idea.

I tried leaving the key in place but blanking out the value (setting it to be an empty string). Windows put the IgnoreFreeLibrary back into the key's value after the GW2 app closed.

I set the permissions for AppCompatFlags\Layers for the user I run GW2 under to specifically Deny both Full Control and Read access. I started and quit GW2 five times, rebooted Windows, then tried a couple more times. The permission change survived reboot and the IgnoreFreeLibrary key is not being created anymore. I did not need to modify the read/full control permissions of the administrator group. Denying read/write to the specific user seems good enough.

I think I'll stick with the registry permissions hack as it's probably less invasive than entirely disabling PCA.

Thanks for your work on GW2 Addon Manager! :)

Edit: To clarify for others, the specific registry path I modified permissions on was:

Registry::HKEY_USERS\<SID OF CURRENT USER>\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers

There may be other AppCompatFlags\Layers folders findable with regedit that will not be the correct one so make sure you are editing the folder associated with the specific windows user object you are running GW2 under.

Azania commented 4 years ago

Huh so that is where the registry was, no wonder I couldn't find it. I can confirm that I have that registry entry there. Either way I have been testing with manual addons installed to see if it would happen again. Since the last post here where I said I installed everything manual it had not happened at all. Which leads me to thinking that something in the way the dll's are loaded (so different from manual chainloading) is causing this to happen?

It seems to happen when the command FreeLibrary(..); is used. Which should be in the gw2 client. Since it doesn't happen with manual install I have a feeling it lies in the gw2-addon-loader where the bug is located to cause this behavior. I have been looking through the code but unable to find any clue there..

I have no proof but it could be somewhere where the dll's have conflicts/try to override eachother? Conflicting information, manifests, files, calls.. Something that doesn't happen in chainloading cause the main dll (usually arcdps) is leading and providing the details/manifests/function calls..

Interesting reading sources; https://docs.microsoft.com/en-us/windows/win32/api/libloaderapi/nf-libloaderapi-freelibrary https://software.intel.com/en-us/forums/intel-fortran-compiler/topic/606006 linked from https://hero.handmade.network/forums/code-discussion/t/2248-windows_preventing_game_code_dll_unloading

So yeah.. So I would say something is still referencing the dll's when the games down with an error somewhere caused by either the dll's (most likely if it happens every few days minimum) or the game itself maybe?

Fixing with messing the registry is for me only a bandaid solution that should not be used for too long..

fmmmlee commented 4 years ago

@megai2 Any insights on the above?

megai2 commented 4 years ago

@megai2 Any insights on the above?

Windows sets this flag when gw2 crashes in d3d9 frequently. Giving fact that some ppl have crash on exit, that i can't reproduce to properly trace down source of problem, "normal" patch date arc crashes and other crashes - only registry cleaning are viable for now.

fmmmlee commented 4 years ago

@megai2 is there some way to block windows from setting the flag or maybe hide the filename so that when the crashes happen Windows doesn't flag d3d9.dll? I'm guessing probably not but can't hurt to try.

At the moment, though, I'll just update the wiki with instructions and information about this problem and how to work around it with permissions or a script like @blocke uses.

megai2 commented 4 years ago

@megai2 is there some way to block windows from setting the flag or maybe hide the filename so that when the crashes happen Windows doesn't flag d3d9.dll? I'm guessing probably not but can't hurt to try.

At the moment, though, I'll just update the wiki with instructions and information about this problem and how to work around it with permissions or a script like @blocke uses.

There was idea to make a manifest, but it ended up not viable.

I was about to make a script for that, but looks like you already got it.

megai2 commented 4 years ago

I added changes in loader to handle that case with ignored FreeLibrary, but it should be placed in game root folder. Maybe it will work out.

fmmmlee commented 4 years ago

@megai2 do you think it might be possible to implement the script blocke wrote above inside the addon-loader d3d9.dll itself on application exit? That way, if Windows ever flags d3d9.dll, the flag gets removed when the game is closed. (of course, if it crashed and the script didn't get a chance to run, then the flag got set....yeah, gotta go run it manually)

also, if those changes you mentioned are ready....would be good if you could make a new release of loader-core :smiley:

megai2 commented 4 years ago

@megai2 do you think it might be possible to implement the script blocke wrote above inside the addon-loader d3d9.dll itself on application exit? That way, if Windows ever flags d3d9.dll, the flag gets removed when the game is closed. (of course, if it crashed and the script didn't get a chance to run, then the flag got set....yeah, gotta go run it manually)

also, if those changes you mentioned are ready....would be good if you could make a new release of loader-core 😃

better to put it somewhere in release but with small improvement: make it delete reg entry & start game.

they are ready, but should be tested first

KLEPTOROTH commented 4 years ago

Wanted to add something here. I've noticed this happening on several computers as well. Finally decided to spend time digging into this and noticed the issue happens on my account but not other accounts, so therefore it must be something in my user profile. After quite a while of deleting anything related to GW2 in my profile, searching the registry, etc, I finally found this key: Computer\HKEY_LOCAL_MACHINE\SOFTWARE\ArenaNet\Guild Wars 2\Src - value was: "C:\Users\username\AppData\Local\Temp\Gw2-64.exe" Funny enough, the registry entry itself wasn't in the user profile, but the path was, so it had the same effect. Not sure why there would be a registry entry pointing to an executable in the temp directory, but deleting it solved the issue with d3d9.dll not loading, at least on my main computer. Will see if it's the same issue on the others. Hope this helps someone.

KLEPTOROTH commented 4 years ago

Well it seems that was a temporary fix. Had to kill the game due to the bug with d912pxy that if the game loses focus, in certain circumstances, the game will lock up. When I loaded the game again, none of the addons loaded. The registry key mentioned earlier: Registry::HKEY_USERS\<SID OF CURRENT USER>\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers and mine: Computer\HKEY_LOCAL_MACHINE\SOFTWARE\ArenaNet\Guild Wars 2\Src both don't exist. Hunting more...

megai2 commented 4 years ago

fixes to loader and d3d wrapper are released. if you have problem with registry key - just move d3d9.dll from bin64 to game root folder

the-gremlin commented 4 years ago

i have encountered the same exact problem, however, whehn i tried the regedit fix, the path ended abruptly at AppCompat and the only thing efter that was a folder thingy named store.

blocke commented 4 years ago

I would no longer recommend playing with permissions on the AppCompatFlags\Layers registry key as revoking write privileges on AppCompatFlags will cause recent versions of the Discord client installer to crash.

The crash in the installer Discord uses (Squirrel) is due to it trying to make sure any AppCompatFlags affecting itself are deleted. sigh

Aelphais commented 3 years ago

Just a small update to this issue... though I am not actually certain that it is the same issue.

All my addons stopped loading for some reason, tried reinstalling and other such fixes before looking around on the internet and finding this thread.

I've looked through the registry and haven't found the AppCompatFlags key. I did find the HKEY_LOCAL_MACHINE src key referencing the wrong install folder, but no change in addon loading after deleting it. Someone else mentioned that renaming the gw2 folder is a temporary fix, but that doesn't seem to work either.

I will say that this doesn't seem to be an issue with addon manager itself as installing manually still results in no addons loaded, but don't really know where else to post for possible help resolving this issue.

megai2 commented 3 years ago

Something prevents any of d3d9.dll load in game. Maybe some 3-rd party overlay or other programs (antiviruses, video capture, some drivers) Or maybe you somehow running game from another install folder.

Anyway if you don't have any logs that is "witch hunting". Maybe you can remember what happenned when addons stopped working, because nothing happens without a reason.

ioakie commented 2 years ago

Having the same issue. STILL. I have to rename the dang Guild Wars 2 directory to get this thing to work. There hasnt been a fix yet?