Skip to content

Maplenormandy/plunderwinds

Repository files navigation

PlunderWinds

PIRATES. TREASURE. ADVENTURE. NOT NECESSARILY IN THAT ORDER.


Installing and Running

First off, you need to install node and npm. There are a lot of tutorials on how to do that online so it's assumed you have the latest version up and running.

Then, go to the root directory of the plunderwinds repository and run the following commands. Depending on your system, you might need to run npm install -g * commands using sudo/admin.

npm install
npm install -g bower
npm install -g grunt-cli
bower install

Now, everything is set up and ready to run. To run, all you have to do is

grunt

The server will automatically look for changes to the javascript files in the game/ directory and reload when there are changes.


Coding Guidelines

  • Use 2 spaces for tabs in javascript.
  • Use JSDoc when documenting code. Please do not commit undocumented code!
  • Make sure you're not duplicating work. Read through other people's work before writing your own, and make sure you're not reimplenting a feature Phaser already has.
  • Write useful commit logs. For example, see this site. In particular, do not use git commit -m
  • Keep the Asana updated.

Quick Phaser Guide

There are a lot of basic tutorials out there for Phaser, particularly on the Phaser site, but none of them go into very advanced games. I like looking through the examples and finding code snippets there.

One thing that isn't documented very well is the States in Phaser. The game currently has 5 states:

  • Boot - loads the preloader
  • Preload - load all the assets
  • Menu - the main menu
  • Play - the state for the game
  • GameOver - the gameover screen

There's a lot of functionality noted over at the Phaser.State documentation and the Phaser.StateManager documentation.

In addition, there are 4 important folders/files:

  • assets - where all of our images and sounds go
  • css - where the stylesheets go
  • game - where all the javascripts for games should go
  • index.html (in the root directory) - the actual webpage that holds the game

Everything else is either autogenerated or config files. You shouldn't need to play around with the other files too much.

About

PIRATES. TREASURE. ADVENTURE. NOT NECESSARILY IN THAT ORDER.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors