RealDocs

UKismetMathLibrary::Multiply_ByteByte

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

Description

Multiplies two byte (uint8) values and returns the result as a byte. In Blueprints this is the 'Byte * Byte' node, used for compact 8-bit arithmetic such as flags, indices, or shader parameter packing.

Caveats & Gotchas

  • The result is silently truncated to uint8 (0–255) — if A * B exceeds 255 the high bits are discarded without any overflow indication. For example, 200 * 2 = 144, not 400. Check your value ranges before using byte multiplication for gameplay logic.
  • Blueprint's byte type maps to uint8; it cannot represent negative values. Use integer arithmetic if you need signed intermediate results.

Signature

static UE_INL_API uint8 Multiply_ByteByte(uint8 A, uint8 B);

Parameters

Name Type Description Default
A uint8 First byte operand (0–255).
B uint8 Second byte operand (0–255).

Return Type

uint8

Example

Scale a byte property by a small multiplier C++
uint8 BaseSpeed = 10;
uint8 Multiplier = 3;
uint8 FinalSpeed = UKismetMathLibrary::Multiply_ByteByte(BaseSpeed, Multiplier); // 30

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.