-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow exporting custom resources from/to GDScript, VisualScript, C#, and PluginScript. #48201
Conversation
b0ce795
to
b5c44b7
Compare
c7c8429
to
bf1021f
Compare
bf1021f
to
1441b97
Compare
1441b97
to
78f1560
Compare
I have now rebased this to adapt to the introduction of EditorResourcePicker and EditorScriptPicker, though the Inspector functionality now needs testing again (I didn't have time to test). I also added the documentation changes that I forward-ported from the 3.x version of this PR. |
0947701
to
4a1d873
Compare
Made several changes to the ScriptServer API and the VisualScript script class changes so that |
Will this PR make its way before feature freeze? |
Yes, there won't be 4.0 beta without this implemented. Edit: And well now that 4.0 beta 1 has been released some users are prompt at pointing out the failed promise. This feature is still planned for 4.0 and we'll get it implemented one way or another as time and resources permit. Some core changes are needed to facilitate implementing this properly and @reduz will have to work on it when he finds time. |
68fdd12
to
30274fd
Compare
FYI, C# is temporarily removed from this "all together" build because of various inconsistent compiler errors I was getting that seem to be tied to the Mono code not being up-to-date(?). Just going to stop maintaining the C# support (#63126) until advised otherwise since the .NET 6 version will just convert them into native engine types using GDExtension integrations (i.e. they won't even need "global script class" support). |
ce61be4
to
2e9b9ed
Compare
e85130f
to
67f4452
Compare
I've just rebased all of the child PRs and re-created this PR, now including the Mono C# support again, so that folks can fully test everything out. Please let me know if you experience any issues. |
I would like to test the feature but I get non-trivial merge conflicts, especially with csharp after the merge of dotnet 6. Is there any date this might be possible to merge again? |
Love this feature so much. @willnationsdev |
67f4452
to
34bcef7
Compare
@antonWetzel I have just now rebased this PR. I had to remove the C# functionality once again, cause I'm pretty sure MOST of what I wrote is completely unnecessary now. I would need to actually find time to get working C# code in the latest beta to figure out where things stand, what's missing, and how best to fill in those missing pieces. In the meantime, C# should at least be accessible from GDScript with these changes since C# is now set up as in-engine classes (to my understanding). I just don't know yet if C# already has proper Export attributes to handle exporting user-defined script resources (or lists thereof - I kinda doubt it has support for either). From akien's comment above though, it sounds as though these child PRs will need another rebasing that take into account whatever changes reduz is gonna make later down the line. In the meantime, I hope people can "test" it adequately in its current state. |
34bcef7
to
48cd0d3
Compare
@willnationsdev Is this PR superseded by #62413 and others? |
Yes it should be. |
Apologies if this should be obvious, but should I be able to create a custom resource in C# in beta 6? I've gone through all the relevant issues and pull requests I can find but there's too many for me to follow what the current status of this is. I tried extending Resource but the new resource type didn't show up in the editor. Also, when I export a field requiring the custom resource (like So, in Godot 4.0 beta 6, is there a way to create a custom resource in C# that will show up in the editor properly? |
Old Content:
I have saved the old history of changes under a new branch called
gdres-all-4.0-v1
. From this point forward, since this is the PR most people are already "tracking" for solving this issue, I'm going to use it as a staging ground for merging together any relevant PRs that are separately submitted so that others can more easily grab everything significant with which to test out the functionality.Child PRs:
Demo Project (Relies on all of the child PRs being present, which they are in this branch's history):
Demo_InspectorResources.zip
Demo Project for C#/Mono (also relies on all child PRs being present):
Demo_InspectorResources_Mono.zip
Bugsquad edit: