Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(2 edits)

This is not a game development question.

Anyway, going about it in Unity is kinda silly. Unity's a game engine - you're talking about taking specific media files and extracting the audio from them (unless you're meaning to do something like take audio from a Youtube video and stream it as audio in a game, which isn't practical unless you like audio lag). I'm going to spitball here since I don't have the source code for something like file2hd, and I don't want to explicitly give instructions for pirating audio just in case my work manager ever finds this account, but you'd hypothetically want to find the source file (or a m3u8 file pointing at the media and get a stream from that file) that Youtube loads. Youtube tries to hide this, and it doesn't help that the different qualities are probably going to put you at a different source url, but if you can't find a pattern there's several websites that will just let you download the video. From there, you're just taking a video file and converting it, which something like https://stackoverflow.com/questions/44981454/c-sharp-extract-mp3-file-from-mp4-f... can help you with.