RealDocs

UKismetSystemLibrary::CreateCopyForUndoBuffer

function Engine Blueprint Since 4.0
#include "Kismet/KismetSystemLibrary.h"
Access: public Specifiers: staticUFUNCTIONBlueprintCallable

Description

Marks an object as modified for the editor's undo/redo transaction buffer before construction-script or utility-widget code changes it.

Caveats & Gotchas

  • Only meaningful inside the editor — it's a thin wrapper around Modify()/transaction recording and has no effect in a packaged game.
  • Must be called before you actually change the object's state; calling it after the fact won't retroactively capture the pre-change values.
  • Intended for editor utility Blueprints and construction scripts, not runtime gameplay logic.

Signature

static void CreateCopyForUndoBuffer(UObject* ObjectToModify)

Parameters

Name Type Description Default
ObjectToModify UObject* The object about to be modified that should be captured for undo/redo.

Return Type

void

Example

Record undo state before an editor utility edits an object C++
UKismetSystemLibrary::CreateCopyForUndoBuffer(TargetActor);
TargetActor->SetActorLabel(TEXT("Renamed"));

Version History

Introduced in: 4.0

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.