Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


capacity

The expected world capacities used to presize internal allocations when the PhysicsWorld is created. All counts default to zero, in which case the engine uses its own minimum defaults. Presizing avoids reallocations during the first simulation steps for worlds with a known object count. Every count is in the range zero to PhysicsWorld.WorldCapacity.MaxCapacity and any value outside that range is clamped into it.
Read time 1 minuteLast updated 12 days ago

Definition

  • Type: Property
  • Namespace: Unity.U2D.Physics
  • Assembly: UnityEngine.PhysicsCore2DModule
public PhysicsWorld.WorldCapacity capacity { readonly get; set; }

Remarks