/zoeplat

To get this branch, use:
bzr branch http://9ix.org/bzr/zoeplat

« back to all changes in this revision

Viewing changes to player.lua

  • Committer: Josh C
  • Date: 2013-04-21 20:40:19 UTC
  • Revision ID: josh@9ix.org-20130421204019-14mx4bztdt4wnbg6
automated build script - pull love win/mac & assemble the parts

Show diffs side-by-side

added added

removed removed

Lines of Context:
12
12
   collisions = {},
13
13
   onWall = false,
14
14
   leftWallAt = 0,
 
15
   jump = love.audio.newSource('data/jump.ogg', 'static'),
15
16
   onNew = function (self)
16
17
              self.velocity.y = 0
17
18
              self.maxVelocity.y = 400
72
73
                     end
73
74
 
74
75
                     if the.keys:justPressed('up') and
75
 
                      (self.onGround or 
 
76
                      (self.onGround or
76
77
                       (DEBUG and the.console.visible) or
77
78
                       (love.timer.getTime() - self.leftWallAt < .1) ) then
78
79
                        self.velocity.y = -400
79
80
                        self.jumping = true
 
81
                        --love.audio.play(self.jump)
80
82
                     end
81
83
                  end,
82
84
   update = function (self, elapsed)