Jump to content

Setting up multiple sections/panes.


Brandon
 Share

Recommended Posts

I'm fairly new to pixi but have read through a few tutorials and understand the basic concepts. One thing that I am confused about is the purpose of the renderer vs the stage.

 

I would like to set up a game that is comprised of 4 sections - 1 main game and 3 layered over the top of it, as shown here:

 

post-13235-0-47009500-1424362474_thumb.p 

 

The main game section (green) would be the bottom most layer. The other 3 would go on top of it. This "layer" would be responsible for rendering the bulk of my game objects and would need to be updated in my main game loop, while each of the subsequent layers would provide additional functionality such as chat (brown), interacting with my game objects from an "inspector" (blue), and a static menu (purple).

 

In order to achieve this, I have the following questions: 

 

Can one renderer render multiple stages?

 

If so, could I create 4 separate stages, add my DisplayObject's to each stage, then render each stage individually using the same renderer?

 

Does each section of my game need it's own renderer?

 

I've seen examples where people will use multiple renderers (which will yield multiple canvas elements) and attach a single stage to each renderer. Each canvas is then positioned directly on top of each other and the top most stages are transparent.

 

Thanks for the help in advanced and I look forward to learning a lot from this board!

Brandon

Link to comment
Share on other sites

  • 4 years later...

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...