BlueprintPseudocode guide

Comments and dead code

Comment text from the graph is kept, so reviewers see what the author wrote next to the logic.

Comment boxes and node comments

A comment box is printed as // [text] right before the first node inside it that the execution reaches. A comment on a single node (the speech bubble) goes at the end of that node's line. A comment box around no written node, such as one around pure nodes, unreachable nodes or empty space, is listed at the end of its graph.

event OnHit(float Amount)
    // [Damage handling]
    Health = Health - Amount  // clamp later?

Disabled and unreachable nodes

Disabled nodes keep their place with a [disabled] prefix. Nodes set to Development Only, as Print String is by default, have [development only]: they run in the editor and development builds, never in Shipping. Nodes that no flow reaches can never run; they're listed at the end of their graph as comments.

A disabled node with one execution input and one output is skipped over: what follows it still runs. One with more, such as a Branch or a Sequence, passes nothing on, and its line says // nothing under it runs. A Development Only node does the same in a cooked build: // in a cooked build nothing under it runs. In 4.27, disabled nodes inside functions and macros may behave differently: the text follows UE5.

event BeginPlay()
    [disabled] PlayIntro()
    [development only] KismetSystemLibrary::PrintString("debug")

// Unreachable nodes in EventGraph (no flow reaches their exec input):
    // GameplayStatics::PlaySound2D(/Game/Audio/Ping.Ping)

// Comments over no written node in EventGraph:
    // [Old ping test]