Jump to content

PixiJS Game States


jamespierce
 Share

Recommended Posts

Hi PixiJS Devs!

I don't know how to handle different states (Example states are: Intro, Main Menu, Game, Settings).

I found 10 year old posts saying to use DisplayObjectContainers for each stage / scene / state. Source: https://github.com/pixijs/pixijs/issues/153

Is that still accurate today with PixiJS?

I'm afraid to create a new stage, wipe it, and then not notice that it's slowly clumping up the memory as the game goes on.

Is it really that easy to change & manage game states?
1) Create a container for each state/scene
2) Wipe all visuals
3) Start drawing new stuff

Thanks in advance!

 

Link to comment
Share on other sites

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...