Can defold.resourcepack.zip be used cross-platform? (DEF-3830)(SOLVED)

#1

In order to use the live update feature of defold, I exclude some collection and build my win32、mac、android、ios bundle, but I found that the defold.resourcepack_xxxxxxx.zip of these four platform not identical. Can I build defold.resourcepack_xxxxx.zip once and use in these four platforms?

0 Likes

#2

The reason you can’t (I think) is because texture formats are different for each platform. Each format is specifically made to be useful for the hardware of the target platform.

1 Like

#3

OK,thanks

0 Likes

#4

Correct! And also Lua bytecode can be different on each platform (for example HTML5 cannot use luajit but uses vanilla Lua).

3 Likes

#5

Since the defold.resourcepack_xxxxx.zip cannot be used cross-platform, I want defold generate different name for different platforms, for example, defold.resourcepack.win32.xxxx.zip for win32 bundle, defold.resourcepack.mac.xxxx.zip for mac bundle,defold.resourcepack.android.xxxx.zip for android bundle, and defold.resourcepack.ios.xxxx.zip for ios bundle

1 Like

#6

Are you bundling from the editor? If you want to batch bundle for all target platforms it would be better to script this using bob and deal with the naming of the resource pack in the script.

But besides that it makes sense to give the file a platform specific name.

0 Likes

#7

@Johan_Beck-Noren this would be a quickfix right?

0 Likes

#8

I am bundling from the editor.

0 Likes

#9

Ok, but do you bundle multiple times in a row, once per platform? Otherwise it’s not that big of a deal to rename the file yourself. If you do bundle for multiple platforms at once this script would help you speed up that process: Build and bundle for multiple platforms from the command line

0 Likes

#10

Right now, I am debugging my project in every platforms, so I will do bundle for every platforms. After several times of bundling, there are many zip in the live update folder:


I can’t distinguish what platform they belongs to.

0 Likes

#11

Yes this should be a quick-fix! Added ticket DEF-3830 for this.

2 Likes

#12

Solved in1.2.150

1 Like