Skip to content
This repository has been archived by the owner on Mar 15, 2021. It is now read-only.
/ brunch-phaser2 Public archive

A Brunch skeleton for making games with Phaser 2 (Phaser CE)

Notifications You must be signed in to change notification settings

samme/brunch-phaser2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Brunch with Phaser 2

A Brunch skeleton for making games with Phaser 2 (CE). (For Phaser 3, please see brunch-phaser.)

You can use CoffeeScript, ES6, TypeScript, or plain JavaScript.

brunch new <project> -s samme/brunch-phaser2

Get started

  • Install (if you don't have them):
  • Run:
    • brunch new <project> -s samme/brunch-phaser2 (or see Clone, below)
    • npm run start or brunch watch --server watches the project with continuous rebuild.
    • npm run build or brunch build --production builds minified project for production.
  • Make:
    • Write your code in app.
    • Put game assets in assets.

Clone

The skeleton includes a sample game written in plain (ES5) JavaScript. If you'd like to start with a sample written in CoffeeScript, ES6, or TypeScript, create your new project by cloning this repository instead:

# Choose one
git clone https://github.com/samme/brunch-phaser2.git --branch coffee
git clone https://github.com/samme/brunch-phaser2.git --branch es6
git clone https://github.com/samme/brunch-phaser2.git --branch typescript

Phaser

Phaser is managed through npm. Update with:

npm update

If you want to switch libraries:

npm remove -S phaser-ce && npm install -S phaser

Add packages

npm install -S <package>

and require('<package>') in your code.

Add bower packages

bower install -S <package>

Add other libraries

Add the unminified script to vendor.

Plugins

You can remove any plugins for languages you aren't using.

# List
npm list --dev --depth=0

# Add (http://brunch.io/plugins)
npm install -D plugin-name

# Remove, e.g.,
npm uninstall -D babel-brunch coffee-script-brunch typescript-brunch

About

A Brunch skeleton for making games with Phaser 2 (Phaser CE)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published