xXMADEXx Posted April 19, 2013 Posted April 19, 2013 For some reason, the table is returning, but the data inside is returning nil addEventHandler("onClientSoundStream",root, function(suc,length,streamN) if not suc then return end local meta = getSoundMetaTags(source) outputChatBox(meta.artist) end ) The Ultimate Lua Tutorial! | MTA PHP SDK
Castillo Posted April 19, 2013 Posted April 19, 2013 That script seems fine, maybe stream sounds don't have some meta tags. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Dealman Posted April 24, 2013 Posted April 24, 2013 Am using MetaTags for my streaming script, and it varies. Some streamed mp3s will have MetaTags and some won't. Some have edited their mp3 files to advertise their website through the MetaTags. I would also highly suggest you make a timer between 1.5 - 2 seconds before you try to fetch the MetaTags, this drastically increases the chance of successfully downloading the MetaTags - and thus does not return nil. This applies for sound length as well. It should not be necessary on local files. If I help you in a thread and you need further assistance, please don't PM me - use the thread you created instead. This way everyone on the forum can take advantage of it.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now