Hugo & non-resource filed MP3s

This is a discussion / support forum for the Hugo programming language by Kent Tessman. Hugo is a powerful programming language for making text games / interactive fiction with multimedia support.

Hugo download links: https://www.generalcoffee.com/hugo
Roody Yogurt's Hugo Blog: https://notdeadhugo.blogspot.com
The Hugor interpreter by RealNC: http://ifwiki.org/index.php/Hugor

Moderators: Ice Cream Jonsey, joltcountry

User avatar
Ice Cream Jonsey
Posts: 28923
Joined: Sat Apr 27, 2002 2:44 pm
Location: Colorado
Contact:

Hugo & non-resource filed MP3s

Post by Ice Cream Jonsey »

Anyone know if Hugo could play an MP3 that was not included in a standing resource file? I wonder if it's possible to do a Jukebox of sorts within the language. Certainly, you could if you squashed your MP3s in a file during compile, but that'd lead to limited juking. And we wouldn't want that. (I figure this is probably a question for Kent, but maybe something a bunch of other Hugoers would be interested in, so I just thought to post it here.)
the dark and gritty...Ice Cream Jonsey!

User avatar
Ice Cream Jonsey
Posts: 28923
Joined: Sat Apr 27, 2002 2:44 pm
Location: Colorado
Contact:

Post by Ice Cream Jonsey »

I should mention that Kent told me that such a thing is possible. You just have to provide the directory name for the MP3 and then you can play it as you would any compiled and resourced MP3.

So, in theory, to write a Hugo Jukebox player you use a batch file / program / whatever that provides, essentially, a dir *.* > dirlist.txt command. You then parse through that file (which presumably Hugo could do, as it has to read save files, natch). You then write code to play through the list.

(As it has taken me three months to remove negative numbers from a 50-line Hammurabi port, anyone wishing to write such a jukebox app immediately has my full support.)
the dark and gritty...Ice Cream Jonsey!

Lex
Posts: 976
Joined: Sat Apr 27, 2002 4:03 pm
Location: Scotland, Bonnie
Contact:

Post by Lex »

I'd love to pump it up & give something back to the community, but I'm totally pooped due to a Learn-To-Study-The-Uni-Way Summer-school. Make Cadre do it. Good practise for him with a real man's language.
WHOOA!

Post Reply