Closed rainbowdesign closed 5 years ago
Do you mean the same mod with the same filename? Can you attach the file structure you have. Please, always attach the log file.
I rechecked it its a little different: The game does not crash but it still seems the mods are not loaded correctly. Take a mod copy it leave it in the modfolder with a different name gives that error:
[= INFO =] Loading AutoSweeperMod, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
[= INFO =] Loading BuildingPatches, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
[= INFO =] Loading AutoSweeperMod, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
[= INFO =] Loading NuclearPowerMod, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentException: element already exists
at System.Collections.Generic.SortedList2[System.String,ModLoader.DependencyGraph+Vertex].PutImpl (System.String key, ModLoader.Vertex value, Boolean overwrite) [0x00000] in <filename unknown>:0 at System.Collections.Generic.SortedList
2[System.String,ModLoader.DependencyGraph+Vertex].Add (System.String key, ModLoader.Vertex value) [0x00000] in
I've added a simple check to skip duplicate mods (same assembly name). Find it here: https://github.com/javisar/ONI-Modloader/blob/master/Managed/ModLoader.dll
@rainbowdesign could you check if it is already fixed?
got this now:
System.BadImageFormatException: Could not load file or assembly 'D:/Steam/steamapps/common/OxygenNotIncluded/OxygenNotIncluded_Data\Managed/ModLoader.dll' or one of its dependencies. An attempt was made to load a program with an incorrect format.
File name: 'D:/Steam/steamapps/common/OxygenNotIncluded/OxygenNotIncluded_Data\Managed/ModLoader.dll'
at (wrapper managed-to-native) System.Reflection.Assembly:LoadFrom (string,bool)
at System.Reflection.Assembly.LoadFrom (System.String assemblyFile, System.Security.Policy.Evidence securityEvidence) [0x00000] in
Mmmm, pretty weird. Can you download it again, it seems that you have a corrupted version of the file. The file size is 11776 bytes.
I checked it again and i think it does work.
Having the same mod two times crashes the game. I think that is not good, better would be to either: Have them run parallel or skip the second.