summaryrefslogtreecommitdiffhomepage
path: root/player.lua
diff options
context:
space:
mode:
authorAki <nthirtyone@gmail.com>2017-02-10 00:13:01 +0100
committerAki <nthirtyone@gmail.com>2017-02-10 00:13:01 +0100
commit1a6b183f2b3457b62b7a403209bec6184c6c6106 (patch)
tree03b0c504c8fe15fd9315d4ef91d444a72000cd0a /player.lua
parent7c37217f4bc21139b34fafd5cb140f483129a10c (diff)
downloadroflnauts-1a6b183f2b3457b62b7a403209bec6184c6c6106.zip
roflnauts-1a6b183f2b3457b62b7a403209bec6184c6c6106.tar.gz
roflnauts-1a6b183f2b3457b62b7a403209bec6184c6c6106.tar.bz2
Cheer sound played on last naut being killed
Diffstat (limited to 'player.lua')
-rw-r--r--player.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/player.lua b/player.lua
index 6195da6..f08ca19 100644
--- a/player.lua
+++ b/player.lua
@@ -439,8 +439,8 @@ function Player:respawn()
end
-- Sounds
-function Player:playSound(sfx)
- if self.alive then
+function Player:playSound(sfx, force)
+ if self.alive or force then
local source = love.audio.newSource(self.sfx[sfx])
source:play()
end