You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An RPG game, where any of the adjacent rooms are loaded at runtime
Describe the problem or limitation you are having in your project
Each of the rooms needs to keep the reference to the adjacent rooms as a string path, but the only way assign file paths to a property is by passing a string representing it. You can use an attribute hint to make it easier:
[Export(PropertyHint.File)]// or [Export(PropertyHint.Dir)]publicstring pathToResource;//or pathToPackedScene, or pathToDir
but it's still not possible to keep track of files/directories which get renamed or moved.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
If you use a resource directly, the engine is able to keep track of it even when renamed or moved inside the editor, i'd like to implement something similar but limiting this feature to keep track of a (project) resource path (or directory), to give the developer a way to manually handle each resource (when load/unload them, and how to do it, for example using other threads to load some scenes and resources)
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
This functionality should be added as a new resource type (something like Path), which only takes a string as its member fields.
The user should be able to pass a file/directory into this resource from the editor, and the latter should be tracked by the editor and updated whether it gets moved or renamed from inside the editor.
The user should be able to access the file path as a string with a method
If this enhancement will not be used often, can it be worked around with a few lines of script?
It can't be worked around. The only way to achieve the same result is by manually changing each of the references to a certain file/directory when moved/renamed (which is not convenient at all, in particular when you are moving a large amount of file into a new location, and might lead to some of the references to be null if you forget to manually update them)
Is there a reason why this should be core and not an add-on in the asset library?
It should improve the editor usability, as it's a missing core funcionality
The text was updated successfully, but these errors were encountered:
References my open discussion #9545 (comment)
Describe the project you are working on
An RPG game, where any of the adjacent rooms are loaded at runtime
Describe the problem or limitation you are having in your project
Each of the rooms needs to keep the reference to the adjacent rooms as a string path, but the only way assign file paths to a property is by passing a string representing it. You can use an attribute hint to make it easier:
but it's still not possible to keep track of files/directories which get renamed or moved.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
If you use a resource directly, the engine is able to keep track of it even when renamed or moved inside the editor, i'd like to implement something similar but limiting this feature to keep track of a (project) resource path (or directory), to give the developer a way to manually handle each resource (when load/unload them, and how to do it, for example using other threads to load some scenes and resources)
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
This functionality should be added as a new resource type (something like
Path
), which only takes a string as its member fields.The user should be able to pass a file/directory into this resource from the editor, and the latter should be tracked by the editor and updated whether it gets moved or renamed from inside the editor.
The user should be able to access the file path as a string with a method
If this enhancement will not be used often, can it be worked around with a few lines of script?
It can't be worked around. The only way to achieve the same result is by manually changing each of the references to a certain file/directory when moved/renamed (which is not convenient at all, in particular when you are moving a large amount of file into a new location, and might lead to some of the references to be null if you forget to manually update them)
Is there a reason why this should be core and not an add-on in the asset library?
It should improve the editor usability, as it's a missing core funcionality
The text was updated successfully, but these errors were encountered: