Page 1 of 1

Dictionary of Lists

Posted: Thu Apr 09, 2020 10:59 pm
by Diggidy
Attempting to save a dictionary of lists. But im getting an error. Saving lists by themselves work but not in a Dictionary. Any ideas on a workaround?

Dictionary<MechanicJobsQueName, List<string>> MechanicJobsQueDict = new Dictionary<MechanicJobsQueName, List<string>>(); //MechanicJobsQueName is an enum

ES2.Save(MechanicJobsQueDict, SaveFileName + "?tag=MechanicJobsQueDict");

System.Collections.Generic.List`1[System.String] is not currently supported or it's ES2Type was not found, but you may be able to add support for it through Assets > Easy Save 2 > Manage Types
UnityEngine.Debug:LogError(Object)

Re: Dictionary of Lists

Posted: Fri Apr 10, 2020 7:52 am
by Joel
Hi there,

This is not possible in Easy Save 2, but is possible in Easy Save 3.

The only alternative in Easy Save 2 is to create a wrapper and save that, as described here: https://moodkie.com/forum/viewtopic.php?f=4&t=744

All the best,
Joel

Re: Dictionary of Lists

Posted: Fri Apr 10, 2020 2:30 pm
by Diggidy
Thanks for clearing that up.

The only reason I havent jumped to ES3 was because I was having problems getting the Reader/Writer working with PS4 and I wanted the best all in one solution.

Re: Dictionary of Lists

Posted: Fri Apr 10, 2020 2:57 pm
by Joel
Ah, I see.

In Easy Save 3 you should not access the Reader/Writer, but instead use the ES3File API. I've described this here, though I can't guarantee that this will work with any particular platform apart from those on our supported list: https://docs.moodkie.com/easy-save-3/es ... rage-apis/

All the best,
Joel

Re: Dictionary of Lists

Posted: Fri Apr 10, 2020 3:19 pm
by Diggidy
Joel,

Thanks for your help, always top notch support.