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

PopupPanel _ready() not called, "error calling method from signal" upon opening #31296

Closed
mitchcurtis opened this issue Aug 11, 2019 · 2 comments
Labels

Comments

@mitchcurtis
Copy link
Contributor

mitchcurtis commented Aug 11, 2019

Godot version:

3.1

OS/device including version:

macOS 10.14.6
MacBook Pro

Issue description:

  1. _ready() is not called at all. From the tests I did with a super minimal example, it should be called after _init() -- without having to open the popup.
  2. When opening the popup, I get this error message:
E 0:00:01:0485   Error calling method from signal 'about_to_show': 'PopupPanel::on_about_to_show': Method not found.
  <C Source>     core/object.cpp:1238 @ emit_signal()
  <Stack Trace>  MainScene.gd:9 @ _unhandled_input()

I was not able to reproduce either of these issues starting from scratch with a minimal example, only when reducing my existing project down to the attached version.

Steps to reproduce:
Run the attached project and press T to open the popup.

Minimal reproduction project:
popup-test.zip

@mitchcurtis mitchcurtis changed the title PopupPanel _ready() not called, errors PopupPanel _ready() not called, "error calling method from signal" upon opening Aug 11, 2019
@mitchcurtis
Copy link
Contributor Author

mitchcurtis commented Aug 11, 2019

OK, I figured out a workaround for #1: attach the SavePopup.gd script to the instance of SavePopup. This shouldn't be necessary, since SavePopup.tscn already has a script attached to its root node.

I'm not sure how the script managed to get removed, as every time I add an instance now, while testing, it has a script attached. Still, should it matter? Shouldn't instances of a .tscn use the script attached to the root node of that .tscn?

@akien-mga
Copy link
Member

Your instance had script removed, which does not happen when creating new instances (either via drag and drop or by pressing the "Instance" button):
Screenshot_20190812_092004

So most likely you reset the script yourself somehow, e.g. by pressing the "Clear Script" button on the instance.

If you can reproduce a scenario where the script is lost without you removing it, then please file a dedicated bug report.

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

No branches or pull requests

3 participants