RealDocs

UKismetMathLibrary::GetBoxSize

function Engine Blueprint Since unknown
#include "Kismet/KismetMathLibrary.h"
Access: public Specifiers: staticUFUNCTIONBlueprintPure

Description

Returns the full width, depth, and height of an axis-aligned box as a vector (Max - Min on each axis).

Caveats & Gotchas

  • Exposed to Blueprint as "Get Size (Box)" via a DisplayName meta tag rather than the raw function name.
  • This returns the full size, not the half-extent used by functions like IsPointInBox — dividing by 2 gives the extent if you need it.

Signature

static FVector GetBoxSize(const FBox& InBox)

Parameters

Name Type Description Default
InBox const FBox& The box to measure.

Return Type

FVector

Example

Scale a decal to match a trigger's footprint C++
FBox Bounds = TriggerBox->Bounds.GetBox();
FVector Size = UKismetMathLibrary::GetBoxSize(Bounds);
DecalComponent->DecalSize = FVector(Size.X * 0.5f, Size.Y * 0.5f, Size.Z * 0.5f);

Tags

Version History

Introduced in: unknown

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.