sounds init
This commit is contained in:
parent
aff6fa8cd3
commit
1e9953b3b7
@ -27,6 +27,7 @@ function Bullet:update(dt)
|
||||
and UserPlayer2.y < self.y + self.height
|
||||
then
|
||||
UserPlayer2.health = UserPlayer2.health - 1
|
||||
GameSounds.hit:play()
|
||||
Bullets1 = {}
|
||||
end
|
||||
end
|
||||
@ -40,6 +41,7 @@ function Bullet:update(dt)
|
||||
and UserPlayer1.y < self.y + self.height
|
||||
then
|
||||
UserPlayer1.health = UserPlayer1.health - 1
|
||||
GameSounds.hit:play()
|
||||
Bullets2 = {}
|
||||
end
|
||||
end
|
||||
@ -52,6 +54,7 @@ function Bullet:update(dt)
|
||||
elseif self.p == 2 then
|
||||
Bullets2 = {}
|
||||
end
|
||||
GameSounds.hit:play()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user