#Dynamically created nodes only has a proper position after turning the parent visible

1 messages · Page 1 of 1 (latest)

sullen sand
#

Hi all,
I made an inventory system using GridContainer. Each grid is simply a texture rect.
Naturally, the container's visibility is set to false upon start. If I generate items to put into this grid system without setting visible=true for a few frames, the items are placed way off screen. If I set visible=true first then place the items, then everything works as expected.
Is there a way for me to initialize the position of the grids without making it visible?

celest flame
#

This is kind of a hack but you could set the modulate's alpha to 0 when it's visible to hide it