Jump to content

Custom Game Objects


Recommended Posts

  • 2 weeks later...

I would like to know that too. It would be nice if I could create my own object and register it with the GameObjectCreator and GameObjectFactory. I have some objects extending e.g. Sprite that offer some extra functionality/display styles. That way I could make my code cleaner by using this.add.something and it would use and process config objects with some extra parameters that I use for configuration.

As Paul said it is not a problem if you edit the Phaser source, but I couldn't find a way to register objects with a Factory without changing the Phaser source. GameObjectCreator and GameObjectFactory are now probably "private" and therefore can not be used outside of Phaser source.

I hope things are not too crazy in the final week before the release. Good luck!

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.

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