I've made a progress indicator for my game which should show up on the HUD when something is being built, and I'm positioning it in the _process()
method. I've also carefully set it up so that the origin point is at the very base of the progress indicator.
func _process(_delta: float):
set_position(Game.main.player.camera.unproject_position(target.transform.origin))
The position is correct, and even if I set it to something like Vector2(100, 100)
it still works the same way which is that it seems to show up way off screen. If I manually insert it into my scene I see warnings about how it's position is dependent on it's parent.
The parent is just a Container node set to fill up the whole screen.
I hope this was enough information to be able to tell what I'm doing wrong. I'm unsure what the problem could be.