marciodrosa/ZineMob — Issue #4: Controllers refactoring
Author: marciodrosa
Created: 2012-03-06 02:21:18+00:00
State: open
Labels: feature

Modifications on controllers classes:

SceneController
- this is the current "Controller" class, but with a new name;
- the old "SceneController" class should be removed. To access the current attached scene, a method getScene() will be available.

GuiController
- this is like the current "GuiEventesController" class, but with a new name and new features;
- the GuiScene can be accessed with the getGuiScene() method;
- when the user creates a class that overrides the GuiScene, he can set a GuiController object to this scene;
- each window of this scene is controlled by this controller, unless the user sets a GuiController specifically to this window;
- the GuiScene calls the init() method of the attached GuiController when the scene starts running.

FlowController
- loop execution, in each iteration calls the executeFlow(Event) method, that should be implemented by the user;
- the game Ultimate Linos used something like that: each "flow" is a different part of the game; examples: audio setup, main menu, the game itself, etc.

Event (or Message, or EventMessage)
- this is the current "GuiEvent" class, but with another name; it will be used by the FlowController too.
- contains the int id and Hashtable parameters