当前位置: 首页 > news >正文

学习 UE5 的一些前置操作总结

随着 Unity, Godot 这些引擎都玩抽象,主动捅自己一刀后,UE5 的风头不可谓不盛,本着多学一点免得失业的思路方针,咱也研究了一下 UE5 引擎,然后发现想要开始使用 UE5 ,包含了很多前置操作,这里总结出来,方便后来人。

1,修改 Epic 启动器的缓存目录,如果不改的话,默认都丢 C 盘,撑爆你的 C 盘。

这个简单,打开设置,拉倒底下就是了。

2,修改引擎的默认缓存目录。

首先是把已有的缓存删掉,在这个目录,删掉里面的所有文件即可。

C:\Users\xx(这里是你的用户名)\AppData\Local\UnrealEngine\Common\DerivedDataCache

打开引擎2进制文件的所在目录,然后继续进入,并打开文件

引擎版本\Engine\Config\BaseEngine.ini

把其中的 ENGINEVERSIONAGNOSTICUSERDIR%DerivedDataCache 替换为 

GAMEDIR%DerivedDataCache

把缓存目录改为本地,其实所有的 ENGINEVERSIONAGNOSTICUSERDIR 都可以改到 GAMEDIR

3,最好是创建一个 C++ 项目,可以方便我们的后续修改和扩展,当然你创建纯蓝图项目也无所谓。

C++ 项目可以通过工具底下的选项刷新 VS 项目,也可以用来打开 VS 项目。

如果你创建的是 C++ 项目,则可以为引擎安装一个整合工具插件。

4,我们打开项目后,如果显卡不是太好的话,屏幕上可能会显示 Video memory has been exhausted,这是因为 UE5 默认使用的图形 API 是 DX12。

我门先打开项目设置

搜索 default RHI ,并修改为 DX11,需要你重启编辑器,并重新编译着色器(挺久)。

重启回来后,就不会再报那个错误了。

5,打开我们的 VS 项目,随便打开一个文件,它应该会弹出一个工具窗口,如图:

刷新总配置,应该能看到命名约定检查器和 HLSL 支持有警告,按提示需要产生2个配置文件。

首先生成目录不用换,直接选择在项目的根目录就可以。

shadertoolsconfig.json 里面用默认就可以。

.editorconfig 里粘贴以下代码,检查应该就都可以通过了,就是全绿状态了。

[*.{cpp,h}]# Naming convention rules (note: currently need to be ordered from more to less specific)cpp_naming_rule.aactor_prefixed.symbols                    = aactor_class
cpp_naming_rule.aactor_prefixed.style                      = aactor_stylecpp_naming_rule.swidget_prefixed.symbols                   = swidget_class
cpp_naming_rule.swidget_prefixed.style                     = swidget_stylecpp_naming_rule.uobject_prefixed.symbols                   = uobject_class
cpp_naming_rule.uobject_prefixed.style                     = uobject_stylecpp_naming_rule.booleans_prefixed.symbols                 = boolean_vars
cpp_naming_rule.booleans_prefixed.style                   = boolean_stylecpp_naming_rule.structs_prefixed.symbols                   = structs
cpp_naming_rule.structs_prefixed.style                     = unreal_engine_structscpp_naming_rule.enums_prefixed.symbols                     = enums
cpp_naming_rule.enums_prefixed.style                       = unreal_engine_enumscpp_naming_rule.templates_prefixed.symbols                 = templates
cpp_naming_rule.templates_prefixed.style                   = unreal_engine_templatescpp_naming_rule.general_names.symbols                      = all_symbols
cpp_naming_rule.general_names.style                        = unreal_engine_default# Naming convention symbols         cpp_naming_symbols.aactor_class.applicable_kinds           = class
cpp_naming_symbols.aactor_class.applicable_type            = AActorcpp_naming_symbols.swidget_class.applicable_kinds          = class
cpp_naming_symbols.swidget_class.applicable_type           = SWidgetcpp_naming_symbols.uobject_class.applicable_kinds          = class
cpp_naming_symbols.uobject_class.applicable_type           = UObjectcpp_naming_symbols.boolean_vars.applicable_kinds          = local,parameter,field
cpp_naming_symbols.boolean_vars.applicable_type           = boolcpp_naming_symbols.enums.applicable_kinds                  = enumcpp_naming_symbols.templates.applicable_kinds              = template_classcpp_naming_symbols.structs.applicable_kinds                = structcpp_naming_symbols.all_symbols.applicable_kinds            = *# Naming convention stylescpp_naming_style.unreal_engine_default.capitalization      = pascal_case
cpp_naming_style.unreal_engine_default.required_prefix     =
cpp_naming_style.unreal_engine_default.required_suffix     =
cpp_naming_style.unreal_engine_default.word_separator      =cpp_naming_style.unreal_engine_enums.capitalization        = pascal_case
cpp_naming_style.unreal_engine_enums.required_prefix       = E
cpp_naming_style.unreal_engine_enums.required_suffix       =
cpp_naming_style.unreal_engine_enums.word_separator        =cpp_naming_style.unreal_engine_templates.capitalization    = pascal_case
cpp_naming_style.unreal_engine_templates.required_prefix   = T
cpp_naming_style.unreal_engine_templates.required_suffix   =
cpp_naming_style.unreal_engine_templates.word_separator    =cpp_naming_style.unreal_engine_structs.capitalization      = pascal_case
cpp_naming_style.unreal_engine_structs.required_prefix     = F
cpp_naming_style.unreal_engine_structs.required_suffix     =
cpp_naming_style.unreal_engine_structs.word_separator      =cpp_naming_style.uobject_style.capitalization              = pascal_case
cpp_naming_style.uobject_style.required_prefix             = U
cpp_naming_style.uobject_style.required_suffix             =
cpp_naming_style.uobject_style.word_separator              =cpp_naming_style.aactor_style.capitalization               = pascal_case
cpp_naming_style.aactor_style.required_prefix              = A
cpp_naming_style.aactor_style.required_suffix              =
cpp_naming_style.aactor_style.word_separator               =cpp_naming_style.swidget_style.capitalization              = pascal_case
cpp_naming_style.swidget_style.required_prefix             = S
cpp_naming_style.swidget_style.required_suffix             =
cpp_naming_style.swidget_style.word_separator              =cpp_naming_style.boolean_style.capitalization              = pascal_case
cpp_naming_style.boolean_style.required_prefix             = b
cpp_naming_style.boolean_style.required_suffix             =
cpp_naming_style.boolean_style.word_separator              =

完成前面的一大串操作后,我们应该就可以开始正经的游戏开发了,UE5 的前摇动作是真滴长~

http://www.lryc.cn/news/464938.html

相关文章:

  • C#/.NET/.NET Core技术前沿周刊 | 第 10 期(2024年10.14-10.20)
  • Git 基本配置
  • 理工科考研想考计算机,湖南大学、重大、哈工大威海、山东大学,该如何选择?
  • 使用langchain和大模型API提取QA的实战教程
  • Java面试场景题(1)---如何使用redis记录上亿用户连续登陆天数
  • Element UI
  • ②PROFINET转ModbusTCP, EtherCAT/Ethernet/IP/Profinet/ModbusTCP协议互转工业串口网关
  • python+Mosh网课笔记04
  • 【微服务】全面构建微服务监控体系:确保系统稳定与性能优化的关键
  • Gin框架操作指南08:日志与安全
  • 鸿蒙系统 VS 安卓系统,谁将引领未来移动操作系统?
  • PyTorch 中 functional.py 文件介绍
  • SQL Injection | SQL 注入 —— 报错盲注
  • 网络通信与并发编程(四)操作系统、进程理论、开启进程的两种方式
  • Java--集合(三)之vectorlinkedlisthashset结构
  • upload-labs Pass-04
  • 如何修改jupyter notebook的工作目录
  • 23种设计模式具体实现方法
  • cisco网络安全技术第3章测试及考试
  • 数据结构练习题5(链表和栈)
  • 计算机网络408真题解析(湖科大教书匠)
  • uniapp+vue3+uview-plus修改默认样式
  • 数控机械制造工厂ERP适用范围有哪些
  • 华为配置 之 Console线路配置
  • 小米等手机彻底关闭快应用
  • 【每日一题】24.10.14 - 24.10.20
  • CMake与Qt4/Qt5的结合使用指南
  • TwinCAT3添加PLC轴,并建立PLC轴与NC轴的链接
  • Linux操作系统如何制作U盘启动盘
  • 如何防止SpringBoot中的jar反编译?解决相关报错及踩到的坑