2024-08-27 22:35:42 +00:00
|
|
|
extends BaseTrack
|
|
|
|
|
2024-08-27 22:37:54 +00:00
|
|
|
# This is the same as example but automatically populates names from file names instead of needing to manually define every track
|
2024-08-27 22:35:42 +00:00
|
|
|
# Gets the area that should become the name from regex
|
|
|
|
# You can use sites like this to help construct regex: https://regex101.com/
|
2024-08-27 22:37:54 +00:00
|
|
|
# Helpful when you have a large amount of music that all follows the same naming convention
|
2024-08-27 22:35:42 +00:00
|
|
|
|
|
|
|
func _init():
|
|
|
|
_default = {
|
|
|
|
"artist": "Kevin MacLeod",
|
|
|
|
"thumbnail": preload("res://thumbnails/example.bmp"),
|
|
|
|
"source": "https://incompetech.com/",
|
2024-08-27 22:38:21 +00:00
|
|
|
"disabled": true
|
2024-08-27 22:35:42 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
_autoload = {
|
|
|
|
"path": "res://music/example",
|
|
|
|
"pattern": "^[^.]+"
|
|
|
|
}
|
|
|
|
|
|
|
|
# You can still override things using a _tracks variable and the track set to the path to the file for what you want to override
|