Topic: Developer
andersand.net Topic Opener |
Posted at: 2024-11-12, 20:42
Hello, I made a small feature a couple days back, and I just wanted to say hello and ask about a feature I would like to see in the game - If encouraged I would like to add a basic music player that I feel is missing. After my last small feature, so far I find the WL code base is very intuitive and I feel I could do this, although I should confess from experience that probably comes from lack of knowledge about the more intricate parts of the code I would have to make a window this time and extend the sound handler etc, etc. Have not started planning yet, as I will not put time into it, unless I can be pretty sure this will end up in the game if I do it right (that the effort is supported by you devs). The idea is to make a simple player like in settlers 2, but not necessarily the exact same. It should do have the obvious playback features, like play, stop, next, previous, optional shuffle and the ability to enable/disable the tracks the player prefers. Optional shuffle and to play previous track could be postponed to a v2 of the player since this would requires more changes (playback history). What do you guys think? I plan to spend some time on this and make it work very good, but I don't want to waste time if there is no support or there is resistance to the feature, so hence this post. Thanks! Edited: 2024-11-12, 20:49
Top Quote |
andersand.net Topic Opener |
Posted at: 2024-11-12, 20:46
To expand on the idea, I think it would be neat if the music tracks were titled in the player so we don't get a list of music_01, music_02 or "Track 01", etc... Rather it would be nice to have a playlist with good names, maybe the musicians have actual names for (some of) the songs? Top Quote |
Nordfriese |
Posted at: 2024-11-12, 21:00
Hi andersand.net and welcome to the forum While I personally usually play without sound, I think there are probably many players who would appreciate it, no objections from my side. Big +1 for displaying titles Top Quote |
andersand.net Topic Opener |
Posted at: 2024-11-12, 21:15
Thank you Nordfriese! Pleased to hear that you support this feature idea! Also nice that there are some song names floating around. If we decide to go for this, perhaps we could start a thread at the music subforum to gather song names informal or otherwise I feel motivated to get started with this, as I think it will add a bit to the game's atmosphere with good name for the music tracks and for players like me who are picky when it comes to music, it's nice to get more control over it. Top Quote |
tothxa |
Posted at: 2024-11-12, 23:57
Most music files have embedded tags with the titles. As for the music player window, I don't want to discourage you, but personally I can't see the point. I agree with Andy Alt on this. Top Quote |
kaputtnik |
Posted at: Yesterday 00:15
+1 Top Quote |
andersand.net Topic Opener |
Posted at: Yesterday 18:03
Thanks for the feedback. Andy Alt wrote that he did not see the need to allow users to play their own music by specifying a folder. I agree as well, but my idea is simply a music player for the music that comes with the game. Perhaps a picture would be useful to make it more clear what I suggest, as I understand there is support for this to be in the sound options window. Here is a simple mockup: https://pasteboard.co/HNjLQEcFg67J.png Top Quote |
andersand.net Topic Opener |
Posted at: Yesterday 22:16
Thanks for the tip! Will have to look into how to read vorbis comment of the music files from c++ There are indeed quite a few titles, some good ones and some I recon deserve a real non-generic title.
Top Quote |
tothxa |
Posted at: Today 01:34
Looks like SDL can do it: https://github.com/libsdl-org/SDL_mixer/blob/a37e09f85d321a13dfcf0d4432827ee09beeb623/include/SDL_mixer.h#L995C1-L1050C82 Top Quote |