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?


#2

Are you using a custom appmanifest?


#3

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


#4

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


#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?


#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


#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.


#8

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


#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.