patrickpietens/Rocket88 — Issue #1: Director Initializing
Author: mayakwd
Created: 2011-10-15 13:18:45+00:00
State: open

Hello!

It is better not to use XML to initialize the Director class, because the parameters which uses for the initialization are not clear, and it is not possible to find them without looking at the code. The better way - that is to create data structure with properties which will be uses for initializing, something like that:

public class DirectorInitConfiguration {
public var debugMode : Boolean = false;
public var enableSounds : Boolean = true;
public var frameRate : uint;
public var width : Number;
public var height : Number;
public function DirectorInitConfiguration(width: Number = 800, height: Number = 600, frameRate: Number = 51) {
this.width = width;
this.height = height;
this.frameRate = frameRate;
}
}