Posted March 13, 20178 yr public static SoundEvent SOUND_LEVELUP; // Called from main class during FMLPreInitializationEvent public static void registerSounds() { SOUND_LEVELUP = registerSound(new ResourceLocation(ModInfo.ID, "levelup")); // etc. } private static SoundEvent registerSound(ResourceLocation location) { final SoundEvent sound = new SoundEvent(location).setRegistryName(location); return GameRegistry.register(sound); } During the loading process just before the SoundSystem starts, I receive an error message like the following for every single sound listed in my sounds.json file: File minecraft:sounds/special/levelup.ogg does not exist, cannot add it to event dynamicswordskills:levelup Note how it appears to be searching for the file with the 'minecraft' domain rather than my mod id, even though it shows the correct resource location just after that. I'm using Forge 1.9.4-12.17.0.1976. What am I doing wrong? http://i.imgur.com/NdrFdld.png[/img]
March 13, 20178 yr The sound events in your sounds.json file have their resource domain set automatically from the file's resource domain, but the individual sound files used by the sound events don't, they need to be specified manually. Replace special/levelup with dynamicswordskills:special/levelup in your sounds.json file. Edited March 14, 20178 yr by Choonster Fixed sound file path Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.
March 14, 20178 yr Author Thanks! I do find it a little odd that the modid needs to be specified in the sounds.json file now - are there any cases where one would want to specify something else? Because you can always fetch sounds from Minecraft or other mods using the registry. http://i.imgur.com/NdrFdld.png[/img]
March 14, 20178 yr Just now, coolAlias said: Thanks! I do find it a little odd that the modid needs to be specified in the sounds.json file now - are there any cases where one would want to specify something else? Because you can always fetch sounds from Minecraft or other mods using the registry. It's possible that you'd want to create a sound event that consists of a combination of vanilla files not present in any existing sound event. For example, a sound event consisting of minecraft:block/chorus_flower/grow1, minecraft:dig/cloth1 and youmod:foo/bar. There's no existing sound event with this combination of sound files. Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.
March 14, 20178 yr Author Huh, never thought of doing something like that. Nice. Cheers! http://i.imgur.com/NdrFdld.png[/img]
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.