- Edited
This is the scene I'm struggling with:
And this is the code I use to get a reference to the "BaseImage" in the Root's script:
@onready var image: Sprite2D = %BaseImage
I tried this as an alternative, but the result is the same:
@onready var image: Sprite2D = get_node("BaseImage")
I keep getting an error message that looks as follows:
E 0:00:00:441 card_base.gd:7 @ @implicit_ready(): Node not found: "BaseImage" (relative to "/root/Game/StockController/@Area2D@11").
<C++ Error> Method/function failed. Returning: nullptr
<C++ Source> scene/main/node.cpp:1878 @ get_node()
<Stack Trace> card_base.gd:7 @ @implicit_ready()
stock_controller.gd:23 @ _ready()
Reloading the project doesn't help. Any idea how to deal with this type of issue?