What is 'No mapping for .ogg'? (SOLVED)

#1

I can build and debug my game without any problem, but when I tried to create bundle for any platform, with Editor 2 or BOB.jar, there is an error as following…


I checked game.project file, did not found any configuration about this. Could anyone help me on this problem?

0 Likes

#2

Are you using a custom appmanifest?

0 Likes

#3

No, I did not use any app manifest or plist file

0 Likes

#4

Could you paste the text of your game.project file here?

0 Likes

#5

Do you have any .ogg files in your project? If so, where? I took a look at the code and the error is generated when the build pipeline tries to make a lookup of compiled file extension (ie *.collectionc, *.scriptc etc) and doesn’t find a mapping of it. Could it be that a .ogg file has ended up inside the build folder somehow?

1 Like

#6

@Pkeod Here is my game.project file, it is very simple…

[project]
title = Mahjong
version = 0.1
dependencies = https://github.com/britzl/defold-clipboard/archive/master.zip,https://www.github.com/britzl/defold-luasocket/archive/master.zip,https://github.com/britzl/defnet/archive/master.zip

[bootstrap]
main_collection = /game/main/main.collectionc

[input]
game_binding = /input/game.input_bindingc
use_accelerometer = 0

[display]
width = 1136
height = 852

[physics]
scale = 0.02

[script]
shared_state = 1

[ios]
bundle_identifier = com.xsjplm.plm

[android]
package = com.xsjplm.plm

[osx]
bundle_identifier = com.xsjplm.plm

[profiler]
track_cpu = 1

0 Likes

#7

@britzl Yes, I have a background music file lobby_bgm.ogg in my project. It can be played correctly when I run or debug my game with Editor 2, but once I tried to bundle the game for any platform, this error message occurs and the bundle process failed.

0 Likes

#8

If you replace it with any other ogg does bundling work?

0 Likes

#9

My bad… I added this sound component by “Add component file” directly. After added it with “Add component->Sound”, the bundle process works smoothly. Thanks for the kindly help.

2 Likes

#10

I resolved this problem same way.

Is It a bug or documented feature?

0 Likes

HTML5 Build error. No mapping for .ogg
#11

It sounds like a bug.

Maybe related to this bug? https://github.com/defold/editor2-issues/issues/2115

0 Likes

#12

Just had this issue as well, with the same resolution. Not a showstopper but it did mean having to create ~20 sound components that weren’t really necessary.

0 Likes

#13

I totally understand. I’m thinking that it could be solved using an editor script that creates the in-between sound component. But the real fix is obviously in the editor itself. I’ll put it on our list of things to investigate It should be quite a quick fix.

1 Like

#14

Same problem)
Changing to with Add component->Sound helped.

0 Likes

#15

Reported here: https://github.com/defold/defold/issues/4959

1 Like