Four programming skills,
why are they so bad in BP
Do you know 5 bad programming in bp?
They are Cast To, Event Tick, Bind Event, Delay and Get All Actors Of Class.
- Cast To
- Event Tick
- Delay
- Get All Actors of Class
- Bind Event
Event tick fires every frame, which means it;s constantly calling your code.
If you have a lot of logic or caluclations happening inside event thick,
it can overwhelm your system and lead to frame rate drops.
if you have something here on the right side, if you have big code,
it's going to lead to FPS drops frames per second.
Let's say you have only one event tick in your blueprints.
You'r playing your game for one hour. That's 3600 seconds.
Event tick is taking 120 times per second.
And the result 3600 seconds times 120 frames per second.
That's equal to 432000 ticks in one hour.
So if you play this game for one hour, you're going to get 432000 ticks.
Now If this is one actor with one event.
Imagine if you have two, three, five or more events.
How much is going to be heavy on your system?
If you remember in the previous post we were talking about how bad the casting is.
Now imagine if you put that casting note with this event tick.
This requires a lot of memory waste.
You might say, but what should we use instead of thick?
We can use custom events.
'UE5' 카테고리의 다른 글
Five Skills You Must Avoid in Unreal Blueprints - Bind Event (0) | 2024.06.03 |
---|---|
Five Skills You Must Avoid in Unreal Blueprints - Delay, Get All Actors of Class (0) | 2024.06.02 |
Five Skills You Must Avoid in Unreal Blueprints - Cast To (0) | 2024.05.31 |
서버연동 GameMode & GameState (0) | 2024.05.27 |
서버 연동 프로젝트 KU - 콜백되는 서브 시스템 함수 만들기 (0) | 2024.05.24 |