{"size": 1075, "ext": "js", "max_stars_repo_path": "scripts/main.js", "max_stars_repo_name": "hellonavneet/phasergameclass", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "scripts/main.js", "max_issues_repo_name": "hellonavneet/phasergameclass", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "scripts/main.js", "max_forks_repo_name": "hellonavneet/phasergameclass", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 28.2894736842, "max_line_length": 113, "alphanum_fraction": 0.6353488372}
var screenWidth = 1000;
var screenHeight = 600;
var playerHeight = 28;
var playerWidth = 28;

playState = {
    preload: function() {
      game.load.image('starfield', '/assets/starfield.png');
      game.load.image('player', '/assets/player.png');
    },
    create: function() {
      spaceField = game.add.tileSprite(0,0, screenWidth, screenHeight,'starfield');      
      
      //Top Left
      player = game.add.sprite(0, 0, 'player');

      //Top Right
      player = game.add.sprite(screenWidth - playerWidth, 0, 'player');

      //Bottom Left
      player = game.add.sprite(0, screenHeight - playerHeight, 'player');

      //Bottom Right
      player = game.add.sprite(screenWidth - playerWidth, screenHeight - playerHeight, 'player');

      //Center
      player = game.add.sprite((screenWidth/2) - (playerWidth/2), (screenHeight/2) - (playerHeight/2), 'player');
    },
    update: function() {

    }
};

var game = new Phaser.Game(screenWidth, screenHeight, Phaser.Canvas, 'mygame');
game.state.add('mainState', playState);
game.state.start('mainState');

