question

Gordon Graber avatar image
Gordon Graber asked

SDK Baloons WebGL size by 8MB?

Early in our Unity WebGL project develpemnet, prior to adding the PlayFab SDK and everything needed to get it running, our prototype WebGL build was 4MB in size.

After adding PlayFab, the build became 12MB. That seems kind of large - Is that normal for the SDK?

While that is not a lot relative to some of our prospective players internet speed/bandwidth limits, getting rid of extra weight is important.

Is there anyway to pare down the build file size with respect to the SDK, like if there are parts of the SDK that we are not using or something?

Thanks for your insights!

unity3dsdksfeedback
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Rick Chen avatar image
Rick Chen answered

It is not normal that the PlayFab SDK increase your build size by 8MB. Please follow this instruction: https://docs.unity3d.com/Manual/ReducingFilesize.html to check the size of each category. According to my test, the PlayFab SDK only takes 1.5MB in the Unity WebGL build.

3 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Gordon Graber avatar image Gordon Graber commented ·

Hey thanks! - yes I've started going through the log, and actually I've noticed the PlayFab demo samples use quite a bit. I thought I removed those from the scene, but I guess I Have them in there somewhere yet.

There is a 'gamedemo-styles.png' uses 4MB alone. Those samples would explain why the initial size increased so much first imported PlayFab - I guess I built the demo login screens.

0 Likes 0 ·
Rick Chen avatar image Rick Chen ♦ Gordon Graber commented ·

Yes, you could remove those file that you don’t use in order to reduce the size of the build. Please let me know if you have any other questions.

0 Likes 0 ·
Gordon Graber avatar image Gordon Graber Rick Chen ♦ commented ·

Yes, I removed the demos and related files, and also the Google and Facebook login classes because we're not using them, and it has brought the size down considerably.

Thanks!

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.