Game.Prefabs.AnimationLayer
Assembly:
Game (Cities: Skylines 2 runtime assembly)
Namespace:
Game.Prefabs
Type:
public enum
Base:
System.Enum (underlying type: System.Int32)
Summary:
Defines discrete animation layers used by prefab actors (characters, props, etc.) to classify and combine animation clips. Each enum value represents a logical layer where animations can be applied or blended (for example body animations vs. facial animations). The default integer values are: None = 0, Body = 1, Prop = 2, Facial = 3, Corrective = 4.
Fields
-
None
Represents no animation layer / default value. Typically used when no layer is assigned. -
Body
Primary body animation layer (full-body motion, locomotion, gestures affecting the skeleton). -
Prop
Layer for prop-specific animations (held items, attachments, or separate prop rigs). -
Facial
Layer reserved for facial animations (expressions, lip-sync, eye movement). -
Corrective
Corrective or override animations used to fix clipping, adjust poses, or apply small corrections on top of other layers.
Properties
- None
This enum has no properties. Use standard enum operations (casts, comparisons) to read or modify values.
Constructors
- None (default)
Enums do not expose custom constructors. The default value isAnimationLayer.None
(0). You can cast integer values to this enum or parse from strings using System.Enum helpers.
Methods
- None (declared)
No custom methods are declared on this enum. Standard System.Enum methods (ToString, Parse, TryParse, GetValues, etc.) are available.
Usage Example
// Assigning a layer
AnimationLayer layer = AnimationLayer.Body;
// Using in logic
switch (layer)
{
case AnimationLayer.Body:
// apply/full-body animation logic
break;
case AnimationLayer.Facial:
// apply facial animation logic
break;
case AnimationLayer.Prop:
// apply prop-specific animation logic
break;
case AnimationLayer.Corrective:
// apply corrective adjustments
break;
default:
// None / fallback
break;
}
// Casting to int (underlying value)
int layerIndex = (int)AnimationLayer.Facial; // 3