Tag: Unreal

  • How to Attach an Actor to Another Actor Using a Socket in Unreal Engine

    How to Attach an Actor to Another Actor Using a Socket in Unreal Engine

    It’s worth noting that the ‘Attach Actor to Actor’ node might not behave as expected when trying to attach to a socket on a skeletal mesh. This can be a bit misleading because this node attempts to attach to a socket on the Root Component. However, in the case of a character, the root component…

  • Optimize Debugging in Unreal Engine with Cheat Codes

    Optimize Debugging in Unreal Engine with Cheat Codes

    Whether it’s for QA testing or during playtesting, maintaining control over your game is essential to efficiently tackle bugs, obstacles, and repetitive tasks. While developers commonly bind inputs to cheat codes – like associating F5 with invincibility – this approach has its limitations: A more effective solution is employing console commands. Triggered by the backtick…

  • Creating a Loading Screen for heavy vevels

    Creating a Loading Screen for heavy vevels

    Summary If you encounter issues with assets loading too slowly and your player’s pawn being instantiated before everything is ready, creating a loading screen can be a practical solution. Not only does it provide a better user experience by showing progress, but it also ensures your pawn doesn’t spawn prematurely, preventing potential glitches such as…

  • FPrintf in Unreal Engine with TEXT, FText, and FString

    Introduction TEXT is a macro for creating wide-character string literals, FString is a C++ string-like type for general text handling (e.g. logs), and FText is a specialized type for managing string translations and handling localized text for, among other, UI elements in Unreal Engine. Not that FText objects are immutable (they cannot be modified), ensuring…

  • How to calculate an Actor Oriented Bounding Box (OBB) With Unreal Engine

    How to calculate an Actor Oriented Bounding Box (OBB) With Unreal Engine

    To obtain an Oriented Bounding Box (OBB) for an object, we first need to retrieve the local Axis Aligned Bounding Box (AABB) and then construct our OBB using a center and an extent vector transformed with the Actor’s world Transform. While the AABB consists of a single Extent vector representing the magnitude on each axis…

  • How to solve Invisible / very small mesh when importing a skeleton from Blender

    How to solve Invisible / very small mesh when importing a skeleton from Blender

    Symptoms If you model and rig your character in Blender and import it into Unreal Engine via FBX, you may notice that the mesh appears invisible or very small. In some cases, the mesh may initially appear fine, but disappear after applying an animation blueprint. Cause The issue is caused by the FFbxImporter in Unreal…

  • How to Spawn an AI Controller Pawn in Unreal Engine

    Use “Spawn AI From Class” to Spawn an AI Character If you want to spawn a Non-Player Character (NPC), you should use the “Spawn AI From Class” node in Unreal Engine, rather than “Spawn Actor for Class”. This is because an AI character is actually composed of two actors: the pawn and the controller (which…

  • Configure UTickableWorldSubsystem

    This subsystem lives along with the world and is initialized and destroyed at the same time. It’s a subclass of UWorldSubsystem, but with a Tick function. This class is particularly useful for creating a “Game Master” system to manage game events, like spawning enemy waves or handling level transitions. To use UTickableWorldSubsystem, you need to…

  • How to create a blueprint node with multiple exec pins.

    To create a blueprint node with multiple exec pins in Unreal Engine, you can use the ExpandEnumAsExecs meta tag in the UFUNCTION macro to specify the number of outputs The ExpandEnumAsExecs meta tag is a special meta tag that can be used in conjunction with an enum parameter in a blueprint function to automatically generate…

  • How to write a Dialog system with Unreal 5.1

    Create a new Widget Blueprint To display a Dialog Box, we first need to create a Widget to display on the screen that contains a text box. In Unreal Engine, you can create a new Widget Blueprint by right-clicking in the Content Browser, selecting “User Interface,” and then “Widget Blueprint.” Give your new Widget Blueprint…