Garry's Mod

Garry's Mod

63 ratings
Timely Music
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Tool
Addon Tags: Roleplay, Scenic
File Size
Posted
Updated
95.826 MB
23 Aug, 2021 @ 7:34pm
24 Feb, 2024 @ 3:57pm
13 Change Notes ( view )

Subscribe to download
Timely Music

In 2 collections by EntranceJew
EntranceJew's Addons
20 items
Timely Music Packs
7 items
Description
Relax to music relevant to your time and weather!

For lack of a music framework that supports hourly or weather-based music that integrates into StormFox 2's weather and time system, I present: Timely Music!
  • Time & Weather Based Music Provides a framework for playing music based on the time of day or the current weather. You can make a pack for energetic music in the day and relaxing jazz at night. You can add relaxing music for whenever it snows. If you don't have StormFox 2 then time will be based on your system clock, and weather will not be available.
  • Backwards Compatible In addition to having its own pack format, Timely Music can load music packs made for NOMBAT, DYNAMO, and Simple Battle Music. Only compatible with the packs, not the addons themselves.
  • Flexible System You can create a music pack by just organizing files in a folder to take advantage of one of the default auto-loaders, but you can also write lua code to control precisely how and when certain music tracks play.
  • New Audio Interface Timely Music is one of the only dynamic music mods that utilizes IGModAudioChannel which should mean better performance and easy looping of sound files, no more running ffmpeg scripts.
  • Combat Music In addition to supporting old music packs, Timely Music's own format supports DYNAMO/Simple Battle Music's style of combat music classification, with an option to use NOMBAT style battle music.
  • Fully Client-Side Does not require the server to have this addon! Bring it with you wherever you go. Server-Side enhancements will be coming soon that allow the combat music system to be more accurate.
  • Toggle Packs All music is organized into packs, which allows you to enable or disable them in-game. Creates toggleable packs automatically out of backwards compatible addons, even if they didn't have their own folder before.
  • Localizations (via DeepL) for: bg, cs, da, de, el, en, es-ES, et, fi, fr, it, ja, lt, nl, pl, pt-BR, pt-PT, ru, sk, sv-SE, zh-CN

Edit these settings from Utilities > User > Timely Music

Default Packs
Timely Music ships with 3 default packs, which may be broken out into their own addons later on after people make more of their own packs:
  • portal2active (hourly) requires Portal 2 to be mounted.
  • portal2ambient (hourly) requires Portal 2 to be mounted.
  • tiny_talos (scripted, time based) featuring music from the hit video game Tiny Talos[entrancejew.itch.io] composed by NoyemiK.

To Do
  • Better feature parity with backwards compatible addons.
  • Find a way to disable campaign music without overwriting the music files outright. This means you will need to use another addon that does that for now.
  • Buttons to manually control the playback (stop all tracks, skip track, etc)
  • PvP detection / handling team-fire.
  • Write-Up scripting API.
  • ... you tell me!

Make Your Own Packs!
If you make a pack, be sure to share it in the comments -- ones that work pretty good I will add to an official collection. You can use these logos[drive.google.com] to distinguish your addon's thumbnail if you would like. Here's how a Timely Music pack is laid out:
At the root of your pack addon you must make 3 nested folders, where $theme_name is your snake_case theme name: /sound/timely_music/$theme_name/ You can use all supported audio types: .ogg, .wav, and .mp3 After that, you can make your choice of folders depending on which features you want to support. Each folder that ends with '*' means you can put any files you want, or you can create more folders. The autoloader will prioritize traveling down folders. The autoloader will attempt to locate folders in the order that they're listed here: ⬤ /maps/$map_name/* 📝 $map_name matches a map name without the extension. If the map name doesn't match, then the autoloader will not travel down it, so use this sparingly. ⬤ /combat/$combat_class/* 📝 $combat_class will attempt to match an NPC's class against the internal TimelyMusic.NPCClassTags, you don't need to supply one of each type unlike DYNAMO. The default tags are: bosses, soldiers, cops, aliens, warning ⬤ /combat/* 📝 If there are no eligible combat class matches, then you can put files at the base of the folder and they will load when State.in_combat is set. All folders inside combat will not be visited if that state flag is not set, so be mindful of the order you set them. ⬤ /ambient/* 📝 The opposite of combat, everything inside the ambient folder will play only if the player is no longer in combat. ⬤ /weather/$weather_name/* 📝 $weather_name matches a StormFox2 description or weather class name. It resolves in a chain, the first item is always the description, the second is always that weather's class, and everything after that else is determined by their inheiratance. 📝 example: {"Snowing", "Rain", "Cloud", "Clear"} ⬤ /hourly/[00-23] 📝 The hourly folder can only handle 24 files, each of them named after an hour of the day in military time. These can be any file extension, and folders after this point will not be processed.

Some example structures:
⬤ Basic NOMBAT style pack: /sound/timely_music/mypack/combat/fight_song.ogg /sound/timely_music/mypack/ambient/relax01.mp3 /sound/timely_music/mypack/ambient/relax_02.wav ⬤ Weather enabled pack: /sound/timely_music/mypack/weather/Snowing/chill.mp3 /sound/timely_music/mypack/weather/Rain/smooth-jazz.ogg /sound/timely_music/mypack/weather/Clear/sun_-_rays.mp3 ⬤ Combat music based on weather: /sound/timely_music/mypack/weather/Snowing/combat/arctic_fight.ogg /sound/timely_music/mypack/weather/Rain/combat/swamp-stomp.wav /sound/timely_music/mypack/weather/Clear/combat/break_stuff.mp3 /sound/timely_music/mypack/weather/Radioactive/combat/fallout_radio.mp3 /sound/timely_music/mypack/weather/Lava/combat/StranglingGod.ogg

Please do not reupload this or include it in ServerContent, I'm working hard to keep this updated and compatible with other mods. I do not want people to get a bad impression that I can't help fix.

Also Try
  • Awesome Hands -- Immersive functional hands for DarkRP and sandbox.
  • Thunder Makes Fire -- Lightning starts fires where it strikes.
  • Lots of Currency -- Fun little collectibles to make things more joyous.
  • Death: Combined Luggage -- Drop all your weapons, ammo, money, and inventory in a convenient carrying case that combines with others to reduce lag.
  • Timely Music -- Play music based on the weather and time of day, compatible with most music addon packs.

Also consider buying my games[entrancejew.itch.io] if you want. No pressure.
50 Comments
DJG 13 Apr @ 2:25am 
I wonder, how "this" mod would react to the "Young Person's Guide To The Orchestra" ?
Callsign_Ewok 31 Jan @ 9:31am 
I did run into a new problem. With Stormfox 2 enabled a weird problem occurs where even if the hour music option on timely music is not enabled, it randomly switches tracks every starfox hour. Which is a bit annoying, trying to resolve that.
Callsign_Ewok 17 Dec, 2024 @ 8:16am 
It should be noted* I deleted my bug report from the discussions because it has been resolved. It mostly works flawlessly aside from it being random, I wish I could control the flow of tracks more, like a "avoid repeating the same track" option or the ability to pick songs in a queue manually.
Callsign_Ewok 4 Jun, 2024 @ 1:51am 
Great idea I had btw since I love this addon and I've gone all in on making my own custom folders, a feature that would be nice is to be able to select specific songs, maybe have some kind menu popup or something that allows me to pick specific tracks based on what I could want or crave at that moment, rather then randomly. Maybe even implementing a queue system so I can pick multiple tracks that will play one after the other as I picked and see fit.
EntranceJew  [author] 8 Feb, 2024 @ 9:18pm 
If a path doesn't start with "sound/timely_music" or would be detected by another soundpack addon, it shouldn't be finding things.
Callsign_Ewok 8 Feb, 2024 @ 7:28am 
I have a theory!! I do have nzombies rezzurection installed into my addons folder... I did see in the console upon boot it's reading it as a file system, the same message applies to the other timely music folders I think.

So maybe the nzombies folder in my addons is being read as a timely music folder by accident thus creating the weird messages upon changing tracks with the other timely music folders?
EntranceJew  [author] 18 Jan, 2024 @ 11:13pm 
It looks like it's making files or you're unintentionally copying files outside the folder where the songs are.
Callsign_Ewok 17 Jan, 2024 @ 9:15pm 
console debug to give you an idea.
Callsign_Ewok 17 Jan, 2024 @ 9:15pm 
TimelyMusic: SendEvent track_change 6542.6306369
TimelyMusic: Track Candidats: tactical_music_nombat2 sound/timely_music/tactical_music_nombat2/ambient/AlbumArt_{B5020207-474E-4720-69A9-C42E26A78900}_Small.jpg
TimelyMusic: DecideTrack rolled: sound/timely_music/tactical_music_nombat2/ambient/AlbumArt_{B5020207-474E-4720-69A9-C42E26A78900}_Small.jpg for theme tactical_music_nombat2 of total 1
TimelyMusic: Notification was: AlbumArt_{B5020207-474E-4720-69A9-C42E26A78900}_Small.jpg [tactical_music_nombat2/Clear/0]
TimelyMusic: DecideTrack said: sound/timely_music/tactical_music_nombat2/ambient/AlbumArt_{B5020207-474E-4720-69A9-C42E26A78900}_Small.jpg
TimelyMusic: file was different: sound/timely_music/tactical_music_nombat2/ambient/AlbumArt_{B5020207-474E-4720-69A9-C42E26A78900}_Small.jpg and sound/timely_music/tactical_music_nombat2/ambient/Cavern Metal Gear Solid F1NG3RS Cover.mp3
TimelyMusic: Error loading sound! 41 BASS_ERROR_FILEFORM
EntranceJew  [author] 17 Jan, 2024 @ 2:31pm 
@Callsign_Ewok:
some software may auto-index and create files anywhere they find MP3s, windows 11 probably has something that does this; if you get a specific error i can look at it further but i'm not sure what the problem is