一个轻量级的HTML5游戏框架:BlocksJS

jopen 11年前

一个轻量级的HTML5游戏框架:BlocksJS

(function () {          var game, slice;         // Create a game      game = BLOCKS.game();         // Create an example slice      slice = BLOCKS.slice({          layer: BLOCKS.layer(game.element), // Create a new canvas for the slice          imageSrc: "images/coin.png", // Define sprite sheet location          numberOfFrames: 10, // Define number of frames of animation          loop: true      });         // Notify the slice of game loop      game.update = slice.update;         game.render = slice.render;    } ());         
http://blocksjs.com/