当前位置:网站首页>UE4 reload system 1. basic principle of reload system
UE4 reload system 1. basic principle of reload system
2022-07-24 06:19:00 【It's really all right, duck】
Section 1 : The basic principle of the reload system
1, principle
The principle of character fashion change is to split the character bone model into multiple parts , Each part uses the same set of bones , The disassembled part finds the corresponding spatial position of the main bone according to the spatial position of the bone , Then synthesize the output. For example, there are multiple characters in a character mesh form , Like the head , The body , leg , The feet are all alone mesh, Share a bone , Share an animation blueprint .
2, technological process
We turn on ue4 Create an empty project
Then import epic Material package for , This is free of charge

Create a character blueprint ,mesh Set as the basic model , Then add spring arm and camera , Character position z The axis direction is set to -87.5,z The axis rotation value is 270

stay mesh Next, add a skeleton mesh , Add four masks , jacket , Pants and shoes
Then create a function InitSkeletalMesh( Initialize the skeleton mesh body ), This function is used to initialize bones , Let each bone share an animation blueprint , Because if a skeleton has an animation blueprint, it will be very troublesome . Drag out characters mesh, call Set Master Pose Component( Set the main attitude component ) Node to make these four sub bones share an animation blueprint , The goal is to share four bones , The main skeleton is a character model

Then call this function from the constructor

Let's add models for these four skeleton mesh bodies

Remember to adjust the position and rotation of the model to 0
Now we can't see that we use Set Master Pose Component( Set the main attitude component ) What's the use of nodes , This is because we haven't used animation blueprints yet
Let's go to the input in the project settings to add an axis input , Name it MoveForward, The key values are w and s, Be careful s Of scale Set to -1

Then set the blueprint moving forward and backward in the character blueprint

Then we create an animation blueprint , Create a mixed space 1D, In mixed space 1D Inside, the horizontal coordinates are named Speed, add to idle Animation ,walk Animation ,run Animation

Add a state machine to the animation blueprint
Call the hybrid space created above in the state machine 1D, Go in and speed Promoted to variable , Then go to the chart to set it speed


Then we use this animation blueprint in the character blueprint we create , I found the clothes were normal , Follow the character changes , Let's copy this character blueprint , We broke the constructor in this new character blueprint InitSkeletalMesh Function call

Then I went back to the viewport and found that the clothes didn't change with the characters

Then we try the two character blueprints in the map scene , The effect is more obvious
Sum up , We can find out set Master Pose Component The function of the node is to make the four child bones share an animation blueprint , Then this is the basic principle of changing clothes .
Just learning ue4 The new , Please correct the mistakes .
The next section links :ue4 Replace the system 2. Scene capture of the reload system _ Grey pigskin blog -CSDN Blog _ue4 Replace the system
边栏推荐
猜你喜欢
随机推荐
快速简单搭建FTP服务器,并内网穿透实现公网访问【无需公网IP】
IP作业(2)RIP
什么是单调栈
First knowledge of graphics
Find the ArrayList < double > with the most occurrences in ArrayList < ArrayList < double >
Dameng database_ Small matters needing attention during use
Leetcode剑指offer JZ9 双栈实现队列
UE4 random generation of items
leetcode剑指offer JZ25 合并两个排序的链表
HoloLens 2开发:使用MRTK并在Unity中模拟手势输入
IP job (1)
leetcode剑指offer JZ42 连续子数组的最大和
Hololens 2 development 101: create the first hololens 2 Application
Using keras and LSTM to realize time series prediction of long-term trend memory -lstnet
Flink restart policy
Openpose Unity 插件部署教程
Ia note 1
unity最新版本的Text(TMP)UI文本怎么显示中文
Map the intranet to the public network [no public IP required]
记一次高校学生账户密码的获取,从无到有









