As far as I know most of the stock music in UT were .mod tracker songs or the like. As far as I know, such songs and their playback software had built in tempo feature. Now, I'm wondering if it would be possible to slowly increase the tempo of a song (not the pitch, just the tempo) gradually as time goes by OR when the remaining time is running out / maximum team score is being reached?
Or, is it possible to create a mod that would change the music track when certain % of gametime passes/ certain % of max team score by the leading team is achieved?
Dynamic Music mod for UT99 - is it possible?
- [did]Madis
- Adept
- Posts: 297
- Joined: Tue Jun 03, 2008 2:48 pm
- Personal rank: カニはとても美味しい
- Feralidragon
- Godlike
- Posts: 5493
- Joined: Wed Feb 27, 2008 6:24 pm
- Personal rank: Work In Progress
- Location: Liandri
Re: Dynamic Music mod for UT99 - is it possible?
No, at least not through UScript afaik. Maybe only possible but using custom drivers to play the music.[did]Madis wrote:As far as I know most of the stock music in UT were .mod tracker songs or the like. As far as I know, such songs and their playback software had built in tempo feature. Now, I'm wondering if it would be possible to slowly increase the tempo of a song (not the pitch, just the tempo) gradually as time goes by OR when the remaining time is running out / maximum team score is being reached?
Yes, that's possible and quite easy to do. The music would be changed in-game by the same function that changes it in MH and SP maps for example (see MusicEvent), and the mutator would just keep updated during the game time, and once the time or score reaches the configured values or percentages like you want, it would change the music.[did]Madis wrote: Or, is it possible to create a mod that would change the music track when certain % of gametime passes/ certain % of max team score by the leading team is achieved?
- [did]Madis
- Adept
- Posts: 297
- Joined: Tue Jun 03, 2008 2:48 pm
- Personal rank: カニはとても美味しい
Re: Dynamic Music mod for UT99 - is it possible?
What I have in mind is online play.
In an ideal situation, in scenario A, where teamscore limit is 10 and the mutator is taking account the teamscore of the leading team. I'd want the mutator to first speed up the tempo of the track X lets say, 10% every time teamscore of the leading team increases by one point, until lets say, teamscore reaches 6. When that happens, track Y starts playing with default speed, with tempo rising 10% every time the teamscore of the leading team increases.
Now, is this possible by whatever means without quitting the game? Or to put it simply - can this be achieved so that the player can just connect to the server and download the mod from the game?
In an ideal situation, in scenario A, where teamscore limit is 10 and the mutator is taking account the teamscore of the leading team. I'd want the mutator to first speed up the tempo of the track X lets say, 10% every time teamscore of the leading team increases by one point, until lets say, teamscore reaches 6. When that happens, track Y starts playing with default speed, with tempo rising 10% every time the teamscore of the leading team increases.
Now, is this possible by whatever means without quitting the game? Or to put it simply - can this be achieved so that the player can just connect to the server and download the mod from the game?
- Feralidragon
- Godlike
- Posts: 5493
- Joined: Wed Feb 27, 2008 6:24 pm
- Personal rank: Work In Progress
- Location: Liandri
Re: Dynamic Music mod for UT99 - is it possible?
Like I said, regarding tempo, I think nothing can be done around that. The only way to have several tempos, would be make more versions of the same music with changed tempos (but that way the new music would mismatch/offset when starting).
Regarding changing music, an easy mutator can do that without any problems at all. And of course, any player would download it without any problems at all.
Regarding changing music, an easy mutator can do that without any problems at all. And of course, any player would download it without any problems at all.
- [did]Madis
- Adept
- Posts: 297
- Joined: Tue Jun 03, 2008 2:48 pm
- Personal rank: カニはとても美味しい
Re: Dynamic Music mod for UT99 - is it possible?
Just changing music doesn't quite cut it. I know that most mod tracker songs should naturally support changing the pitch/tempo of the track, so I was curious if it was at all doable.
Re: Dynamic Music mod for UT99 - is it possible?
It's not possible for currently existing maps and mod.
Mods can be structured any way the one wants it. If he wants he can have at least 256 different looping sections in a single mod file. Each one can have it's own tempo, notes... anything. In Uscript you can change which mod section you want to play. For example, most of the songs from unreal have 2 looping sections. One is the normal one and the other is a more upbeat version or variation. I don't really know if the upper limit is 256, but I always assume that even the smallest variables in a program are byte sized.
There is also an extreme solution. You could use Uscript to code the a Uscript music player that can play your own mod format. You have pulse code modulation and samples in Uscript, that's all that is needed for a basic tracker. I don't know about the rest but if you can change the pitch and volume of the sound while it's playing in Uscript, you can even implement volume envelopes, vibrato, portamento effects ect. That way you have 100% control over tempo and everything. You can double it or triple it whenever you want, and you won't be limited by 20 year old module formats, but by your ability to code and the possibilities in Uscript. Yeah, that is kinda extreme and it will severely limit the amount of in-game sound channels.
However if you do do it, you're awesome.
Ok, now someone should go and check and prove me wrong that galaxy.dll actually does have a function that you can access to change global tempo and it is just that it was never actually used before.
Mods can be structured any way the one wants it. If he wants he can have at least 256 different looping sections in a single mod file. Each one can have it's own tempo, notes... anything. In Uscript you can change which mod section you want to play. For example, most of the songs from unreal have 2 looping sections. One is the normal one and the other is a more upbeat version or variation. I don't really know if the upper limit is 256, but I always assume that even the smallest variables in a program are byte sized.
There is also an extreme solution. You could use Uscript to code the a Uscript music player that can play your own mod format. You have pulse code modulation and samples in Uscript, that's all that is needed for a basic tracker. I don't know about the rest but if you can change the pitch and volume of the sound while it's playing in Uscript, you can even implement volume envelopes, vibrato, portamento effects ect. That way you have 100% control over tempo and everything. You can double it or triple it whenever you want, and you won't be limited by 20 year old module formats, but by your ability to code and the possibilities in Uscript. Yeah, that is kinda extreme and it will severely limit the amount of in-game sound channels.
However if you do do it, you're awesome.
Ok, now someone should go and check and prove me wrong that galaxy.dll actually does have a function that you can access to change global tempo and it is just that it was never actually used before.