projects
/
koperkapel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Play weapon sounds when firing.
[koperkapel.git]
/
koperkapel
/
weapons.py
diff --git
a/koperkapel/weapons.py
b/koperkapel/weapons.py
index f07caedb2404ae802bc94f280ea839fc9a38f621..ee83eb816c6eb5c9295db74c05fb78199d506e56 100644
(file)
--- a/
koperkapel/weapons.py
+++ b/
koperkapel/weapons.py
@@
-18,6
+18,10
@@
class Weapon:
if sound:
self.sound = sounds.load(sound)
+ def play_sound(self):
+ if self.sound:
+ self.sound.play()
+
WEAPONS = [
Weapon("spit", damage=1, bullet_range=2, can_tape=False,