Jump to content

Correct way to control a scene


Recommended Posts

I'm trying to build an '90s style rpg game, think dragon warrior series, where it will have a UI box at the bottom of the screen where the user makes a choice like attack, move, eat etc

I'm thinking of having a game controller (phaser scene?) which updates a board scene and a UI box  scene and displays other scenes if necessary

I am thinking of passing in to the UI box an object with  message, an array of choices and  each choice will have a callback method

So as far as I can tell there are three ways to pass event information to a scene

1) use get scene method to get an instance of a scene and then make calls to that scenes methods

2) using event emitter

3) stopping and starting a scene and passing parameters into the create method

Is one way preferable or another? is there a good coding standard?  Would anyone be able to offer any other helpful hints on how to accomplish the above task


Thank you

Edited by MTiger
Link to comment
Share on other sites

  • 3 weeks 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.

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.


  • Recently Browsing   0 members

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