Table of Contents

Class NPCDrinking

Namespace
S1API.Entities.Actions
Assembly
S1API.dll

Wraps the drinking action for an NPC. Use to equip a drink and play the drinking animation.

public sealed class NPCDrinking
Inheritance
NPCDrinking
Inherited Members
Extension Methods

Remarks

Requires the drinking component to be configured on the prefab via EnsureDrinking(string?). If not present, Begin() and End() are no-ops.

Properties

IsActive

Whether the drinking action is currently active (drink equipped, animation playing).

public bool IsActive { get; }

Property Value

bool

Methods

Begin()

Begins the drinking action: equips the drink and plays the drinking animation.

public void Begin()

Remarks

No-op if the drinking component is not on the prefab. Call EnsureDrinking(string?) during ConfigurePrefab to add it.

End()

Ends the drinking action: unequips the drink and stops the animation.

public void End()