• Hi Guest!

    We are extremely excited to announce the release of our first Beta1.1 and the first release of our Public AddonKit!
    To participate in the Beta, a subscription to the Entertainer or Creator Tier is required. For access to the Public AddonKit you must be a Creator tier member. Once subscribed, download instructions can be found here.

    Click here for information and guides regarding the VaM2 beta. Join our Discord server for more announcements and community discussion about VaM2.
  • Hi Guest!

    VaM2 Resource Categories have now been added to the Hub! For information on posting VaM2 resources and details about VaM2 related changes to our Community Forums, please see our official announcement here.

VaM 1.x “Duplicate Key” Error After Copying to SSD (VAR Package Refresh Fails)

Threads regarding the original VaM 1.x

Indiwent

New member
Joined
Nov 8, 2025
Messages
3
Reactions
0
I backed up the entire game to a portable drive, where it still runs correctly and loads all VAR packages. After copying the same files to my SSD, the game shows the following error during package refresh:

Exception during package refresh System.ArgumentException: An element with the same key already exists in the dictionary.
at System.Collections.Generic.Dictionary`2<string, MVR.FileManagement.VarFileEntry>.Add (string, MVR.FileManagement.VarFileEntry) <0x00330>
at MVR.FileManagement.FileManager.RegisterPackage (string) <0x005a0>
at (wrapper dynamic-method) MVR.FileManagement.FileManager.Refresh_Patch1 () <0x01096>

Since the SSD copy was made directly from the portable drive, I expected identical behavior. Why is this happening?
 

Last entry
 

Last entry
the same game in my portable disk can load all the vars and work well, but a full copy in my SSD doesn't ? that's really weird
 
It means that you have one or more VARs with problems, but as the scanning process is not identical it can show the problem on one but not the other, or at different times in the same.
This is the most likely problem, VARs with unrecognized characters, often chinese.
In a far less common scenario, there's some specificness to your disks such as permissions, mount options, or even bad blocks.
 
It means that you have one or more VARs with problems, but as the scanning process is not identical it can show the problem on one but not the other, or at different times in the same.
This is the most likely problem, VARs with unrecognized characters, often chinese.
In a far less common scenario, there's some specificness to your disks such as permissions, mount options, or even bad blocks.
well, even a full copy can't restore my game. So I can only use binary search? But there are too many of them...
 
It's almost always something from an asian creator that you got from outside the Hub.
  1. Move out the VARs from asian creators of AddonPackages, load VAM and confirm that the error is gone. Quit VAM.
  2. Make a folder inside AddonPackages and move some of the VARs you set aside to the folder. Load VAM, see if the error appears,
  3. If no error, move those VARs to the base AddonPackages to empty the subfolder, move new ones in, hard reset VAM or quit/start.
  4. Redo the operation until you find a group of VARs that throw the error, one or more are the culprit(s).
 
Back
Top Bottom