Page 1 of 1
Group Items in templates like with ItemPopupAttribute
Posted: Wed Sep 25, 2019 3:25 am
by Deadcow
I added Item property to Dialogue Entry template and all items in popup is not grouped
With ItemPopupAttribute it looks fine
Re: Group Items in templates like with ItemPopupAttribute
Posted: Wed Sep 25, 2019 4:13 am
by Deadcow
So I made tiny change in DialogueEditorWindowAssetLists.cs line 90
names.Add(new GUIContent(string.Format("[{0}] {1}", asset.id, asset.Name), string.Empty));
replaced with
names.Add(new GUIContent(asset.Name, string.Empty));
Is it some reason to put Id before the name?
Re: Group Items in templates like with ItemPopupAttribute
Posted: Wed Sep 25, 2019 9:53 am
by Tony Li
Hi,
Internally, references to items, actors, etc., store the ID, not the name. The dropdown menu shows IDs to remind you that it will store the ID:
- assetByID.png (17.09 KiB) Viewed 540 times
Re: Group Items in templates like with ItemPopupAttribute
Posted: Sat Sep 28, 2019 3:16 am
by Deadcow
It's not very helpful in my opinion. I made a field in Dialogue Entry template for designers to set when they building conversations, and instead of nicely formatted popup we've got a raw list of about a hundred of items, totally unusable
Well maybe ID should go at the end after the name to keep nice formatting, or some another way to sort by ID.
Anyway, I'll keep my change then, no worries
Re: Group Items in templates like with ItemPopupAttribute
Posted: Sat Sep 28, 2019 8:48 am
by Tony Li
That's reasonable. In the next update, I'll change it to put the [ID] number at the end.