Examples - Remove unnecessary Game Loop Creation
This commit is contained in:
parent
914b2aa5dd
commit
d11a47abc5
1 changed files with 0 additions and 14 deletions
|
@ -92,20 +92,6 @@ void activate(MouseEvent e) {
|
||||||
examples.forEach((Example ex) {
|
examples.forEach((Example ex) {
|
||||||
if (ex.canvas == c) {
|
if (ex.canvas == c) {
|
||||||
resetExample(ex);
|
resetExample(ex);
|
||||||
switch (ex.query) {
|
|
||||||
case "#while_loop":
|
|
||||||
ex.loop = new WhileLoop(new Game(ex.canvas));
|
|
||||||
break;
|
|
||||||
case "#fixed_variable":
|
|
||||||
ex.loop = new FixedLoopVariableRender(new Game(ex.canvas));
|
|
||||||
break;
|
|
||||||
case "#variable_timestep":
|
|
||||||
ex.loop = new VariableTimestep(new Game(ex.canvas));
|
|
||||||
break;
|
|
||||||
case "#dirty_flag":
|
|
||||||
ex.loop = new DirtyFlagRender(new Game(ex.canvas));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
addControls(ex);
|
addControls(ex);
|
||||||
} else {
|
} else {
|
||||||
resetExample(ex);
|
resetExample(ex);
|
||||||
|
|
Loading…
Reference in a new issue