Unreal Engine Integration
Add Compuon to your Unreal Engine project. Native wrappers link the Compuon core into your game binary.
Installation
Unpack the SDK package from your dashboard into your game module's ThirdParty directory. The zip holds the static library at its root, the headers, and three text files:
Source/YourGame/ThirdParty/compuon-core/
compuon.lib // static library (libcompuon.a in the linux-x64 package)
include/
compuon/
compuon.h
platform.h
types.h
protocol/
sync_handler.h // SyncHandler: your link to the integrity server
messages.h
INTEGRATION_TIPS.md // read this first
README.md
TOOLCHAIN.txt // compiler, commit, seed, gated or notThe Unreal module — CompuonTypes.h (FCompuonInt, FCompuonFloat, UCompuonSubsystem) and its Build.cs— is not in the zip. It is delivered separately: email hello@compuon.dev. The library is built with MSVC /GL and the /MD runtime; your toolset major version must match the one recorded in TOOLCHAIN.txt.
Add to your Build.cs:
string CompuonPath = Path.Combine(ModuleDirectory, "ThirdParty", "compuon-core"); PublicIncludePaths.Add(Path.Combine(CompuonPath, "include")); PublicAdditionalLibraries.Add(Path.Combine(CompuonPath, "compuon.lib"));
Compuon Types
Compuon provides Unreal-friendly wrappers around Compuon<T>:
#include "CompuonTypes.h"
// Integer values (health, ammo, score, gold)
FCompuonInt Health = FCompuonInt::Make(100);
FCompuonInt Ammo = FCompuonInt::Make(30);
FCompuonInt Score = FCompuonInt::Make(0);
// Float values (speed, position components)
FCompuonFloat MoveSpeed = FCompuonFloat::Make(600.0f);
FCompuonFloat JumpHeight = FCompuonFloat::Make(420.0f);
FCompuonInt DamageTaken = FCompuonInt::Make(12);
Health -= DamageTaken; // Tier 0, both values built (core x += y: 114 ns)
Ammo -= FCompuonInt::Make(1); // Make() builds two values per call: 1.9–2.0x
// core x -= Compuon<int>(25) (6.6 µs)
Score.ScalarMul(2); // Tier 0 (not timed)
bool bDead = Health.Val() <= 0;Timings are for the core type the wrappers hold, Compuon<int>, on one AMD Ryzen 7 5825U, MSVC 19.51 x64 Release, 2026-09-28 (median of three invocations of 9 runs), from one build of the library generated from one seed; your SDK build comes from its own seed and will time differently. Make() default-constructs the wrapper and then assigns a newly built value, so it builds two protected values per call; a copy of the wrapper built outside UE took 1.9–2.0 times core x -= Compuon<int>(25) for X -= Make(d). UE's toolchain was not timed. For per-frame damage or regen, keep the operand as an FCompuonInt built once, and compare with Val(). See Operation Tiers.
UCompuonSubsystem
A tickable world subsystem that comes up with the game module. Its tick is deliberately a no-op: the SDK needs no per-frame housekeeping, and your game owns the connection to the integrity server.
- + Automatic initialization on module start
- + No per-frame SDK call — the tick is kept as a hook point
- • The connection to the integrity server, key-rotation handling, and spot-check replies are yours to wire up — see Key Rotation.
// Usually no manual access is needed.
UCompuonSubsystem* Compuon =
GetWorld()->GetSubsystem<UCompuonSubsystem>();
// The subsystem does no per-frame SDK work; it is a stable
// place to hang your integrity-server transport.
check(Compuon != nullptr);Example: Protected PlayerState
// MyPlayerState.h
#pragma once
#include "CompuonTypes.h"
#include "GameFramework/PlayerState.h"
#include "MyPlayerState.generated.h"
UCLASS()
class AMyPlayerState : public APlayerState
{
GENERATED_BODY()
public:
FCompuonInt Health = FCompuonInt::Make(100);
FCompuonInt Armor = FCompuonInt::Make(0);
FCompuonInt Ammo = FCompuonInt::Make(30);
FCompuonFloat MoveSpeed = FCompuonFloat::Make(600.0f);
void TakeDamage(int32 RawDamage)
{
const int32 AbsorbedValue = FMath::Min(Armor.Val(), RawDamage);
const FCompuonInt Absorbed = FCompuonInt::Make(AbsorbedValue);
Armor -= Absorbed;
Health -= FCompuonInt::Make(RawDamage - AbsorbedValue);
if (Health.Val() <= 0) Die();
}
};Blueprint Considerations
Compuon is C++ only by design. Compuon types should not be exposed to Blueprints, as Blueprint variables are trivially inspectable in memory. Keep protected variables in C++ classes and expose only derived/display values to BP via getter functions.
// Expose read-only display value to Blueprints:
UFUNCTION(BlueprintPure, Category = "Stats")
int32 GetHealthDisplay() const
{
return Health.Val();
}
// Keep the actual FCompuonInt in C++ only.Build & Shipping
Compuon links statically into your game binary. In a monolithic Shipping build (the UE default):
- + No separate DLL — the SDK sits inside the game executable
- + No exports, no PDB once you drop the
.pdbfiles from the package;__FILE__build paths can remain in strings — see the name/path hygiene notes in the shipping checklist - + Internals are re-seeded per build; instruction-shape anchors remain (measured) — see the threat model