Skip to content
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

C# bindings generator #25

Closed
Gamerfiend opened this issue Sep 29, 2023 · 8 comments
Closed

C# bindings generator #25

Gamerfiend opened this issue Sep 29, 2023 · 8 comments
Labels
enhancement New feature or request

Comments

@Gamerfiend
Copy link

Feature description

Would it be possible to have this as a separate addon that could be used with others? Or how difficult would it be to use this with another addon? Sorry I know this is off-topic a bit but I don't know another way to discuss with you

Implementation Ideas

No response

@Gamerfiend Gamerfiend added the enhancement New feature or request label Sep 29, 2023
@DmitriySalnikov
Copy link
Owner

Well, in order for this to work with other projects, I need to put the class names and the path to the output file in the arguments of the generate method. Also I haven't published some optimizations yet. And I use conditional compilation to disable bindings in the release build. Maybe I forgot something else.
But the main question here is not how to separate it into a separate addon, but why is it needed in C++? I would prefer such a generator coded in GDScript or even in C#. It would be the most lightweight and cross-platform generator.
In this addon [debug_draw_3d], I wanted to do everything in one DLL, so I used C++.

I could try to make a separate project for this, but now I am busy with another program for which I got some money...

A C# roadmap has also recently been published, which discusses updates to the binding generator. However, it is unknown when all this will be implemented.
https://github.com/godotengine/godot-proposals/issues/7895

@Gamerfiend
Copy link
Author

Yup, I saw your post on there and came over here to see what you had done! I do agree it would be best in GDScript more than likely or as a Python script maybe?

@DmitriySalnikov
Copy link
Owner

or as a Python script maybe?

My approach to generation uses classes and methods of Godot itself in real time. Therefore, it is possible to use only GDScript/C#/C++ (as well as third-party languages implemented through GDExtension).

@GeorgeS2019
Copy link

@DmitriySalnikov

C# (Scene) Test-Driven-Development (TDD) using Godot4 in VS2022

https://youtu.be/JLI0cIYMgr0

using the latest gdUnit4API TestAdaptor from @MikeSchulze

Test.Driven.Development.in.Godot4.mp4

@DmitriySalnikov
Copy link
Owner

@GeorgeS2019 What do you expect from me? This project is written in C++, I think it would be more logical to write tests in C++. Although the entire API is already used in my scene with examples.

Please don't mention me in every issue related to C# or GDExtension. I don't want to deal with the official GDExtension binding generator for C#. In addition, they had plans for a complete restructuring of how C# works and all my edits are likely to be useless.

@MikeSchulze
Copy link

@GeorgeS2019 please do not spam repositories with this information, I didn't ask you to do that.

@GeorgeS2019
Copy link

@MikeSchulze
I truly believe more projects need to try that so that it is easy to share codes done in one project to the future projects

@DmitriySalnikov
Sorry for the stress I caused. I thank you for what you have attempted

@skooter500 skooter500 mentioned this issue Mar 12, 2024
@GeorgeS2019
Copy link

@DmitriySalnikov DmitriySalnikov closed this as not planned Won't fix, can't repro, duplicate, stale May 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants