Search found 5 matches

by ShaunBartoo
Thu Sep 30, 2021 10:21 pm
Forum: General Discussion
Topic: InvalidCastException issue
Replies: 2
Views: 891

Re: InvalidCastException issue

I resolved this by being more selective about what I was serializing. CardData (The class that was causing the exception) is part of the data associated with a "Unit" that I was trying to serialize. rather than serializing each active Unit's GameObject to capture its state, I serialized th...
by ShaunBartoo
Sun Sep 26, 2021 11:12 pm
Forum: General Discussion
Topic: InvalidCastException issue
Replies: 2
Views: 891

InvalidCastException issue

Hi Joel, I'm having an intermittent issue serializing a ScriptableObject. It seems to be having issues serializing an Enum in certain cases. Here's the error I'm getting: InvalidCastException: Specified cast is not valid. ES3Types.ES3Type_enum.Write (System.Object obj, ES3Writer writer) (at Assets/P...
by ShaunBartoo
Thu May 13, 2021 8:27 pm
Forum: General Discussion
Topic: Loading Sprite Reference from File not Working
Replies: 1
Views: 750

Loading Sprite Reference from File not Working

Hi, I'm hoping to get some support on an issue I'm having. I'm trying to save a scriptable object called CardData with ES3. One of the fields in CardData is CardImage, a reference to a Sprite. When I save CardData to Cache and then reload it within the same scene, CardImage loads back with the corre...
by ShaunBartoo
Thu May 06, 2021 4:31 pm
Forum: General Discussion
Topic: Loading Runtime-Generated ScriptableObjects
Replies: 5
Views: 1118

Re: Loading Runtime-Generated ScriptableObjects

Hi Joel, Thanks for clarifying that. I misunderstood how ES3 serialized Scriptable Objects I think. I have a few followup questions. If I save the nested Scriptable Object's parent object directly, will the child objects should serialize as well? Does directly loading a Scriptable Object create an i...
by ShaunBartoo
Wed May 05, 2021 11:24 pm
Forum: General Discussion
Topic: Loading Runtime-Generated ScriptableObjects
Replies: 5
Views: 1118

Loading Runtime-Generated ScriptableObjects

Hi, I'm just getting going with this asset. So far its been great but I've hit a snag. I'm having trouble serializing a fairly complex component. I'm working on a card game, and I have a Deck component I'm trying to save/load. The deck has a list of Cards (a non-MonoBehaviour c# class), and each car...