API Docs for: 0.1.0
Show:

zerk.game Class

Module: zerk

Game

Base class for games. All games should inherit from here.

Methods

_getConfigDefaults

() Object protected

Returns the default game configuration

This method should be extended by child classes to setup default game configuration.

Returns:

Object: Default configuration

_onLoadGameConfiguration

(
  • gameConfig
  • localConfig
)
protected

Fires when the game configuration is loaded

Parameters:

  • gameConfig Object

    Game configuration

  • localConfig Object

    Bootstrap configuration

init

(
  • config
)
async

Class constructor

Parameters:

  • config Object

    Game configuration

run

()

Run the game

This method should be extended by child classes to boot the game.

Properties

_engine

zerk.game.engine protected

The game engine

_jsonLoader

zerk.jsonLoader protected

JSON Loader