Commit graph

67 commits

Author SHA1 Message Date
Celtic Minstrel
9cccfd73b0
Extend the image localization system to sounds and music (#3935)
Fixes #2987
2019-03-03 16:13:30 -05:00
Martin Hrubý (hrubymar10)
674fda85b7 Migrate links to https if available - Fwd c18537edc0
(cherry-picked from commit bc4d22dc72)
2018-10-07 03:23:36 +00:00
Jyrki Vesterinen
bcc914bfe8 Fix #2602: music doesn't change immediately on loading a save
This time I added an option to disable the feature to allow the currently
playing track to finish when changing the playlist. This allows more
fine-grained control of distinct use cases.

In wesnoth.cpp:do_gameloop(), I reversed the order of the title screen
music and default music because otherwise adding the default music would
enable play_once for the title screen music and prevent instant music
change when the player loads a save. I play title screen music with
immediate=yes, so it's still played first.

(cherry-picked from commit 91afbfd586)
2018-10-07 03:22:18 +00:00
Jyrki Vesterinen
de1bdba769 Revert "Fix #2602: music doesn't change immediately on loading a save"
This reverts commit 94b69e0281.

(cherry-picked from commit cafede479c)
2018-10-07 03:22:18 +00:00
Jyrki Vesterinen
097244559f Fix #2602: music doesn't change immediately on loading a save
(cherry-picked from commit 94b69e0281)
2018-10-07 03:22:16 +00:00
Gregory A Lundberg
b5f76eff79
Bump copyright to 2018 2018-01-19 00:02:20 -06:00
Alexander van Gessel
749646a75b Make get_current_track_index safer to use
This prevents problems like issue #1861.
2017-10-30 21:17:05 +01:00
Alexander van Gessel
d063aa077a Don't use invalid music indices. Fixes #1861 2017-10-20 17:31:09 +02:00
Gregory A Lundberg
3acd4b8707 Fix warnings about missing function prototypes (#1878) 2017-08-04 21:36:38 -04:00
Pentarctagon
ad5bbd4131 Create wesnoth.music_list.previous, along with the __cfg field for tracks (#1728) 2017-05-29 08:51:06 -04:00
Charles Dang
2101353d36 Convert include guards to the shorter #pragma once
Turns out I mistook @celticminstrel's opinion that we should use include guards over pragma (737916e).
Since all major compilers support `#pragma once`, there's no reason not to use it.

For future mergability reasons, this excludes src/spirit_po and src/xBRZ. It also excludes src/boost-patched.
2017-05-09 19:41:37 +11: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
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
Celtic Minstrel
b4dc11ce36 Belated 2017 copyright update 2017-03-19 10:05:38 -04:00
Jyrki Vesterinen
bf510e7886 Pause the music when the game loses focus 2016-06-30 12:58:18 +03:00
Chris Beck
ba51524f6e update copyright to year 2016
using this shell script:

find src -type f -print0 | xargs -0 sed -i "s|Copyright (C) \([[:digit:]]*\)\([ ]*\)-\([ ]*\)2015|Copyright (C) \1\2-\32016|g"
2016-01-02 23:59:31 -05:00
Ignacio R. Morelle
6ee669803b Remove describe*_versions() functions, supersed by library_versions_report()
font::manager::init() had a call to the font::describe_versions()
function I just dropped since there's little point in having that line
there when one can just run wesnoth --version to get the full table now.
2015-07-09 03:22:37 -03:00
Ignacio R. Morelle
57ae45387a New Year copyright update 2015-01-01 19:07:35 -03:00
Chris Beck
aa0ec207e3 dump library versions also, when using wesnoth -v 2014-10-20 19:13:27 -04:00
Ignacio R. Morelle
a4f47a63c7 New Year copyright update 2014-01-01 02:08:52 -03:00
Eric S. Raymond
043c4f9fd3 Remove $Id$ cookies. 2013-03-26 21:41:37 -04:00
Mark de Wever
43b71f2ff0 New year copyright update. 2013-01-01 09:22:03 +00:00
Ignacio R. Morelle
6ca69b2df5 New year copyright update 2012-01-07 02:35:17 +00:00
Mark de Wever
ecbabea838 New year copyright update. 2011-01-01 15:57:50 +00:00
Mark de Wever
09e1e335a9 Remove unneeded includes. 2010-11-21 13:58:44 +00:00
Guillaume Melquiond
eeb047de55 Fixed file headers so that they match the content of the COPYING file. 2010-09-01 21:12:38 +00:00
Jérémy Rosen
58b319c6bc rework the [music_volume] tag to a more generic [volume]...
...to be able to adjust sound effect through WML, patch by lfernando
2010-05-09 10:10:41 +00:00
Jérémy Rosen
d7f3239c2f allow changing of music volume through WML,
...slightly modified from patch #1640 by lfernando
2010-04-23 14:55:31 +00:00
Mark de Wever
92f5f92ce5 New year copyright update. 2010-01-01 13:16:49 +00:00
Guillaume Melquiond
68e485ee3e Removed unused function sound::play_no_music. 2009-08-15 14:20:39 +00:00
Ignacio R. Morelle
61fb097e5d Partial refactoring of music and sound effects component.
The music_track struct has been rewritten (and "promoted" to class) and
music caching behavior in Wesnoth has changed a bit. This should not
noticeably affect performance or be visible to users in other ways (if
it is, we've got regressions).

There's a hidden, disarmed core bomb in this commit. Can you find it?

Formerly, the engine resolved binary paths to music files whenever it
hit one in the playlist. Now it resolves the binary path when
loading/editing the playlist, reducing the time it takes to play a new
track by an insignificant amount of time. It will also consider a
data/add-ons/foo/music/track1.ogg as a different file to
data/core/music/track1.ogg as far as the music cache is concerned, since
it now stores entries by real paths rather than just filenames.
2009-03-24 12:19:40 +00:00
Tomasz Śniatowski
ea31aa6324 expand sound:: interface a bit 2009-01-13 11:26:54 +01:00
Mark de Wever
a5d1d2e969 New year copyright update. 2009-01-01 10:27:41 +00:00
Jérémy Rosen
9840d115fa move the drawing code down into the frame object 2008-03-14 18:41:51 +00:00
Karol Nowak
bbc4c0bfb9 Made it possible to loop sounds in sound sources.
Clarified a FIXME comment. Fixed error reporting.
This part of code needs some refactoring soon.
2008-03-11 07:45:38 +00:00
Mark de Wever
001af46e6e Updated all headers to 2008. 2008-02-16 08:47:16 +00:00
Karol Nowak
e1701913da Make it possible to repeat a sound played with [sound] using repeat=.
Fix a bug with sound playing endlessly when fade is used.
2008-01-05 00:18:32 +00:00
Karol Nowak
2ae091daac Fixed points 2&4 of FR/bug 10559 - timer sound issues. 2007-12-30 22:50:53 +00:00
Patrick Parker
98b8dd96fa patch #797 Smooth music transitions based on ms_before and ms_after tags 2007-08-23 22:16:57 +00:00
Patrick Parker
b058ecda17 another attempt to fix bug#9734 for the linux people
(works on my system so just stabbing in the dark)
2007-08-19 03:34:33 +00:00
Mark de Wever
080eb69f60 Updated the headers to state GPL 2+ and a few changelog cleanups. 2007-08-15 13:41:56 +00:00
Patrick Parker
5cc4bd41e1 wire in the new timer sound and get rid of some of the sound glitches.
note: there is still one glitch, the timer sound will not start
playing while in a dialog (but now it will continue playing if a
dialog is opened).
2007-07-26 02:25:59 +00:00
Mark de Wever
bb01934b85 A rather large update which updates the copyright info
* Wesnoth is distributed under the terms of the GPL version 2, made
  that more explicit

* updated the copyright range to 2007

* updated Dave's email adress
2007-07-21 07:28:04 +00:00
Ali El Gariani
1d7be21104 do a reversion for Sapient 2007-04-25 01:20:00 +00:00
Karol Nowak
1c58327f0e Add a slider which changes volume of sound sources. 2007-04-24 20:53:12 +00:00
Patrick Parker
948be22738 code cleanup - sound sources 2007-03-19 22:54:52 +00:00
Patrick Parker
25eaa7b2b1 fix various bugs in the sound code 2007-03-19 07:28:17 +00:00
Patrick Parker
a32b17aed1 re-attempt at workaround for vector<Mix_Chunk*> deletion error
feel free to submit a "real fix"
2007-03-14 01:43:10 +00:00