UndertaleModTool icon indicating copy to clipboard operation
UndertaleModTool copied to clipboard

Add ParentEntry to code editor

Open skirlez opened this issue 1 year ago • 2 comments
trafficstars

Description

This PR makes it so you can see the ParentEntry property in the code editor. Often when searching for a specific function you'll find the code entry referencing it, but then have to manually search for the parent entry to view/edit its contents. This change would make it easier to go there, you just need to double click it.

The property won't be displayed when null (so it will only show up when relevant), and can't be edited or set to null.

Screenshot from Void Stranger's gml_Script_scr_steam_achievement_get: image

Caveats

Notes

skirlez avatar Oct 05 '24 15:10 skirlez

Seems like a good addition to me. One caveat with this is that you can change the ParantEntry by dragging a different one in, which makes no sense and doesn't update that entry's ChildEntries list, but it doesn't seem to cause any bugs I could find and it doesn't affect the saved data.win file so it might be fine to leave as is.

zivmaor avatar Oct 06 '24 11:10 zivmaor

Seems like a good addition to me. One caveat with this is that you can change the ParantEntry by dragging a different one in, which makes no sense and doesn't update that entry's ChildEntries list, but it doesn't seem to cause any bugs I could find and it doesn't affect the saved data.win file so it might be fine to leave as is.

I think this can be addressed by adding a boolean to UndertaleModTool/Controls/UndertaleObjectReference.xaml.cs, specifying whether any changes (by drag and drop) are allowed. That or with some fancy bindings, but I'm not too sure how WPF handles that.

colinator27 avatar Oct 23 '24 03:10 colinator27

I implemented said boolean, that caveat should now be fixed

skirlez avatar Oct 24 '24 10:10 skirlez

@Skirlez can you send a new screenshot for GUI? Am interested in seeing a specific thing there.

Miepee avatar Nov 25 '24 11:11 Miepee

@Skirlez can you send a new screenshot for GUI? Am interested in seeing a specific thing there.

image

The same as the screenshot from earlier, except that the tooltip for dragging doesn't appear anymore.

skirlez avatar Nov 25 '24 19:11 skirlez