ported to phaser 2.2.1