Posted March 11, 20169 yr I am trying to play a custom sound when my block gets powered but I get the same error everytime Unable to play unknown soundEvent: spoopy:creepysound i have a json file in my src/main/resources/assets/spoopy and the sound file inside src/main/resources/assets/spoopy/sounds the json file looks like this [embed=425,349]{ "creepysound": {"category": "general","sounds": [{"name": "creepysound","stream": true}]} }[/embed]
March 11, 20169 yr For starters, please edit your OP to give it a version label (just in case the rules have changed between MC versions). My own custom sound uses "master" rather than "general", but I don't know the difference. IIRC, "stream":true is for long-playing sounds like music discs. They might need special handling. If you're playing just a few seconds of sound effect, change this to false. Your sound file must be in ogg format. The debugger is a powerful and necessary tool in any IDE, so learn how to use it. You'll be able to tell us more and get better help here if you investigate your runtime problems in the debugger before posting.
March 12, 20169 yr Then it's time to worry about things like capitalization in the filename. If you can't find some mismatch, then start posting more of your log (not console) and code. Show us the whole error message in context. Show us the whole method that calls the playSoundEffect method. Running in the debugger would probably also be informative. My one experience with sounds is in mc 1.8, so it's possible that something must be different in 1.7.10. The debugger is a powerful and necessary tool in any IDE, so learn how to use it. You'll be able to tell us more and get better help here if you investigate your runtime problems in the debugger before posting.
March 12, 20169 yr Author Fixed it the problem was that my workspace got corrupted or something so minecraft wasnt launching correctly
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.