d2d.toolkit.game



abstract class Game;
Class for easily creating a window

protected @property ref int windowWidth();
Window start width, will not update afterwards

protected @property ref int windowHeight();
Window start height, will not update afterwards

protected @property ref Bitmap windowIcon();
Window icon, will not update afterwards

protected @property ref string windowTitle();
Window title, will not update afterwards

protected @property ref int maxFPS();
Max FPS, will not update afterwards

protected @property ref WindowFlags flags();
Window start flags, will not update afterwards

protected @property Window window();
Handle to the window.

protected @property ref ShaderProgram postShader();
Optional post processing shader.

protected abstract void start();
Start function will get called before window is created. Variables can be changed here.

protected abstract void load();
Load function thats meant for loading content.

protected abstract void update(float delta);
Will get called every frame before
draw
.

protected abstract void draw();
Draw code goes here,
window.display
is not needed.

protected void onEvent(Event event);
Happens when some window event gets called.

void run();
Starts the window and calls all functions


Page generated by Ddoc.