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

gdexport on method exports without transforming #88

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

geekrelief
Copy link
Contributor

Fixes #87
Now adding gdExport on a method exports it like proc. So method doIt() {.gdExport.} exports as do_it instead of _do_it. So godot can find our virtual methods that don't begin with underscores.

@endragor
Copy link
Member

endragor commented Feb 4, 2021

As I mentioned in #87, this would break method process and most other methods. The proper fix, in my opinion, would be to allow to override the exported name, like this: method doIt() {.gdExport: "do_it".}.

@geekrelief
Copy link
Contributor Author

I've tested it in my code base with classes that have method process, enter_tree, init etc. Everything seems to be working fine. This doesn't change their existing behavior and brings method inline how gdExport works on proc and var, as far as I can tell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

method assumes virtual methods always start with an underscore
2 participants