当前位置:网站首页>[ue5] blueprint making simple mine tutorial
[ue5] blueprint making simple mine tutorial
2022-07-02 10:00:00 【Qiao'an fish】
This is a small effect that I researched myself , But it can't cope with complex situations .
The effect of Mines —— The player presses the key to place a mine ,AI Explosion after encountering .
Split the whole process :
1. The player presses the key to place the mine model .
2.AI After encountering mines ,AI disappear .
3. Mines play explosion effects , Disappearance of Mines .
One 、 Press the key to place mines
1. Make mine blueprints
Create a Actor The blueprint , Add any MESH Components as models .
Add trigger , You can choose any shape .
( When touching this trigger , Play the landmine incident )
The size of the trigger is larger than the model , Otherwise, when the model collides ,AI Unable to trigger .
2. Press the key to place mines
Open the player character blueprint , Right click input E, stay “ Keyboard events ” Add “E” event .
Press E Key will trigger this event .
Drag and drop E The event Pressed Pin , establish “ Generate Actor” function .


It's generating Actor Of class Choose the mine blueprint we created 
The name of the function will show the class we selected .
Next, we need to give the location of this function , It can be generated at the current player position .
Create get Actor The position function , And generate Actor Of Spawn Transform Pin to pin , A vector transformation will automatically appear in the middle .
After placement , You will find the camera bounced off , I can't see the players .
This is because mines collide , Play the character away .
Select from the mine blueprint mesh Components , In the details panel, change the collision preset to NoCollision, The collision of mines is closed .
Play again , This time the mine didn't bounce the player away .
Two 、AI Hit a mine explosion
1. establish AI Communicate with mines
We can use AI The trigger of the mine overlaps with the trigger of the mine to create an explosion event , however AI Will be deleted after triggering , In order to ensure that both disappear at the same time , Still need to be in AI Establish blueprint communication with mines , To inform the mine explosion .
Right click > The blueprint > Blueprint interface , Establish blueprint communication .
The name IF_ The explosion .
Open blueprint communication , Modify the function name as explosion.
such , Blueprint communication is established .
2.AI The explosion
open AI Character blueprint , Select capsule components , Add the event when components begin to overlap in the details panel .
Execute pins when dragging components to start overlapping , Create what we just set Explosion function ,other actor Connect with the goal .
In this way, the mine is notified to start the explosion .
Similar to the method of generating mines , stay AI The current position generates an explosion effect ,Class Choose your own explosion Blueprint is enough .
And then to delete AI Model , establish Delete Actor function .
AI The explosion effect of is finished :
3、 ... and 、 Mine explosion
Just make the mine model disappear .
Open mine blueprint , We are going to call the explosion . Input explosion, Note that we have to choose events Explosion.
Destroy directly Actor That's it .


The effect is achieved !
I said before. , This is just a simple effect , If there are multiple colliders , Will trigger an explosion .
So you also need to filter triggers .
边栏推荐
猜你喜欢

渗透测试的介绍和防范

三相逆变器离网控制——PR控制
![[Yu Yue education] University Physics (Electromagnetics) reference materials of Taizhou College of science and technology, Nanjing University of Technology](/img/a9/ffd5d8000fc811f958622901bf408d.png)
[Yu Yue education] University Physics (Electromagnetics) reference materials of Taizhou College of science and technology, Nanjing University of Technology

JDBC review

阿里云ack介绍

2837xd code generation - stateflow (4)

2837xd code generation - stateflow (1)

【UE5】动画重定向:如何将幻塔人物导入进游戏玩耍

Alibaba cloud SLS log service

FragmentTabHost实现房贷计算器界面
随机推荐
A model can do two things: image annotation and image reading Q & A. VQA accuracy is close to human level | demo can be played
Junit5 支持suite的方法
XA Transaction SQL Statements
职业规划和发展
Read Day6 30 minutes before going to bed every day_ Day6_ Date_ Calendar_ LocalDate_ TimeStamp_ LocalTime
FragmentTabHost实现房贷计算器界面
BugkuCTF-web21(详细解题思路及步骤)
ESLint 报错
图像识别-数据标注
About the college entrance examination
2837xd 代码生成——StateFlow(4)
2837xd 代碼生成——StateFlow(4)
2837xd code generation - stateflow (2)
In SQL injection, why must the ID of union joint query be equal to 0
【UE5】AI随机漫游蓝图两种实现方法(角色蓝图、行为树)
BugkuCTF-web24(解题思路及步骤)
College Students' CET-4 and CET-6 composition template (self created version, successfully crossed CET-6)
Bugkuctf-web16 (backup is a good habit)
Minimum number of C language
Data insertion in C language