forked from endless-sky/endless-sky
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* This PR is a revival of endless-sky#7538. * Authorship from prior code review is preserved. Feature Summary --------------- Adds the possibility to add playlists to the game that are only played in certain locations and if certain conditions are met. Example: ```ruby track "test2" volume 0.1 #add 0.1 to volume idle "music/mainscreen" #idle track, played during normal gameplay combat "music/mainscreen" #combat track, played during combat landing "music/mainscreen" #landing track, played while landed track "test1" idle "music/haispace" combat "music/haispace" landing "music/haispace" playlist "test" to play #conditions for playing this playlist has "Hai Intro: done" location #locationfilter for where to play this not government "Hai" priority 1 #the priority, higher priority playlist will be chosen over lower priority playlists weight 10 #the weight of a playlist inside of its priority layer, higher weight means more probable to be chosen tracks "linear" "test1" 20 "test2" 20 ``` Detailed Explanation -------------------- `track NAME` holds the following child keys. * `NAME` the name of the track * `volume` (default 0): a value that should be chosen between -1 and 1 that gets added to the current volume of the music. (use this with small values, otherwise users who want dim music will be annoyed.) * Three categories of music associated with this track. The tracks will be played when the player is in their state. If one is not given, nothing will be played in that state. * `idle` * `combat` * `landing` `playlist NAME` holds the following child keys. * `NAME` the name of the playlist. * `to play` conditions that determine if this playlist can be played. * A `location` filter for where this playlist will be played. * A `priority`, higher priorities will always play over lower priorities. * A `weight`, playlists with higher weight are more likely to be played inside the same priority. * `tracks` * A progression style: `linear`, `random`, or `pick` (pick means that one track will be picked and repeated until the playlist is switched) * Various tracks with weights to them, weights only matter for pick or random progression style. This would play either track one or track two when you are not in Hai government zone. Testing Done ------------ TBD Important --------- * Asset pull request: endless-sky/endless-sky-assets#127 Checklist --------- - [ ] Update with upstream master including CMake. - [ ] Do some testing. Co-authored-by: Hurleveur <[email protected]> Co-authored-by: tibetiroka <[email protected]>
- Loading branch information
1 parent
a80c84a
commit 3b9a54b
Showing
21 changed files
with
577 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.