UE4->Plugin 认识UE4插件 1

2024-06-16 02:48
文章标签 ue4 认识 插件 plugin

本文主要是介绍UE4->Plugin 认识UE4插件 1,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

原创文章,转载请注明出处。

本文带大家认识UE4的插件, Plugin

UE4 Engine中插件代码占很大一部分,可参考下图,里面的Editor, Developer, Runtime, Slate举例都是大家比较熟悉的几个
在这里插入图片描述
1>看下图的中Json,其实就是我们的.plugin文件

{"FileVersion": 3,	//文件版本"Version": 1,		//Plugin版本"VersionName": "1.0",	//版本名称"FriendlyName": "Taskp",	//插件名称"Description": "tianhuajian created",	//插件描述"Category": "Other",			//插件所属组"CreatedBy": "tianhuajian",		//插件创建者"CreatedByURL": "",				//创建者网站"DocsURL": "",					//插件的文档URL"MarketplaceURL": "",			//虚幻商城URL"SupportURL": "",				//技术支持URL"CanContainContent": true,		//是否可包含Content"IsBetaVersion": false,			//是否是测试版"IsExperimentalVersion": false,	//是否是实验性的版本, UE4插件中会有显示"Installed": false,				//是否安装的"Modules": [					//可包含多个模块{"Name": "TestPlg",		//重要:模块名称"Type": "Runtime",		//重要:模块的类型->下面再介绍"LoadingPhase": "Default"		//重要:加载阶段->下面再介绍}]
}

2>Modules->Type(类型)介绍
代码中搜索 EHostType, 转到定义, ModuleDescriptor.h,对应上面Type 的枚举其实就在这个文件中。在这里插入图片描述

/*** Environment that can load a module.*/
namespace EHostType
{enum Type{// Loads on all targets, except programs.Runtime,	//Runtime模式下会去加载// Loads on all targets, except programs and the editor running commandlets.RuntimeNoCommandlet,	//Runtime模式, 不包含命令// Loads on all targets, including supported programs.RuntimeAndProgram,		//Runtime模式, 小程序// Loads only in cooked games.CookedOnly,		//和Cook资源相关// Only loads in uncooked games.UncookedOnly, //只在没有cook过的程序中加载// Deprecated due to ambiguities. Only loads in editor and program targets, but loads in any editor mode (eg. -game, -server).// Use UncookedOnly for the same behavior (eg. for editor blueprint nodes needed in uncooked games), or DeveloperTool for modules// that can also be loaded in cooked games but should not be shipped (eg. debugging utilities).Developer,	//开发模式下加载,兼容老版本留下来的枚举// Loads on any targets where bBuildDeveloperTools is enabled.DeveloperTool,	//开发模式下加载 新的枚举// Loads only when the editor is starting up.Editor,		//Editor模块// Loads only when the editor is starting up, but not in commandlet mode.EditorNoCommandlet,	//Editor非命令行加载// Loads only on editor and program targetsEditorAndProgram,	//Editor小程序// Only loads on program targets.Program,	//独立程序// Loads on all targets except dedicated clients.ServerOnly,		//服务端模块// Loads on all targets except dedicated servers.ClientOnly,		//客户端模块// Loads in editor and client but not in commandlets.ClientOnlyNoCommandlet,		//客户端没有命令行的模块//~ NOTE: If you add a new value, make sure to update the ToString() method below!Max	//如果新加枚举的话 别忘了把这个Namespace中的tostring方法完善一下};

3>Modules->LoadingPhase(加载阶段)介绍
代码中搜索 ELoadingPhase, 转到定义, ModuleDescriptor.h,对应上面LoadingPhase 的枚举其实就在这个文件中。

namespace ELoadingPhase
{enum Type{/** As soon as possible - in other words, uplugin files are loadable from a pak file (as well as right after PlatformFile is set up in case pak files aren't used) Used for plugins needed to read files (compression formats, etc) */EarliestPossible,/** Loaded before the engine is fully initialized, immediately after the config system has been initialized.  Necessary only for very low-level hooks */PostConfigInit,/** The first screen to be rendered after system splash screen */PostSplashScreen,/** Loaded before coreUObject for setting up manual loading screens, used for our chunk patching system */PreEarlyLoadingScreen,/** Loaded before the engine is fully initialized for modules that need to hook into the loading screen before it triggers */PreLoadingScreen,/** Right before the default phase */PreDefault,/** Loaded at the default loading point during startup (during engine init, after game modules are loaded.) */Default,/** Right after the default phase */PostDefault,/** After the engine has been initialized */PostEngineInit,/** Do not automatically load this module */None,// NOTE: If you add a new value, make sure to update the ToString() method below!Max};

这篇关于UE4->Plugin 认识UE4插件 1的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/1065292

相关文章

Java对异常的认识与异常的处理小结

《Java对异常的认识与异常的处理小结》Java程序在运行时可能出现的错误或非正常情况称为异常,下面给大家介绍Java对异常的认识与异常的处理,本文给大家介绍的非常详细,对大家的学习或工作具有一定的参... 目录一、认识异常与异常类型。二、异常的处理三、总结 一、认识异常与异常类型。(1)简单定义-什么是

CnPlugin是PL/SQL Developer工具插件使用教程

《CnPlugin是PL/SQLDeveloper工具插件使用教程》:本文主要介绍CnPlugin是PL/SQLDeveloper工具插件使用教程,具有很好的参考价值,希望对大家有所帮助,如有错... 目录PL/SQL Developer工具插件使用安装拷贝文件配置总结PL/SQL Developer工具插

maven中的maven-antrun-plugin插件示例详解

《maven中的maven-antrun-plugin插件示例详解》maven-antrun-plugin是Maven生态中一个强大的工具,尤其适合需要复用Ant脚本或实现复杂构建逻辑的场景... 目录1. 核心功能2. 典型使用场景3. 配置示例4. 关键配置项5. 优缺点分析6. 最佳实践7. 常见问题

MyBatis分页插件PageHelper深度解析与实践指南

《MyBatis分页插件PageHelper深度解析与实践指南》在数据库操作中,分页查询是最常见的需求之一,传统的分页方式通常有两种内存分页和SQL分页,MyBatis作为优秀的ORM框架,本身并未提... 目录1. 为什么需要分页插件?2. PageHelper简介3. PageHelper集成与配置3.

Maven 插件配置分层架构深度解析

《Maven插件配置分层架构深度解析》:本文主要介绍Maven插件配置分层架构深度解析,本文给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友参考下吧... 目录Maven 插件配置分层架构深度解析引言:当构建逻辑遇上复杂配置第一章 Maven插件配置的三重境界1.1 插件配置的拓扑

Idea插件MybatisX失效的问题解决

《Idea插件MybatisX失效的问题解决》:本文主要介绍Idea插件MybatisX失效的问题解决,详细的介绍了4种问题的解决方法,具有一定的参考价值,感兴趣的可以了解一下... 目录一、重启idea或者卸载重装MyBATis插件(无需多言)二、检查.XML文件与.Java(该文件后缀Idea可能会隐藏

解决Maven项目报错:failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.13.0的问题

《解决Maven项目报错:failedtoexecutegoalorg.apache.maven.plugins:maven-compiler-plugin:3.13.0的问题》这篇文章主要介... 目录Maven项目报错:failed to execute goal org.apache.maven.pl

Maven pom.xml文件中build,plugin标签的使用小结

《Mavenpom.xml文件中build,plugin标签的使用小结》本文主要介绍了Mavenpom.xml文件中build,plugin标签的使用小结,文中通过示例代码介绍的非常详细,对大家的学... 目录<build> 标签Plugins插件<build> 标签<build> 标签是 pom.XML

IDEA常用插件之代码扫描SonarLint详解

《IDEA常用插件之代码扫描SonarLint详解》SonarLint是一款用于代码扫描的插件,可以帮助查找隐藏的bug,下载并安装插件后,右键点击项目并选择“Analyze”、“Analyzewit... 目录SonajavascriptrLint 查找隐藏的bug下载安装插件扫描代码查看结果总结Sona

Java架构师知识体认识

源码分析 常用设计模式 Proxy代理模式Factory工厂模式Singleton单例模式Delegate委派模式Strategy策略模式Prototype原型模式Template模板模式 Spring5 beans 接口实例化代理Bean操作 Context Ioc容器设计原理及高级特性Aop设计原理Factorybean与Beanfactory Transaction 声明式事物