Looking for "bottom-mid centered" scaling advice

Godot Version 4.4.1

Hi everyone,

I’ve got multiple TextureRects in a HBoxContainer, centered to the bottom of the screen. During runtime, the amount of icons will change, so I need the auto alignment of the HBoxcontainer.

I already build way more complex UIs with Godot, but I never had to scale control nodes at the bottom before and I’m a little surprised at how cumbersome it seems to be. I know theres a workaround with adding non-control nodes in between, but thats not working well for my case.

Are there any other clean ways to do this than having the sprites in the correct size? (so they don’t have to be scaled)

Your green anchors look correct. You can use this green circle to select a anchor preset, maybe your parent node’s anchors aren’t set correctly?

Thanks gertkeno, I used that for anchoring it there. Because the images are too big, I have to scale them down. I can’t do that directly, because of the inheritance. If I Scale down the top node to 0.5, everything is still anchored to the same spot, but everything moves away from there, like shown below

I see! You may have to use the rare pivot, circled is the “pivot” and you can use this tool to move it. This will change from where the node scales and rotates.

But if you are adding items dynamically you will have to update the pivot_offset in code.

I was hoping to have missed any UI feature for that, but I’m gonna use the pivot offset then, thanks a lot gertkeno! :slight_smile: