Jump to content

Need Help with Custom Sounds [1.7.10] [Solved]


KristinnVikarJ

Recommended Posts

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]

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.