CMCharacter Modules 0.1.0

Capsule Hull

Kind: Hull · Add Component: Character Modules > Collision > Capsule Hull

Gives the character a rounded shape. Feet roll off small bumps instead of catching on them.

The character's shape as a capsule: rounded at the feet, so it slides over small bumps and down edges instead of catching on them. It suits third-person characters whose feet should roll off a step rather than hang on it.

Inspector
▼Capsule Hull⋮
CharacterCharacter (Character Motor)
Collision MaskDefault, TransparentFX, 3, Water, UI, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ▾
Skin0.01
Radius0.4
Height1.8
The Capsule Hull component in the Inspector, with its defaults.
Origin. Unity's Character Controller and Unreal's Character are capsules; most third-person games since the 2000s are.

How it works

Upright capsule, the shape most modern games and Unity's CharacterController use.

Good: looks the same from every direction and glides around corners. Its rounded bottom rolls over small lips without any step logic. Watch out: on a ledge corner the sweep reports the corner's slanted normal, not the floor's, so the capsule slides off edges unless the ground sensor asks for the real surface normal. Its effective step height depends on the radius.

Combine it

  • Used by the presets: Retro Platformer, Modern Platformer, Traversal Adventure, Action RPG.

Properties

PropertyDescriptionRangeDefault
CharacterThe character this module belongs to. Drag its Character Motor here.None
Collision MaskLayers the character collides with.Default, TransparentFX, 3, Water, UI, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31
SkinGap kept between the hull and the world so that sweeps never start inside a collider, metres.0.001 or more0.01
RadiusRadius of the capsule, metres.0.05 or more0.4
HeightTotal height from feet to head, metres.0.1 or more1.8

Additional resources