Menu

Adding Scenes

We are adding Scene as the new top-level drawable component, to organize things for transitions. Scene subclasses GameObject because it uses the Install Pipeline.

Things like the Locator and Timer may get moved into the Scene, so it stays a self-contained unit, and makes tearing down a Scene simpler.

The RenderService manages Scenes and their lifecycle. Transitions are subclasses of Scene and use render-to-texture and multi-texture techniques.

The Install Pipeline for a Scene uses composite pattern, so Scene delegates Resource Load, Render, etc. to its component GOs. Before calling install() the Scene is populated with its components. Any components installed thereafter are automatically associated with the current scene.

Starting/Transitioning a Scene is a specific method call on the GameCycle class. This posts a message to the apartment to pick up processing. Expected use is to call this method from the loaded() callback for the Scene.

Posted by g-dollar 2013-04-22

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.