Skip to content

Enumeration in ScriptableObject #5

Description

@rudamaia
  1. Created a public class UDictionaryStringColor : UDictionary<String, Color> following the provided code example.

Screen Shot 2022-01-05 at 00 04 34

  1. Created a ScriptableObject class that has a UDictionaryStringColor field.

  2. Objects works and stores values without issues.

Screen Shot 2022-01-05 at 00 04 07

  1. Try to iterate trough the ScriptableObject field and get an error:

Screen Shot 2022-01-05 at 00 08 32

NullReferenceException: Object reference not set to an instance of an object
UnityEngine.Collections.Generic.UDictionary`2+Enumerator[TKey,TValue].MoveNext () (at Library/PackageCache/com.prastiwar.unityserializeddictionary@769342ef7b/Runtime/UDictionary.cs:719)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions