Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- THIS IS THE FIRE CLASS
- --]]
- Fire = {}
- --local sLoader = require("SpriteHelper.SpriteHelperLoader");
- --local magicBulletAnim = sLoader:createAnimatedSpriteWithName( "granadeSpriteSheet_1", "magicBullet", "MagicBulletSH.pshs", "magicBulletAnim")
- function Fire:new()
- local magicBullet = magicBulletAnim
- magicBullet:prepareAnimationNamed("magicBulletAnim")
- magicBullet:playAnimation()
- physics.addBody(magicBullet,"dynamic")
- magicBullet.x = --Here is where I get lost this values will be parsed to the player
- magicBullet.y = --Here is where I get lost this values will be parsed to the player
- function magicBullet:touch()
- transition.to( self, { time=20000, alpha=0, onComplete=self })
- end
- function magicBullet:onComplete()
- self:removeSelf()
- end
- magicBullet:addEventListener("touch", magicBullet)
- return Fire
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement