InsaneHero Posted December 2, 2014 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. Link to comment Share on other sites More sharing options...
XekeDeath Posted December 2, 2014 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 Link to comment Share on other sites More sharing options...
InsaneHero Posted December 2, 2014 Author 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. Link to comment Share on other sites More sharing options...
Recommended Posts