0

I'm making a mod for a game in VS. I added a reference to TagLibSharp and it works fine in VS but when I run the game, even if the code is in an if statement that doesn't run but references TagLibSharp, it gives the error.

I don't know if the problem is related to how the game is built or some other thing. I'm not the most experienced coder either, having only made mods for this game.

System.IO.FileNotFoundException: No se puede cargar el archivo o ensamblado 'TagLibSharp, Version=2.2.0.0, Culture=neutral, PublicKeyToken=db62eba44689b5b0' ni una de sus dependencias. El sistema no puede encontrar el archivo especificado. Nombre de archivo: 'TagLibSharp, Version=2.2.0.0, Culture=neutral, PublicKeyToken=db62eba44689b5b0'

Fusion Log:

  FusionLog   "=== Información de estado anterior al enlace ===\r\nLOG: DisplayName = TagLibSharp, Version=2.2.0.0, Culture=neutral, PublicKeyToken=db62eba44689b5b0\n (Fully-specified)\r\nLOG: Appbase = file:///C:/Program Files (x86)/Steam/steamapps/common/Duck Game/\r\nLOG: PrivatePath inicial = NULL\r\nEnsamblado de llamada : (Unknown).\r\n===\r\nLOG: Este enlace empieza en el contexto de carga default.\r\nLOG: Utilización del archivo de configuración de la aplicación: C:\\Program Files (x86)\\Steam\\steamapps\\common\\Duck Game\\DuckGame.exe.Config\r\nLOG: Utilizando el archivo de configuración de host: \r\nLOG: Utilizando el archivo de configuración del equipo en C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\config\\machine.config.\r\nLOG: Referencia posterior a la directiva: TagLibSharp, Version=2.2.0.0, Culture=neutral, PublicKeyToken=db62eba44689b5b0\r\nLOG: Intento de descarga de la nueva dirección URL file:///C:/Program Files (x86)/Steam/steamapps/common/Duck Game/TagLibSharp.DLL.\r\nLOG: Intento de descarga de la nueva dirección URL file:///C:/Program Files (x86)/Steam/steamapps/common/Duck Game/TagLibSharp/TagLibSharp.DLL.\r\nLOG: Intento de descarga de la nueva dirección URL file:///C:/Program Files (x86)/Steam/steamapps/common/Duck Game/TagLibSharp.EXE.\r\nLOG: Intento de descarga de la nueva dirección URL file:///C:/Program Files (x86)/Steam/steamapps/common/Duck Game/TagLibSharp/TagLibSharp.EXE.\r\n"   string
iPablol
  • 1
  • 1
  • Check the exception's `FusionLog` property, what is written there? – cly Feb 18 '21 at 19:04
  • 1
    The solution to this is going to depend on the specific game. It's likely you need to deploy your assembly in a different location-- possibly the folder that contains the game itself, or some other folder in its [probing path](https://learn.microsoft.com/en-us/dotnet/framework/configure-apps/specify-assembly-location). If there isn't any documentation for this, checking the [fusion logs](https://stackoverflow.com/questions/255669/how-to-enable-assembly-bind-failure-logging-fusion-in-net) is a good place to start. – John Wu Feb 18 '21 at 19:09
  • I don't know what is going on in the Fusion Log, but there it is. – iPablol Feb 18 '21 at 19:28
  • Looks like moving the .dll to the game's folder is all I needed. Thanks for the help! – iPablol Feb 18 '21 at 19:38

0 Answers0