transistion on a group containing widget buttons

Hi,

I have a ‘pause’ dialog that is centered on the screen and contains 3 widget buttons within in.

Im trying to get the group and buttons to start off at size 0,0 and then use a transition.to to make it expand from the center until it is full size.

initially i had the dialog and buttons separate so only the dialog (a newRect) would zoom in with the button being full size.

No problem, i thought,  ill add the dialog and buttons to a displayGroup and put the transition on this.

Now it just behaves really oddly (kind of shoots off the screen) - probably because a displaygroup doesnt really have a size i can change.

Just wondering how people perform a transition on a group containg several objects?

Thanks

Why not create an overlay scene and add your dialog, buttons etc. to it? Then just call that overlay scene with a desirable scene effect as detailed here.

If you don’t want overlay scenes and want to put everything in a display group, try using “group.anchorChildren = true”. You can read more about it here.

Hi,

thanks for your reply… Im trying to avoid a new scene but I’ll give the anchorChildren a go and see what happens

cheers

Why not create an overlay scene and add your dialog, buttons etc. to it? Then just call that overlay scene with a desirable scene effect as detailed here.

If you don’t want overlay scenes and want to put everything in a display group, try using “group.anchorChildren = true”. You can read more about it here.

Hi,

thanks for your reply… Im trying to avoid a new scene but I’ll give the anchorChildren a go and see what happens

cheers