When activating a trigger that starts an .mp3 file, map changes will cause the song to start all over again rather than continue playing between level loads. It also restarts when the .mp3 file is COMPLETELY FINISHED.
This happens in the Linux version of Half-Life. Does it happen with Windows users too?
I just noticed this problem as well, both with the normal 48kbps soundtrack, and with custom content 128kbps MP3's. It's readily apparent during the tram ride, though luckily the audio is shut off by the map before a level transition at the end. However, no such luck later in anomalous materials. The music that plays when you pick up the HEV suit will restart when you transition levels; and will even restart after a level transition when the music had already finished. :( It never ends!
I'm running Windows 7 with the latest Half-Life version:
Protocol version 48
Exe version 1.1.2.2/Stdio (valve)
Exe build: 14:12:58 Feb 25 2013 (5968)
Yeah, there is an issue with the music. Those MP3s should play like CD audio tracks: only once and independent of loading saves and changing levels. Just like in the WON version of Half-Life.
Did some more experimenting with this. It's definitely happening all over Half-Life 1; but strangely not in Opposing Force or Blue Shift. It also happens with music triggered by levels and by music set to play through console commands.
Easiest way to reproduce it is to find a level transition you can cross back and forth between, play the 28th track (cd play 28) wait for it to finish (it's a short track) and then cross the transition; it'll start playing again every time, up until a new song is triggered at which point THAT song will start playing again after a level transition.
Still running Windows 7
Protocol version 48
Exe version 1.1.2.2/Stdio (valve)
Exe build: 18:02:44 Apr 3 2013 (6005)
BS and OF are broken. HL is partially fixed. Those games should play music just like I said above.
BS and OF just stop playing music when they hit a level transition (they don't play the RIGHT music, but that's another issue). They don't have this weird music restart glitch.
I'm not entirely sure it's possible for Half-Life to play an audio file during a load screen (CD music is different because that's handled on a hardware/operating system level). If it's not, then maybe it's possible for Half-Life to remember where the sound got cut off at and start it again once the level loads, but I'm just speculating at this point.
It is possible. My patched WON Game of the Year version has MP3 decoder and it plays music just like CD audio tracks.
Any ETA on when this will be fixed? (Especially since the music has been upgraded to 128 kbps) It surprising how mood breaking it is for the HEV music to repeat over and over. It sucks all the pre-reacter incident eeriness from the game...
I wonder if this was intentionally added as a way to get the opening tram music to play during the entire tram ride, since Half-Life kills the audio on level transitions. In which case I wonder if it's possible to turn it off for the rest of the game? Though if I had to choose between one and the other, I'd go with the music not restarting at all.
Maybe an alternative could be to alter the levels to start the tram music at the start of every map during the tram ride?
Okay, man was this subsystem busted. Assorted changes over the years meant the mp3 soundtrack wasn't playing for the right amount of time, I've gone through it now and I believe I have it back the way it used to be.
You are a beautiful person, Alfred. Thank you very much. If you're going to PAX Prime this year and I run into you, I owe you a coke or something! :smile:
Couple of notes about the current system
Anywho, thanks again!
EDIT: Just noticed an anomaly. In map c1a0c (the beginning of Unforeseen Consequences) the music track that plays (Half-Life07.mp3) will continue to loop constantly until a new track plays. When I get time tomorrow, I'll run through the game looking to see if any more do this, but the only one I've found is the opening tram music which is supposed to loop.
Also, a new wrinkle on the things replaying when you start a new game or load a save game, apparently you load a game while one of these looping songs is playing, instead of continuing to play the song until it's finished, it'll restart when the game loads and then restart after every level transition like the glitch of yore.
Yeah, this thread needs to be reopen.
Start a new game (or load a map with the music track), than start Hazard Course or Multiplayer, the music will reappear.
Okay, I finally checked the other tracks in the game and none of the other ones have the issue, so it's just the one from c1a0c that's repeating unnecessarily.
What about opposing force? At the beginning of Worlds Collide and the lift to the final boss, the autosave or load function cuts the music off...I know it's a really minor issue, but I love the in game music, and this sort of thing makes me want to go back to owning the retail. In any case, please don't ignore opposing force's music issue. Thanks for fixing HL looping music btw, just got the update and it seems to work fine.
@mikela-valve I retested c1a0c and the music still continues to play after starting another map using the map command. This also happens with other music, for example starting c0a0 and then changing map.
I think music should be stopped when using the map command. changelevel and changelevel2 should continue to play music. It's not ideal since not all uses are supposed to do that but there is no way to specify whether a changelevel is programmatic or a user command.
As far as music stopping for all other games goes, a better way to detect whether music should be stopped is needed.
Currently this is handled in GameUI, CGameUI::ConnectToServer:
if ( /*CZero career checks*/ )
{
//Omitted
}
else
{
if ( strcasecmp(game, "valve") )
engine->pfnClientCmd("mp3 stop\n");
baseuifuncs->ActivateGameUI();
}
I think the simplest solution is adding a liblist.gam entry to control this. Other ways are unreliable, for example checking if you're playing a singleplayer game would fix it for all games but would break it for multiplayer. Ideally you could add an interface that lets GameUI query the client dll but that could get complicated.
Feedback from Facepunch user Marphy Black:
There's a lot of redundant reporting in these threads as well as conflicting reports apparently as a result of Alfred making some changes in 2013 (which I don't recall). This is in addition to the misinformaiton by a few people describing incorrect behavior. I'll summarize the intended behavior:
The bugs affecting music as of the current Steam build:
This report claims there's a problem where music tracks would restart after a map load. I have never experienced this, but the user in question says this occurred on Linux, and it may have been fixed by Alfred in 2013, so I can't confirm anything now. Truthfully, this is a terrible and confusing report that looks to be conflating two issues: music unnecessarily restarting after loads and music not playing through loads. The former no longer seems to be an issue, if it ever was. The latter is the actual problem still at hand.
I also have the same problem (a song triggered before a map-load being cut-off) occur with Windows (7) in Blue-Shift (Steam Version)
In the chapter "Captive Freight" (ba_yard4, ) It happens when I enter the open window of the (Freight Management Offices) before encountering HECU units in a warehouse. The music starts preparing for impending combat, but upon rounding the corner (and loading the next part of the map) the map loads, the music starts playing again for about one second and then abruptly stops.
_(I saw this thread and was suggested by steam support to ask about it on Half Life Github)_
@mikela-valve Can you look into this one?
7 years on... still not fixed...
7 years on... still not fixed...
At least is on a milestone now, Valve has other priorities, it's understandable sadly.
i dont know anything about coding but i would imagine this would be a simple issue to fix, at least considering theyve already fixed it in the base game
Most helpful comment
@mikela-valve Can you look into this one?