Skip to content

[Bug] Issues when displaying nested variables #12

@Ivan-Vankov

Description

@Ivan-Vankov

Let's say we have the following code:

[Serializable]
public class NestedVar {
    public int nestedValue;
}
[Serializable]
public class BaseVar {
    public Reference<NestedVar> nestedVar;
    public bool baseValue;
}

Then we create variables of type BaseVar and NestedVar.
In the dropdown for Nested Var in BaseVar we choose Variable.
When we assign the NestedVar variable there it displays like this in edit mode:
image
The initial value of Nested Var is displayed after Base Value.
It is on the same indentation level as Nested Var.
This becomes worse when you add more nested vars.
They all display on the bottom with the same indentation and you don't know which initial value belongs to what.

In play mode it looks like this:
image
The current value of Nested Var is displayed on the top-right of the initial value and is misaligned with everything else.
It also hides the trigger that enables you to edit the initial value in play mode.

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