InsaneHero Posted December 2, 2014 Report Share Posted December 2, 2014 I'm using Groups to create layers, but the code is structured so that the Group layer that needs to always be at the very top (the screen blanker) is the first created because it needs to cover up all the nasty transitions done by lower level stuff.So I need a way to bring that Group to the top whenever another Group is added.Group.bringToTop is for sprites inside the group. Quote Link to comment Share on other sites More sharing options...
XekeDeath Posted December 2, 2014 Report Share Posted December 2, 2014 Pretty sure Group.bringToTop is what you need, you are just looking at the wrong group. Adding a group to your game adds it to the game.world object, a Phaser.World object which extends Phaser.Group So, try calling game.world.bringToTop(yourGroupHere) and see how that goes... Carlos and InsaneHero 2 Quote Link to comment Share on other sites More sharing options...
InsaneHero Posted December 2, 2014 Author Report Share Posted December 2, 2014 Thanks, that works perfectly. I thought there must be a meta-Group somewhere but didn't know what it was called. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.