Commit a58bb1a8 authored by santiago duque's avatar santiago duque

added second button and logic to stop events as a test

parent 95542bc4
......@@ -34,7 +34,6 @@ def setup_sounds():
global contentlist
global sound_dir
print("inside setup")
print(contentlist)
for content in contentlist:
......@@ -45,14 +44,10 @@ def setup_sounds():
):
sound = pygame.mixer.Sound(join(sound_dir, content))
sound_array.append(sound)
print(content)
print("sound array")
print(sound_array)
sound_playing = False
def play_sound(index):
global sound_playing
global cut_current_sound
......@@ -69,7 +64,7 @@ def play_sound(index):
channel = sound_array[current_sound_index].play()
while channel.get_busy():
pygame.time.wait(100) # ms
#pygame.time.wait(100) # ms
print("Playing...")
print(btn_array[current_sound_index].is_held)
print(btn_array[current_sound_index].is_pressed)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment