Unity引擎在其2017.3版本中引入了C# Job System、Burst Compiler以及Entity Component System,使得开发者能够利用CPU的多核硬件并行处理游戏逻辑,大大提升了游戏效率。Nordeus Demo是Unite Austin会议上展示的通过利用上述技术实现了PC平台上数以万计角色同屏的效果。
有一个问题是Unity本身以及DOTS相关package都更新太快了,很多读者想要运行起来这个demo难免遇到很多问题,这篇文章就记录一下我的一些解决方法。
下载源码
demo url:https://github.com/Unity-Technologies/UniteAustinTechnicalPresentation
下载编辑器
相关版本的editor下载:
the preview build posted by will be able to run the sample projects. If you have Unity Hub, make sure you delete the existing b12 and link the preview b12 version!
也就是说必须使用下面这个preview版本才能运行,下载链接https://beta.unity3d.com/download/ed1bf90b40e6/public_download.html
修改配置
修改manifest.json文件如下:
{
"dependencies": {
"com.unity.entities": "0.0.12-preview.2"
}
}
解决运行报错
运行报错 loadExpection:去相应位置(cach)添加try catch语句