[SOLVED] Missing script attribute descriptions

Hey hey :slight_smile:

It seems like since the new UI design for the editor was rolled out, the description of script attributes can’t be seen anymore by hovering over them with the mouse. Is this intendet or a bug?

1 Like

Confirmed, the same happens in any project/script.

Hope definitely a bug, we miss them.

@will

1 Like

On the same topic, before the UI changes, the description of array-attributes were also never visible. Maybe this could be fixed as well? :blush:

1 Like

Calling @vaios to address these for you… :smile:

1 Like

Hello,

We will bring those tooltips back thanks for reporting that.

1 Like

This should be working now.

2 Likes

Confirmed, it’s working, thanks @vaios.

1 Like

Awesome, thanks :slight_smile:

I found another issue with attributes

When I create an attribute of type ‘vec2’

Test.attributes.add('points', {
    type: 'vec2',
    array: true,
});

fill them like this
image
then click on another entity in the editor and finally back on the same entity, it looks like this:
image

This combination of attribute options seems to only display the value edited last. It doesn’t necessarily has to be last value of the array. I didn’t test it with other options, like ‘vec3’, ‘rgb’ or ‘rgba’…

I iterated over them in the initialize function and the array contains the correct values, so it seems only to be a visual bug in the editor.

1 Like

Thanks so much for letting us know @AliMoe - we really appreciate it. @vaios will look into it for you.

No problem, I’m glad if I can help :wink:

This should be fixed now.

1 Like

Capture
Another problem: The enum is not showing options in the editor!

BtnStates.attributes.add('Choices', {
    type: 'number',
    enum: mapEnum(MyEnum),
    default: MyEnum.LastChoice
});

function mapEnum(Enum) {
    var reverseLookup = {};
    var result = [];
    for(var value in Enum) {
        if(!Enum.hasOwnProperty(value)) continue;
        var enumEntry = {};
        enumEntry[value] = Enum[value];
        result.push(enumEntry);
        reverseLookup[Enum[value]] = value;
    }
    Enum.toString = function(value) { return reverseLookup[value]; };
    return result;
}

Before the update, it was showing the options perfectly but now I cannot select any options hence I cannot work further. Please fix this as soon as possible @vaios

This should now be fixed @Mustafa_Ali

3 Likes

Yes, it has been fixed, Thank you!

Cool, Thanks :slight_smile:

1 Like