mirror of
https://github.com/wassname/phaser.git
synced 2026-08-18 12:20:33 +08:00
Updated a lot of examples to Phaser 2.0 :)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
|
||||
var game = new Phaser.Game(800, 600, Phaser.AUTO, 'phaser-example', { preload: preload, create: create, update: update });
|
||||
var game = new Phaser.Game(800, 600, Phaser.CANVAS, 'phaser-example', { preload: preload, create: create, update: update });
|
||||
|
||||
function preload() {
|
||||
|
||||
@@ -28,6 +28,8 @@ function create() {
|
||||
// Populate the wave with some data
|
||||
waveData = game.math.sinCosGenerator(32, 8, 8, 2);
|
||||
|
||||
console.log(bmd.context)
|
||||
|
||||
}
|
||||
|
||||
function update() {
|
||||
@@ -44,6 +46,8 @@ function update() {
|
||||
|
||||
function updateWobblyBall()
|
||||
{
|
||||
|
||||
|
||||
var s = 0;
|
||||
var copyRect = { x: 0, y: 0, w: wavePixelChunk, h: 32 };
|
||||
var copyPoint = { x: 0, y: 0 };
|
||||
|
||||
Reference in New Issue
Block a user