Skip to content

seanewest/Quintus

 
 

Repository files navigation

Quintus + Browserify

This is an npm-friendly and browserified fork of Quintus.

Install

Make sure you have node.js installed

Then in your project folder:

$ npm install quintus

Now in your code you can

var Quintus = require('quintus')

Examples

You can run and live edit these examples on RequireBin:

ball disasteroids cannon collision

Usage

Browserified Quintus differs with mainline Quintus only in how it requires the Quintus engine and modules.

A sample module file:

module.exports = function(Q) {
    Q.gravityY = 0;
}

And here is how you can load Quintus and this module

var Quintus = require('quintus')
Quintus.MyModule = require('./my-module')

window.addEventListener('load',function() {
    var Q = Quintus().include("Sprites, Scenes, Input, Anim, 2D")
                     .include("MyModule")
                     .setup({ width: 320, height: 416 });
});

Local Installation

First clone and install:

git clone https://github.com/seanewest/quintus
cd quintus
npm install

Install beefy for fast and fun browserify development

$ npm install -g beefy

Now you can run each example like so:

$ cd examples/ball
$ beefy ball.js --open

License

MIT / GPLv2

About

Quintus + Browserify

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 98.4%
  • CSS 1.6%