Commit graph

9 commits

Author SHA1 Message Date
Charles Dang
ee49c0286b Properly clean up lua_music_track object 2017-05-10 00:12:08 +11:00
Charles Dang
98da5cf2cf Renamed second music_track class for clarity 2017-05-10 00:01:41 +11:00
Charles Dang
e4f03fe459 Moved all preferences source files into a single folder 2017-05-04 11:04:19 +11:00
Jyrki Vesterinen
9edf49e3af Remove an unused variable
Thanks to @matthiaskrgr for noticing.
2017-04-29 10:34:58 +03:00
Celtic Minstrel
a694201c02 A few more improvements to the music API
- Handle all plausible cases of assigning into the playlist
- Allow changing the current track to an existing one on the playlist
- Allow getting playlist as a real array instead of an array-like proxy
  (Could be useful for storing it to a WML variable, for example)
2017-04-29 00:01:40 -04:00
Celtic Minstrel
c04456dec1 Store music tracks as shared_ptrs 2017-04-27 17:49:32 -04:00
Celtic Minstrel
eb0947c863 Some improvements to the new Lua music API
- Allow removing a track by index and fixup the "set track" interface
- Commit music changes only after event completes, not after any control=flow tag is executed
- Allow inserting a track into the middle of the playlist
- Allow assigning a config to an existing track to overwrite it
- Use std::find when checking for duplicate tracks
2017-04-27 17:09:16 -04:00
Celtic Minstrel
5b4dbe1c61 Port [volume] to Lua
This also fixes [volume] considering 100% to be an invalid volume.
2017-04-27 17:09:05 -04:00
Celtic Minstrel
6906ced4e7 Properly port [music] to Lua 2017-04-27 17:09:03 -04:00