- [NEW] Sound everywhere
- Game logic extracted to game.lua
This commit is contained in:
2
imp.lua
2
imp.lua
@@ -73,6 +73,7 @@ function imp.update()
|
||||
imp.x=imp.x-2
|
||||
if imp.x==78 then
|
||||
fireball.init(imp.hab,imp.x+8,imp.y+4,imp.flip)
|
||||
playchirp(audio_hit)
|
||||
imp.flip=not imp.flip
|
||||
elseif imp.x==-12 then
|
||||
imp.reset()
|
||||
@@ -81,6 +82,7 @@ function imp.update()
|
||||
imp.x=imp.x+2
|
||||
if imp.x==4 then
|
||||
fireball.init(imp.hab,imp.x+8,imp.y+4,imp.flip)
|
||||
playchirp(audio_hit)
|
||||
imp.flip=not imp.flip
|
||||
elseif imp.x==92 then
|
||||
imp.reset()
|
||||
|
||||
Reference in New Issue
Block a user