On android, the game goes blank {only the physics debug draw continues to work} when the game is restored after being paused... very very weird. Need to investigate...
The Update() method in the ProcessScheduler needs to be rewritten. The processes that are active need to be checked Separately from the processes that are already terminated.
Currently everything is being processed in one big switch statement. If any process attaches a child and deletes itself, the iterator updates to incorrect value resulting in a Crash.
The entire scene graph and matrix stack has to be revised. Very ugly hack implemented in SpriteNode's PreRender function. This is to ensure that ONLY the leaf nodes like sprite get multiplied by CSF.
Side effect of this is that if I need to scale leaf node, i need to put it "inside" an empty container.
If the game is resumed from the background, the OpenGL surface goes totally black. As it appears the EGLContext is being destroyed when the app goes into background.
For now, Implement component factory that returns a fully initialised view component --> It should be able to accept xml file and return a VIEW component based on that description.
When this is implemented, extend the component factory and then start working on the Actor factory.
The activity is destroyed and then re-created as it goes into background and then to foreground, or if the orientation changes. Need to implement state saving in Android which should save the current state of the game.
Please implement efficient mechanisms for saving and loading current game state. This should be very detailed, e.g: even the position/color/angle of individual particles should be recreated upon restore.
Instead of storing a strong pointer to actor, just store a weak pointer to the actor in ALL of the components so that it doesn't result in a memory leak as it is happening right now :S
Well, this is not going to be a realistic physics at all. Just some candies falling with constant speed. Also need to implement collision detection specially keeping in view the "tunnelling" since candies will be moving fast.
Currently the ActorComponents are very very tightly coupled. Decouple them by using event manager. Also a huge army of header files is included on top of almost every source. Try to improve that as well.
Right now the factory methods are hiding all the details, they read in XML file and create a corresponding object {view or actor etc}. But reading XML is SLOW. The Engine must provide EASY facilities to create new objects from the code.
The Engine also should provide mechanisms to clone existing objects from memory {for efficient creation}.
Whenever an even occurs it calls appropriate listener function. Now IF a listener (specially of the same event) is removed from WITHIN the SAME initially called listener, EventDispatcher will crash (because it never got to update the listenerMap within the same loop)
Never delete a listener from within another listener SPECIALLY having the same EventID. Mark the listener as "ready for deletion" and then erase it from somewhere else such as ProcessSchedular or something
Even though the Scene Graph 2D is properly calling "Render()" for all children but it is ONLY calling "Update()" for the FIRST child. Remaining children do not get updated.