Pular para o conteúdo
Mídia 1 do anúncio Poolwright
0 comentário

Descrição

Poolwright pre-allocates and reuses `AActor` and `UObject` instances so the hot paths that would otherwise spawn and destroy hundreds of things per second projectiles, tracers, impact FX, pickups, shell casings, short-lived AI, scratch data objects stop paying spawn cost and stop feeding the garbage collector. Spawning a fresh projectile costs roughly 2–3× activating a pooled one; Poolwright turns that spike into a flat line.

One `UGameInstanceSubsystem` owns every pool, keyed by class, and it survives level transitions — you build the projectile pool once, not on every streaming load. Returned instances are hidden, collision-off and tick-off (never destroyed) and handed straight back out on the next request with a stable

identity and, on a networked pool, a stable net GUID.

Video Showcase:Poolwright - Showcase video

Documentation v1.1: Poolwright documentation-v1.1

Poolwright features:

- One central registry, not a pool object per spawner. Several spawn points that share a class automatically share a pool.

- Blueprint and C++ are equal. Every operation is a node; the Acquire nodes return your actor class directly (`DeterminesOutputType`) no cast.

- `AActor` and `UObject`. Pool analytics events, request contexts and scratch objects too, not only actors.

- Optional network replication. Flip one flag for a server-authoritative pool: net-dormancy wake on acquire, sleep-after-flush on return, disjoint

  server/client work, stable net GUID across reuses. Classic replication only no push-model dependency.

- Optional auto-sizing. Grow in batches ; shrink on idle so memory converges back down after a spike — never below a configurable floor. Both off by default.

- Placeable spawn-point component with a details-panel pool config and a level-editor gizmo, so designers place spawn locations without touching code.

- Per-instance reset via the optional `IPoolable` interface — `OnUnpooled` is your per-reuse "BeginPlay", `OnPooled` is your teardown.

- Wide engine support from a single code path: UE 4.26 – 5.8, all version macros isolated in one header.

- Full C++ source included. 17 deterministic automation tests. No editor module, no `UnrealEd` dependency — safe to ship.

One rule: a pooled actor's `BeginPlay` runs once, on first spawn. Put per-reuse reset (health, FX, AI, timers) in `IPoolable::OnUnpooled`, not`BeginPlay`.

Not included: `UActorComponent` pooling, an in-editor stats panel, client-predicted acquire. Poolwright does no client→server RPC — authority is

your gameplay code's decision, exactly as with `SpawnActor`.

Formatos incluídos