Fix bugs in note controller being removed
This commit is contained in:
@ -13,7 +13,8 @@ func _ready():
|
||||
|
||||
func button_pressed():
|
||||
NotePlayer.stream = NoteAudio
|
||||
NotePlayer.play()
|
||||
if !NotePlayer.playing:
|
||||
NotePlayer.play()
|
||||
|
||||
func chord_changed(chord):
|
||||
var resource_string = "res://audio/%s/%s%s.ogg" % [chord, chord, self.name]
|
||||
|
@ -7,10 +7,10 @@ var NotePlayer: AudioStreamPlayer
|
||||
func _ready():
|
||||
RhythmPlayer = get_node("/root/Control/RhythmPlayer")
|
||||
ChordPlayer = get_node("/root/Control/ChordPlayer")
|
||||
NotePlayer = get_node("/root/Control/NotePlayer")
|
||||
self.pressed.connect(button_pressed)
|
||||
|
||||
func button_pressed():
|
||||
RhythmPlayer.stop()
|
||||
ChordPlayer.stop()
|
||||
NotePlayer.stop()
|
||||
if RhythmPlayer.playing:
|
||||
RhythmPlayer.stop()
|
||||
if ChordPlayer.playing:
|
||||
ChordPlayer.stop()
|
||||
|
Reference in New Issue
Block a user