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

The _Init() method doesn't work in C# #32295

Closed
aaronfranke opened this issue Sep 24, 2019 · 3 comments
Closed

The _Init() method doesn't work in C# #32295

aaronfranke opened this issue Sep 24, 2019 · 3 comments

Comments

@aaronfranke
Copy link
Member

Godot version: 3.1.1 and 30e16ff

OS/device including version: Ubuntu 18.04 64-bit

Issue description: It seems that _Init doesn't work at all in C#. @neikeq

Steps to reproduce: Open and run the reproduction project, which contains the following:

public override void _Init()
{
    GD.Print("This text is never printed.");
}

In 3.1.1: The code in _Init() isn't executed at all.

In master: 'TestNode._Init()': no suitable method found to override (CS0115)

Minimal reproduction project: OverrideVoidInit.zip

@Zylann
Copy link
Contributor

Zylann commented Sep 24, 2019

What would _init be for in C# since it has constructors?

@neikeq
Copy link
Contributor

neikeq commented Sep 24, 2019

Duplicate of #22633

_Init never did anything in C#, and as I recently commented:

I'm removing _Init for now in #29140, but I plan to add a working implementation in the future ...

@NQNStudios
Copy link

For API parity, I think _Init() should exist for C#. Or documentation should explain how to replicate the functionality with a C# constructor.

@aaronfranke aaronfranke closed this as not planned Won't fix, can't repro, duplicate, stale Dec 4, 2023
@YuriSizov YuriSizov removed this from the 3.2 milestone Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants