Skip to content

Commit 8f13815

Browse files
committed
Fixed an issue when selecting folders for typing sounds in exporting projects
1 parent 99b7424 commit 8f13815

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

addons/dialogic/Nodes/random_audio_stream_player.gd

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,9 @@ func load_samples_from_folder(path):
8080
var file_name = dir.get_next()
8181
while file_name != "":
8282
if not dir.current_is_dir():
83-
if file_name.to_lower().ends_with(".wav") or file_name.to_lower().ends_with(".ogg"):
84-
#print(dir.get_current_dir() + "/" + file_name)
85-
var resource = ResourceLoader.load(dir.get_current_dir() + "/" + file_name)
86-
#print(resource)
83+
var f = file_name.replace('.import', '')
84+
if f.to_lower().ends_with(".wav") or f.to_lower().ends_with(".ogg"):
85+
var resource = ResourceLoader.load(dir.get_current_dir() + "/" + f)
8786
samples.append(resource)
8887
file_name = dir.get_next()
8988
select_samples_from_folder = ""

docs/changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
- Added a new page to the docs about the [Text Events](https://github.com/coppolaemilio/dialogic/blob/main/docs/events/TextEvent.md)
1111
- Fixed a bug when trying to skip fade-in dialog animations [[idontkillcoyotes](https://github.com/idontkillcoyotes)]
1212
- Fixed an issue with typing sounds in exported projects
13+
- Fixed an issue when selecting folders for typing sounds in exporting projects; Thank you [AnidemDex](https://github.com/AnidemDex)!
1314

1415

1516
## v1.2 - Organize it!

0 commit comments

Comments
 (0)