Skip to content

Commit

Permalink
Merge branch 'master' of github.com:DancingBanana/game-off-2012
Browse files Browse the repository at this point in the history
Conflicts:
	public/coffee/models/Loader.coffee
  • Loading branch information
rogeruiz committed Dec 1, 2012
2 parents 62285a7 + dfc8e65 commit 39e45be
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions public/coffee/models/Loader.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@ define [
constructor: ->
@nextLevel 1
@currentLevel = 1
$canvas = $ '#gamescape'
@canvas = $canvas.get 0
@sound = new SoundHelper $canvas
@loadLevel Level
$('#gamescape').on 'requestLevel', (e) =>
@loadLevel @currentLevelRequest
# @currentLevel = 1

loadLevel: (levelRequested) =>

Expand All @@ -34,6 +41,8 @@ define [
do goal.destroy
do player.destroy

world = boxbox.createWorld @canvas, levelRequested.World

grounds = (new GroundEntity world, options).register() for options in levelRequested.GroundEntity

doors = (new DoorEntity world, options).register() for options in levelRequested.DoorEntity
Expand Down

0 comments on commit 39e45be

Please sign in to comment.