Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

PropertyDrawer not working #36

Open
szyuGH opened this issue May 16, 2024 · 0 comments
Open

PropertyDrawer not working #36

szyuGH opened this issue May 16, 2024 · 0 comments

Comments

@szyuGH
Copy link

szyuGH commented May 16, 2024

I'm using Unity 2021.3.19f1 with the SerializableDictionary package.

I created a class for my Dictionary and added another class in an Editor folder:

[Serializable]
public class StatMap : SerializableDictionary<string, int> {}

and

[CustomPropertyDrawer(typeof(StatMap), true)]
public class AnySerializableDictPropertyDrawer : SerializableDictionaryPropertyDrawer {

    public override void OnGUI(Rect position, SerializedProperty property, GUIContent label) {
        base.OnGUI(position, property, label);
     } 
}

I override the OnGui method so I can place a breakpoint. But no matter what I do, the breakpoint is never reached. I have an auto property inside my PlayerCharacter script and the inspector looks like this:

image

Has anyone a solution on how to get the property drawer working?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant