在运行时将AssetBundle(DLC)数据加载到Android手机[UNITY] [英] AssetBundle (DLC) data load to Android phone at runtime [UNITY]

查看:372
本文介绍了在运行时将AssetBundle(DLC)数据加载到Android手机[UNITY]的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Unity的资源浏览器.我想减少比赛量.因此,我应该制作资产捆绑包(DLC),当我单击手机中的下载按钮时,数据将永久下载并加载到手机中,然后该用户可以离线播放后立即下载.我在资源浏览器中构建了数据.我该如何加载?

I'm using Asset Browser of Unity. I want to reduce my game. So I should make Asset Bundle(DLC) and when i click download button in phone, datas will download and load to phone as permanantly, it will download at once, after that user can play as offline. I builded my data in Asset Browser. how can i load it?

推荐答案

首先,您需要使用资产捆绑浏览器构建资产捆绑,并将其放入可公开访问的服务器中.您需要在游戏中使用UnityWebRequest从服务器下载资产捆绑包.

First, you need to build the asset bundles (with Asset bundle browser) and put them in a server that is publicly accesible. You need to use UnityWebRequest in your game to download your assetbundle from the server.

https://docs.unity3d.com/Manual/UnityWebRequest-DownloadingAssetBundle.html

或者您可以使用Unity资产捆绑管理器 (看起来是Unity从资产商店中将其删除的)

Or you can use Unity Asset Bundle Manager ( Looks like Unity removed it from the asset store)

但是,我发现了这个很棒的工具,实际上我也在使用它,它做的更好.只需阅读自述文件,它就非常简单.您只需设置捆绑软件的URL,然后通过指定捆绑软件的名称来下载捆绑软件.

However, I have found this awesome tool, that I am actually using too, and it does a way better job. Just read the README, it is pretty straightforward. You just have to set the URL of your bundles, and then download bundles by specifying their name.

https://github.com/SadPandaStudios/AssetBundleManager

这篇关于在运行时将AssetBundle(DLC)数据加载到Android手机[UNITY]的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆